Learn how to securely authenticate with the Mudstack API using API keys and JSON Web Tokens (JWTs).
To interact with the Mudstack API, you need to authenticate using a JSON Web Token (JWT). This token is generated using an API Key and Secret Key linked to your account.
Note: API access is only available for Pro and Enterprise customers. If you are on a different plan, please contact Mudstack support to upgrade your account.
To get an API Key and Secret Key, please contact Mudstack support. Click the link below to start an email to support@mudstack.com with the subject “Generate API Key for my Mudstack Account”.
Generate API Key for my Mudstack Account
Important:
Once you have your API Key and Secret Key, you can generate a JWT. Use the following endpoint to authenticate:
Notes:
token
field contains your JWT, which is valid for the duration specified in expires_in
(in seconds).Use this token in the Authorization
header for all subsequent API requests:
In addition to the Authorization
header, some endpoints require additional headers to validate resource access or ownership. These headers are:
x-account-id
: Specifies the account ID associated with the request. Required for endpoints that operate at the account level.x-workspace-id
: Specifies the workspace ID associated with the request. Required for endpoints that operate within a specific workspace.Here is an example of a request that includes all necessary headers:
Best Practices:
x-account-id
and x-workspace-id
values match the resources you are trying to access.If the required headers are missing or invalid, the API will return an error. Common error responses include:
Tips for Debugging:
x-account-id
and x-workspace-id
headers are correct and match the requested resource.Keep Your JWT Secure:
Rotate Your Keys Regularly:
For further assistance contact Mudstack Support.
Learn how to securely authenticate with the Mudstack API using API keys and JSON Web Tokens (JWTs).
To interact with the Mudstack API, you need to authenticate using a JSON Web Token (JWT). This token is generated using an API Key and Secret Key linked to your account.
Note: API access is only available for Pro and Enterprise customers. If you are on a different plan, please contact Mudstack support to upgrade your account.
To get an API Key and Secret Key, please contact Mudstack support. Click the link below to start an email to support@mudstack.com with the subject “Generate API Key for my Mudstack Account”.
Generate API Key for my Mudstack Account
Important:
Once you have your API Key and Secret Key, you can generate a JWT. Use the following endpoint to authenticate:
Notes:
token
field contains your JWT, which is valid for the duration specified in expires_in
(in seconds).Use this token in the Authorization
header for all subsequent API requests:
In addition to the Authorization
header, some endpoints require additional headers to validate resource access or ownership. These headers are:
x-account-id
: Specifies the account ID associated with the request. Required for endpoints that operate at the account level.x-workspace-id
: Specifies the workspace ID associated with the request. Required for endpoints that operate within a specific workspace.Here is an example of a request that includes all necessary headers:
Best Practices:
x-account-id
and x-workspace-id
values match the resources you are trying to access.If the required headers are missing or invalid, the API will return an error. Common error responses include:
Tips for Debugging:
x-account-id
and x-workspace-id
headers are correct and match the requested resource.Keep Your JWT Secure:
Rotate Your Keys Regularly:
For further assistance contact Mudstack Support.