Getting Started
Obtaining client credentials
Section titled “Obtaining client credentials”To start working with the Myver API, please request access here.
Getting an access token
Section titled “Getting an access token”Request an access token from the Authentication API using HTTP Basic Auth. The snippet below stores your credentials in environment variables and exchanges them for a short-lived token:
export CLIENT_ID="your_client_id"export CLIENT_SECRET="your_client_secret"
curl -v -X POST https://auth.prod.myver.tech/oauth2/token \ -H "Content-Type: application/x-www-form-urlencoded" \ -d "client_id=${CLIENT_ID}" \ -d "client_secret=${CLIENT_SECRET}" \ -d "grant_type=client_credentials" \ -d "scope=brand:read store:read store:write source:read source:write receipt:write payment:write" \ -d "audience=api.prod.myver.tech"A successful response matches the object below; use its access_token field for subsequent API calls:
{ "access_token": "eyJhbGciOiJIUzI1NiIsI⋯dQssw5c", "expires_in": 3600, "token_type": "bearer", "scope": "brands:read stores:write sources:read sources:push"}Next steps
Section titled “Next steps”- Planning to send receipts to Myver? Continue with the receipt sending tutorial.
- Planning to receive receipts from Myver? Continue with the receipt receiving tutorial.