Switch SDK Token Status — API

Enables or disables the SDK token associated with a specified user UUID. Returns the token, user, business unit, terminal, device, and active-status information, with documented 200 OK and 400 Bad Request responses.

1. Overview

Enables or disables the SDK token associated with a specified user.

This endpoint allows authorized callers to manage the SDK token's active status using the user's UUID. The API response includes the user and token details, associated business unit and terminal information, device ID, and active status.

2. Endpoint Details

PropertyValue
HTTP MethodPUT
Endpoint/api/v1/sdk-token/USERID
Production Base URLhttps://app-api.edfapay.com
Request BodyNone specified
Access LevelNot specified in the provided API reference

3. Authentication

Include the API key in the request headers, as required by the API configuration.

HeaderValue
X-API-KEYYOUR_API_KEY
Accept*/*

4. Path Parameters

ParameterTypeRequiredDescription
userIdString (UUID)YesUnique identifier of the user whose SDK token status is to be changed.

Example:

3fa85f64-5717-4562-b3fc-2c963f66afa6

5. Request Example

cURL

curl --request PUT \
  --url 'https://app-api.edfapay.com/api/v1/sdk-token/3fa85f64-5717-4562-b3fc-2c963f66afa6' \
  --header 'X-API-KEY: YOUR_API_KEY' \
  --header 'Accept: */*'

Replace the sample UUID with the actual userId.

Note: The provided Swagger reference does not show a request body or a parameter specifying whether to enable or disable the token. Confirm the intended status-switching behavior in the API implementation or live Swagger before integrating this endpoint.

6. Responses

6.1 HTTP 200 — OK

Description: The request was processed successfully.

Example response:

{
  "code": 0,
  "message": "string",
  "errorCode": "string",
  "data": {
    "userId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "token": "string",
    "userBusinessUnitId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "userType": "SUPER_ADMIN",
    "terminalId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
    "trsm": "string",
    "deviceId": "string",
    "active": true
  }
}

Response Fields

FieldTypeDescription
codeNumberAPI response code.
messageStringResponse message.
errorCodeStringError identifier, where applicable.
data.userIdUUIDUser identifier.
data.tokenStringSDK token associated with the user.
data.userBusinessUnitIdUUIDAssociated business unit identifier.
data.userTypeStringUser role or type. The example shows SUPER_ADMIN.
data.terminalIdUUIDAssociated terminal identifier.
data.trsmStringTerminal serial number or identifier used by the system.
data.deviceIdStringAssociated device identifier.
data.activeBooleanIndicates whether the returned record is active.

6.2 HTTP 400 — Bad Request

Description: The request could not be processed because of invalid input or another request-related issue.

Example response:

{
  "code": 0,
  "message": "string",
  "errorCode": "string",
  "data": {}
}

The values shown are Swagger placeholders and may differ from actual runtime responses.

7. Implementation Notes

  • Provide a valid UUID in the userId path parameter.
  • Include the required authentication header.
  • Check the returned data.active value to determine the active status represented in the response.
  • Treat the SDK token as sensitive information and avoid exposing it in logs or sharing it with unauthorized parties.
  • The provided reference does not specify how the enable/disable action is selected, whether a request body is required in other configurations, or whether the token value changes after the operation.

8. Summary

This endpoint manages the SDK token status associated with a specified user and returns the associated user, business unit, terminal, and device information. Refer to the live API specification to confirm how the desired status is selected.


Did this page help you?