Create Customer Session

Optty widgets require a session token to verify the source the Widget is loading from, and be able to display the correct list of available Payment Methods.

Parameters

Content Type: application/json

Create Customer Session

POST https://api.qa.optty.com/merchants/customer/sessions

For live environment, please update the endpoint to https://api.optty.com

Headers

NameTypeDescription

Authentication*

string

Authorization: Bearer <token>

Request Body

NameTypeDescription

customerIdentifier*

string

A unique identifier for a merchant’s customer. This can be the customer’s email address, or “anonymous” if it is a user not logged in.

{
    "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjdXN0b21lcklkZW50aWZpZXIiOiI2NDkzZDA3NTNmYjliNzBhNGY3YzFjYjE1ZTMwYzZjMmU1ZjE5Y2FlMWE1MGJiNTllMjRkMTYwMjIyOTcyMjgzMjA4OGJhZmRiMzAwNTA5MmQ4MTdjMzNhMTUyNzQyYjExZWMyZjJmYmJkYjlmN2FkYjFjMmMyMGQ3YzhjN2RiYyIsIm1lcmNoYW50SWQiOiI0NGFkMzIxMS0yYTgzLTRiNWUtYTJlNy03ZmZlNjhlZTkyMWMiLCJpYXQiOjE2MzM2ODM4NjksImV4cCI6MTYzNDI4ODY2OX0.4sTHdfV8aDJ26Lq1552cZIvpwwY6VPlBzoW2AGcAH8E",
    "ttl": 604800
}

Full Example

{
    "customerIdentifier":"anonymous"
}

Last updated