Roll API Key


                https://api.ocamba.com/v2/ocamba/personal-api-keys/{id}/roll
            

Generates a new API Key with same settings and deactivates the existing one immediately.


Name
Description
idstringrequired
API Key identifier.


Example: id=1001

200 - OK
Arrow
Name
Description
company_idstring
The ID of the company, assigned by Ocamba API.

descriptionstring
A more details about API key for easy identification.


Example: My API Key

end_timedateTime
Ending date and time for API Key. Timezone: GMT.


Example: 2024-11-25 13:45:03

idstring
API Key indentifier.


Example: 1001

namestring
A descriptive name for the API key for easy identification.


Example: My API Key

secretstring
API Key.


Example: i01S296VTdPI00F3tPbONQ

start_timedateTime
Starting date and time for API Key. Timezone: GMT.


Example: 2021-11-25 13:45:03

statusstring
Api Key status.


Example: active

Possible values: active | pending | expired

400 - Bad Request
Arrow
Name
Description
codeinteger
Http response status code.


Example: 400

messagestring
The human readable message that describes how to deal with error.


Example: The request body is not valid.

titlestring
The error title.


Example: Bad request.

trace_idstring
Error trace id.


Example: 99a84211-f73d-4ff8-acdf-eb3e06bb9d62

500 - Internal Server Error
Arrow
Name
Description
codeinteger
Http response status code.


Example: 500

messagestring
The human readable message that describes how to deal with error.


Example: Internal server error.

titlestring
The error title.


Example: Internal server error.
200 Arrow
{
  "id": "1002168",
  "company_id": "6197120",
  "name": "My API key",
  "description": "API key used for ...",
  "status": "active",
  "secret": "a2e9a25b9a4f57f3d307bebafb0ac9db3d78f4ce",
  "start_time": "2024-08-08 13:00:00",
  "end_time": "2024-10-09 13:00:00",
  "create_time": "2024-08-09 13:05:50",
  "update_time": "2024-08-09 13:05:50"
}
{
  "id": "1001",
  "issuer_id": "10001",
  "member_id": "10001",
  "name": "My API Key",
  "description": "My API Key",
  "status": "active",
  "secret": "i01S296VTdPI00F3tPbONQ",
  "end_time": "2024-11-25 13:45:03",
  "start_time": "2021-11-25 13:45:03",
  "create_time": "2021-11-25 13:45:03",
  "update_time": "2021-11-26 11:37:25"
}
{
  "code": 400,
  "title": "Bad request.",
  "message": "The request body is not valid.",
  "trace_id": "99a84211-f73d-4ff8-acdf-eb3e06bb9d62"
}
{
  "code": 500,
  "title": "Internal server error.",
  "message": "Internal server error."
}