Scoped Authentication
Fetch business auth token
Fetches a new auth token scoped to the specified business. The business auth token is used to authenticate Layer API requests from client-side applications. Note the return type is an AuthToken object rather than a standard Layer API response object.
GET
/
v1
/
businesses
/
{businessId}
/
auth-token
Authorizations
Authorization
string
headerrequiredBearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Headers
Content-Type
string
Content-Type must be set to application/json
Path Parameters
businessId
string
requiredThe UUID of the business to fetch a business-scoped auth token for
Response
200 - application/json
access_token
string
The business-scoped access token for the Layer API
expires_in
integer
Number of seconds until the access token expires
token_type
string
Type of the access token, currently always Bearer.