/
v3

v3

Endpoint URL

Staging

https://us-central1-fleet-staging-2333a.cloudfunctions.net

Production

will be provided after SIT

 


Login and Get Session Token bUSINESS Provider

Description

To acquire authorization token

Endpoint

/login

Method

POST


Request Headers

{ "Content-Type": "application/json" }


Request Body

Field

Data type

Required

Description

Field

Data type

Required

Description

email

string

yes

email credential

password

string

yes

password


Sample Request Body

{ "email": "sandbox_dev@gmail.com", "password": "password" }

Sample Response

Status: 200 OK! { "success": true, "results": { "apiKey": "fb77c9653bf5e736d191b46bbfed7c2bd", "clientId": "SANDBOX_DEV", "sessionToken": "b45e2fb77c9653bf5e736d19e1fd18ebbffd0f6d3dd25af118e5eb38851bf4d" } }

 

Field

Description

Field

Description

apiKey

Generated hash on client-side to be used on succeeding API request

clientId

Reference Client ID

sessionToken

Generated hash on every API login to be used on succeeding API requests.
Expires after 20 minutes.

 

  • Session token expires after 20 minutes of use.

  • Session duration refreshes every login or on API (createPost, getPost, etc.) calls given that the token is still valid.

  • QUOTA_EXCEEDED error message occurs when you reach a certain number of login API request per second. For bulk API calls, please use the login API once and reuse the session token. You may also retry the operation after 1-2 seconds.

Error Messages:

Invalid Email

 

Invalid Password

 

Quota Limit Exceeded Error

Login v2 BUSINESSProvider

Description

Login V2 that uses JWT Auth

Endpoint

/loginV2

Method

POST

 

Request Headers

KEY

VALUE

KEY

VALUE

Content-Type

application/json

 

Request Body

Field

Data type

Required

Description

Field

Data type

Required

Description

email

string

yes

email credential

password

string

yes

password

Sample Response

  • To use Login API v2 on our existing endpoints (e.g. /getpost), “x-access-token" must be defined in the HEADERS instead of the "Auth-token" and value for it should be “Bearer {{accessToken}}”.

  • apiKey is no longer required to be defined in the Parameters on our existing endpoints
    (e.g. /getpost) if “x-access-token" is defined in the Headers.

Error Messages:

Invalid Email

Invalid Password

Get Partners Business Provider

Description

To get the list of your preferred partners

Endpoint

/getPartners

Method

GET


Request Headers

Login V1

Login V2

Query parameters (URL)

Login V1

Login V2


Sample Response

 

Get List of Areas Business

Description

To get the list of areas

Endpoint

/getListOfAreas

Method

GET


Request Headers

Login V1

Login V2


Query parameters (URL)

Login V1

Login V2


Sample Response

Get List of Stores/Hubs BUSINESS

Description

To get the list of stores/hubs

Endpoint

/getListOfStores

Method

GET


Request Headers

Login V1

Login V2

Query parameters (URL)

Login V1

Login V2


Sample URL


Sample Response


List of Statuses

Responses (Success and Errors)

Status

Message

Description

Status

Message

Description

200

OK

Success

400

Bad Request

We could not understand the request due to invalid syntax or invalid parameters.

401

Unauthorized

Your apiKey can be missing or invalid. Your auth-token is not valid or may have already expired.

500

Internal Server Error

Unhandled exception. Please contact the production team when you encounter this error.