Authentication
To send requests to the MaintainX® REST API to fetch and modify data, you need to authenticate every request.
Bearer​
Authenticate by adding the following HTTP header to your requests:
Authorization: bearer {{token}}
The token is an API key that you can generate from your MaintainX account. For details, see Generate a MaintainX API Key.
| Security Scheme Type | HTTP Authorization Scheme | Bearer Format |
|---|---|---|
| HTTP | Bearer | JWT |
Multi-Organization Token​
If your token can be used on multiple organizations, you have to pass a header to indicate the organization you are referring to in all your calls:
x-organization-id: {{organizationId}}
For list endpoints that support querying multiple organizations in one request, you can instead pass a comma-separated list of organization IDs:
x-organization-ids: {{organizationId1}},{{organizationId2}}
A 400 code will be returned if you're using a token for multiple organizations but didn't pass either header. You cannot use both headers (x-organization-id and x-organization-ids) at the same time.