---
updatedAt: 2026-06-22T12:50:10.000Z
agentTools:
  projectIndex: https://developers.upayments.com/llms.txt
---

# Create Customer Unique Token

Users can create customer unique token for saving Credit/Debit cards

## Request Model

The request is a POST request with the following parameters:

| Input Parameter     | Type               | Length                      | Description                           |
| :------------------ | :----------------- | :-------------------------- | :------------------------------------ |
| customerUniqueToken | integer, mandatory | 8 (minimum) to 18 (maximum) | Pass the customer's unique token here |

> ❗️ customerUniqueToken Formation
>
> The customerUniqueToken is used as the primary identifier to retrieve a customer’s saved credit cards. To protect sensitive financial data, you must ensure this token is non-predictable.
>
> **Format:** Must be a numeric string between 8 and 18 digits (8 digits is highly preffered in order to enable KFAST for saving KNET cards).
>
> **Strict Requirement:** Do not use a standalone phone number. Phone numbers are public-facing and easily guessable, which creates a high security risk.
>
> **Implementation Strategy:** We strongly recommend concatenating your internal System User ID with the customer's phone number.
>
> **Objective:** This composite approach ensures the token is unique to your system and impossible for unauthorized parties to guess or enumerate.

```json Create Token Request
{
    "customerUniqueToken":9904917379121
}
```

<br />

## Response Model

Customer unique token created successfully

```json
{
  "status": true,
  "message": "Customer unique token created successfully",
  "data": {
    "customerUniqueToken": 9904917379121
  }
}
```

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "sandbox-api-base-url",
    "version": "2.0"
  },
  "servers": [
    {
      "url": "https://sandboxapi.upayments.com/api/v1/"
    }
  ],
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "paths": {
    "/create-customer-unique-token": {
      "post": {
        "summary": "Create Customer Unique Token",
        "description": "Users can create customer unique token for saving Credit/Debit cards",
        "operationId": "createcustomeruniquetoken",
        "parameters": [
          {
            "name": "Authorization",
            "in": "header",
            "schema": {
              "type": "string",
              "default": "Bearer jtest123"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "customerUniqueToken": {
                    "type": "string",
                    "description": "Insert your own Customer Unique Token",
                    "default": "9904917379121"
                  }
                }
              },
              "examples": {
                "Request": {
                  "value": {
                    "customerUniqueToken": "9904917379121"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "201",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"status\": true,\n    \"message\": \"Customer unique token created successfully\",\n    \"data\": {\n        \"customerUniqueToken\": 9904917379121\n    }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "boolean",
                      "example": true,
                      "default": true
                    },
                    "message": {
                      "type": "string",
                      "example": "Customer unique token created successfully"
                    },
                    "data": {
                      "type": "object",
                      "properties": {
                        "customerUniqueToken": {
                          "type": "integer",
                          "example": 9904917379121,
                          "default": 0
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"message\": \"Unauthorized\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Unauthorized"
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "403",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"message\": \"Not a valid API request\"\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Not a valid API request"
                    }
                  }
                }
              }
            }
          },
          "422": {
            "description": "422",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"message\": \"Customer unique token already exist\",\n    \"errors\": {\n        \"customerUniqueToken\": [\n            \"Customer unique token already exist\"\n        ]\n    }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "example": "Customer unique token already exist"
                    },
                    "errors": {
                      "type": "object",
                      "properties": {
                        "customerUniqueToken": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "example": "Customer unique token already exist"
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "security": []
      }
    }
  },
  "x-readme": {
    "headers": [
      {
        "key": "accept",
        "value": "application/json"
      }
    ],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```