IncidentIo. ApiKeysV1
(IncidentIo v0.3.1)
View Source
Manage API keys for your organisation.
API keys are used to authenticate requests to the incident.io API. This module supports listing, creating, updating, and rotating API keys.
Summary
Functions
Create a new API key.
Delete an API key.
List all API keys for an organisation.
Rotate an API key, generating a new token.
Get a single API key.
Update an existing API key.
Functions
@spec create(IncidentIo.Client.t(), map()) :: IncidentIo.response()
Create a new API key.
Example
IncidentIo.ApiKeysV1.create(client, %{name: "My API Key"})More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_Create
@spec destroy(IncidentIo.Client.t(), binary()) :: IncidentIo.response()
Delete an API key.
Example
IncidentIo.ApiKeysV1.destroy(client, "some-api-key-id")More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_Delete
@spec list(IncidentIo.Client.t()) :: IncidentIo.response()
List all API keys for an organisation.
Example
IncidentIo.ApiKeysV1.list(client)More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_List
@spec rotate(IncidentIo.Client.t(), binary()) :: IncidentIo.response()
Rotate an API key, generating a new token.
Example
IncidentIo.ApiKeysV1.rotate(client, "some-api-key-id")More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_Rotate
@spec show(IncidentIo.Client.t(), binary()) :: IncidentIo.response()
Get a single API key.
Example
IncidentIo.ApiKeysV1.show(client, "some-api-key-id")More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_Show
@spec update(IncidentIo.Client.t(), binary(), map()) :: IncidentIo.response()
Update an existing API key.
Example
IncidentIo.ApiKeysV1.update(client, "some-api-key-id", %{name: "Updated Key Name"})More information at: https://api-docs.incident.io/tag/API-Keys-V1#operation/API%20Keys%20V1_Update