API Keys

We use API keys to authenticate requests. You can view and manage your API keys through the vivenu Dashboard or via the API.

Endpoints

The API Key Object

Attributes

_id
Required
string

The ID of the API key.

name
Required
string

An internal name to identify the API key.

key
Required
string

The secret key to be used to authenticate against the API.

createdAt
Required
string date-time

An ISO Timestamp indicating when the API Key was created.

updatedAt
Required
string date-time

An ISO Timestamp indicating when the API Key was last updated.

Optional Attributes

Collapse all
Was this section helpful?
YesNo
Example
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}

Create an API Key

Payload

name
Required
string

An internal name to identify the API key.

Optional Attributes

Collapse all
Responses
201
Created
400
Bad Request
401
Unauthorized
403
Forbidden

Was this section helpful?

YesNo
post
/api/keys
{
"name": "string",
"orgId": "string"
}
Response
application/json
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}

Get an API Key

Query

No supported query parameters
Responses
200
OK
400
Bad Request
401
Unauthorized

Was this section helpful?

YesNo
get
/api/keys/{id}
Response
application/json
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}

Update an API Key

Payload

Optional Attributes

Collapse all
Responses
200
OK
400
Bad Request
401
Unauthorized

Was this section helpful?

YesNo
put
/api/keys/{id}
{
"active": true,
"name": "string"
}
Response
application/json
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}

Get All API Keys

Query

No supported query parameters
Responses
200
OK
401
Unauthorized

Was this section helpful?

YesNo
get
/api/keys
Response
application/json
[
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}
]
ORG

Get or Create a Default API Key

Payload

sellerId
Required
string

The seller ID to get or create the API key for.

Responses
200
OK
400
Bad Request
401
Unauthorized

Was this section helpful?

YesNo
post
/api/keys/default
{
"sellerId": "string"
}
Response
application/json
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}

Get Information about the used API Key

Query

No supported query parameters
Responses
200
OK
401
Unauthorized

Was this section helpful?

YesNo
get
/api/keys/info
Response
application/json
{
"_id": "string",
"active": true,
"name": "string",
"sellerId": "string",
"orgId": "string",
"key": "key_somerandomcombinationofnumbersandletters",
"createdBy": {
"type": "USER",
"id": "string"
},
"createdAt": "2030-01-23T23:00:00.123Z",
"updatedAt": "2030-01-23T23:00:00.123Z"
}