API keys
You can create, view, manage, and delete API keys on behalf of your merchants. Store them securely to authenticate your merchants when using the FlexFactor APIs
API Keys Endpoints
endpoint | link to documentation |
---|---|
POST /v1/api-keys | Create an API key |
GET /v1/api-keys/{id} | Get an API key |
GET /v1/api-keys/{mid} | Retrieve all the API keys related to a merchant |
DELETE /v1/api-keys/{id} | Revoke an API key |
General Information
The API Kays management enables seamless handling of credentials related to converted applications. These APIs are RESTful and use standard HTTP methods (POST, GET, DELETE) to perform operations such as uploading, retrieving, and deleting documents.
Some requests require data in the message body, while others use URL parameters to specify the target document or application.
Endpoints
Sandbox testing | https://api-sandbox.flex-charge.com/v1/ |
Production environment | https://api.flex-charge.com/v1/ |
The sandbox environment is completely isolated for testing purposes. Experiment freely without impacting production systems. When you’re ready for deployment, production credentials will provide access to the live system.
Do not upload sensitive or real-world financial data in the Sandbox environment.
Headers
To interact with the API Keys Management APIs, ensure the following headers are included in your requests:
Name | Description | Request Type | Value |
---|---|---|---|
authorization | Every request must be authenticated. | GET, POST, DELETE | Bearer token |
content-type | Specifies the media type of the resource. | POST | multipart/form-data or application/json |
Versioning
The API Keys Management APIs follows the versioning protocol outlined in the base API documentation.
For example, <https://api.flex-charge.com/v1/onboarding/application/{id}/documents/> indicates version 1 of the API.
Backward-incompatible updates will increment the version number, while minor enhancements and fixes do not.
Ensure that your implementation can handle API revisions, including additional, unspecified response fields or variable response sizes.
Errors
The Document Management API uses standard HTTP response codes to indicate success or failure. Below is a list of common response codes and their meanings:
Response Code | Description |
---|---|
200 OK | The request completed successfully. |
201 Created | Resource created successfully. |
204 No Content | Returned on a successful DELETE request. |
400 Bad Request | The request is malformed or missing required parameters. |
401 Unauthorized | Authentication failed. Provide valid credentials to proceed. |
403 Forbidden | Access to the resource is denied. |
404 Not Found | The specified application or document could not be located. |
405 Method Not Allowed | The HTTP method used is not allowed for this resource. |
500 Internal Server Error | An unexpected error occurred on the server. |
502 Bad Gateway | Received an invalid response from the upstream server. |
503 Service Unavailable | The server is temporarily unable to process the request. |
504 Gateway Timeout | The server timed out while attempting to process the request. |
Updated 1 day ago