Generate API Key
To obtain your API key, simply utilize our dedicated endpoint designed explicitly for this purpose. When sending a request to this endpoint, you have the flexibility to define the lifespan of your API key according to your needs. Specify the desired duration for validity by setting a value for "expires_at".
info
Maximum API Keys a user can generate is 5.
POST/api/api-key
POST https://api.amlwatcher.com/api/api-key HTTP/1.1Host: api.amlwatcher.comAuthorization: Bearer TokenContent-Type: application/jsonContent-Length: 24{"expires_at": 12}
Request
Parameters | Required | Type | Description |
---|---|---|---|
expires_at | Yes | Integer | Min: 1 Max: 365 The expires_at represents the number of days. |
Response
Parameters | Description |
---|---|
error | Whenever there is an error in your request, this param will have details of that error; otherwise it’ll remain empty. |
status | The status field is set to either “SUCCESS” or “FAIL”, indicating that the API request resulted in a successful or failure/error condition respectively. |
data | An array containing the actual response elements. |
Sample Response
{
"data": {
"api_key": {
"created_at": "Wed, 08 May 2024 06:13:24 GMT",
"expires_at": "Mon, 20 May 2024 06:13:24 GMT",
"key": "Generated API Key"
}
},
"error": false,
"status": "SUCCESS"
}