Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Type

Parameter

Required

Details

FORMDATA

client_id

Yes

  • ASCII string (100)

  • This is the Client ID given in the Developer User Account section

FORMDATA

client_secret

Yes

  • ASCII string (100)

  • This is the Client Secret given in the Developer User Account section

BODY

grant_type


  • ASCII string

  • This is the client's access type

  • possible values: 'password', 'refresh_token', 'client_credentials'

  • default value: 'client_credentials'

BODY

refresh_token

  • ASCII string

  • only to be used with the grant_type: refresh_token.

  • It should be the refresh_token attribute in the last response of this method.

BODY

scope

  • ASCII string

  • Available values: ‘customer', 'merchant’

  • Default value: merchant

Example Request:

Code Block
languagejson
{
    "client_id": "flexitidemo",
    "client_secret": "77xde15a-9d33-4c15-930a-3se4b3as33e9",
    "grant_type": "client_credentials",
    "scope": "merchant"
}

Response Parameters:

Type

Parameter

Details

BODY

access_token

  • Bearer token to be used in subsequent calls

BODY

expires_in

  • Time, in seconds, that the token will last

BODY

refresh_token

  • Token to be used to refresh the access_token

Success Response:

Code Block
{
    "token_type": "bearer",  
    "access_token": "2d8f373a3c2b1e61baf5a7769930ff4f0e08cdb0",  
    "expires_in": 1200,  
    "refresh_token": "36e0fc3d7415145f4b1d71512c459fd6eaa13aa8",
    "scope": "merchant"
}

...

POST /client-id/{client_id}/merchants/login

...

Type

Parameter

Details

BODY

merchant_name

  • ASCII string (130)

  • Name of the merchant authenticated

BODY

merchant_id

  • number (10)

  • ID of the merchant authenticated

BODY

form_values

  • ASCII strings

  • Various values used in the credit application form

Success Response:

Code Block
breakoutModewide
languagejson
{
    "merchant_name": "ACME Jewellers",
    "merchant_id": "123",
    "form_values": {
        "salutation": {
            "options": {
                "mr": "Mr.",
                "ms": "Ms.",
                "mrs": "Mrs.",
                "mss": "Miss."
            }
        },
        "province": {
            "options": {
                "AB": "Alberta",
                "BC": "British Columbia",
                "MB": "Manitoba",
                "NB": "New Brunswick",
                "NL": "Newfoundland & Labrador",
                "NS": "Nova Scotia",
                "NT": "Northwest Territories",
                "NU": "Nunavut",
                "ON": "Ontario",
                "PE": "Prince Edward Island",
                "QC": "Quebec",
                "SK": "Saskatchewan",
                "YT": "Yukon Territory"
            }
        },
        "security_qid": {
            "options": {
                "4": "What is the name of your favourite childhood friend?",
                "5": "What is the country of your ultimate dream vacation?",
                "6": "What was the first concert you attended?",
                "7": "What is the name of the street you grew up on?",
                "8": "What is the name of your first grade teacher?",
                "9": "What is your favourite movie?"
            }
        },
        "govid_type": {
            "options": {
                "CADL": "Driver's Licence",
                "CAHC": "Health Card",
                "CAPID": "Provincial ID Card",
                "CAP": "Passport",
                "CAPRC": "Permanent Resident Card",
                "CAICBC": "Insurance Corporation of British Columbia",
                "CAAR": "Alberta Registries",
                "CASGI": "Saskatchewan Government Insurance",
                "CADSNS": "Department of Service Nova Scotia and Municipal Relations",
                "CADPPEI": "Department of Transportation and Public Works of the Province of Prince Edward Island",
                "CASNB": "Service New Brunswick",
                "CADGSNF": "Department of Government Services and Lands of the Province of Newfoundland and Labrador",
                "CADTNW": "Department of Transportation of the Northwest Territories",
                "CADCTN": "Department of Community Government and Transportation of the Territory of Nunavut",
                "CACSC": "Correctional Service Canada identification card (with the individual's name and photograph)",
                "CAGCEC": "Government of Canada employee identity card (with the individual's name and photograph)",
                "CALCB": "Liquor Control Board Age of Majority (BYID) card",
                "CACFL": "Canadian Firearms licence",
                "CACFID": "Canadian Forces identification card",
                "CAMPIC": "MPIC card issued by the Manitoba Public Insurance Corporation",
                "CACAID": "NEXUS or CANPASS Air membership card (issued by Canada Border Services Agency)"
            }
        },
        "govid_issued_by": {
            "option_depends": {
                "CADL": {
                    "AB": "Alberta",
                    "BC": "British Columbia",
                    "MB": "Manitoba",
                    "NB": "New Brunswick",
                    "NL": "Newfoundland & Labrador",
                    "NS": "Nova Scotia",
                    "NT": "Northwest Territories",
                    "NU": "Nunavut",
                    "ON": "Ontario",
                    "PE": "Prince Edward Island",
                    "QC": "Quebec",
                    "SK": "Saskatchewan",
                    "YT": "Yukon Territory"
                },
                "CAHC": {
                    "BC": "British Columbia",
                    "NB": "New Brunswick",
                    "NL": "Newfoundland & Labrador",
                    "NT": "Northwest Territories",
                    "NU": "Nunavut",
                    "QC": "Quebec",
                    "SK": "Saskatchewan",
                    "YT": "Yukon Territory"
                },
                "CAPID": {
                    "ON": "Ontario"
                },
                "CAP": {
                    "CANADA": "Canada"
                },
                "CAPRC": {
                    "CANADA": "Canada"
                },
                "CAICBC": {
                    "BC": "British Columbia"
                },
                "CAAR": {
                    "AB": "Alberta"
                },
                "CASGI": {
                    "SK": "Saskatchewan"
                },
                "CADSNS": {
                    "NS": "Nova Scotia"
                },
                "CADPPEI": {
                    "PE": "Prince Edward Island"
                },
                "CASNB": {
                    "NB": "New Brunswick"
                },
                "CADGSNF": {
                    "NL": "Newfoundland & Labrador"
                },
                "CADTNW": {
                    "NT": "Northwest Territories"
                },
                "CADCTN": {
                    "NU": "Nunavut"
                },
                "CACSC": {
                    "CANADA": "Canada"
                },
                "CAGCEC": {
                    "CANADA": "Canada"
                },
                "CALCB": {
                    "AB": "Alberta",
                    "BC": "British Columbia",
                    "MB": "Manitoba",
                    "NB": "New Brunswick",
                    "NL": "Newfoundland & Labrador",
                    "NS": "Nova Scotia",
                    "NT": "Northwest Territories",
                    "NU": "Nunavut",
                    "ON": "Ontario",
                    "PE": "Prince Edward Island",
                    "QC": "Quebec",
                    "SK": "Saskatchewan",
                    "YT": "Yukon Territory"
                },
                "CACFL": {
                    "CANADA": "Canada"
                },
                "CACFID": {
                    "CANADA": "Canada"
                },
                "CAMPIC": {
                    "MB": "Manitoba"
                },
                "CACAID": {
                    "CANADA": "Canada"
                }
            }
        }
    }
}