Get Customer API Token

This page contains information on how can agency owners get the API token for the its customers.

Get User API Access Token

This API endpoint retrieves a user API Access token based on the provided user ID.

Endpoint

MethodURL

GET

https://api.v7.botpenguin.com/ext/get-user-token

Parameters

ParameterRequiredDescription

userId

Yes

The unique identifier for the user. You can get the same from the Get Customer API.

Headers

HeaderValueDescription

authtype

Key

Must be set to 'Key'.

Authorization

Bearer

Bearer token for authentication. You can get the same from the agency admin's account on BotPenguin Dashboard.

Example Request

curl --location 'https://api.v7.botpenguin.com/ext/get-user-token?userId=*********' \
--header 'authtype: Key' \
--header 'Authorization: Bearer **********'

Success API Response

{
    "success": true,
    "message": "",
    "data": {
        "permanentToken": {
            "key": "**********",
            "active": true
        }
    },
    "code": 200
}

Response Fields

FieldDescription

success

Indicates if the request was successful.

message

Additional information or error messages.

data

Container for the response data.

permanentToken

Object containing the permanent API access token details of the customer

key

API access token generated for the user.

active

Indicates whether the token is currently active or not.

code

The status code indicating the result of the request (200 for success).

Got any questions?

If you have any questions, you can look into our repository of FAQs, most likely, you will find your answer here, If not, write us at contact@botpenguin.com.

Last updated