Requesting Tokens
Redirecting For Access Tokens
Once you get your API credentials, you may use your
ID (client_id)
and Lekirkey (client_secret)
to request an access token from Lekirpay application. Your apps should issue a POST request to Lekirpay to request an access token /oauth/token
page like so:
Request
Redirect URL | Method | # |
---|---|---|
https://app.lekirpay.com/oauth/token | POST |
Parameter |
Parameter | Type | Position | # | Value | |
---|---|---|---|---|---|
grant_type | string |
Body |
Required |
client_credentials | |
client_id | string |
Body |
Required |
your client id | |
client_secret | string |
Body |
Required |
your lekirkey |
Example request
curl -X POST \ https://app.lekirpay.com/oauth/token\ -F grant_type=client_credentials \ -F client_id=73467417 \ -F client_secret=30kZRzDeD5023o2JKopDA9Qq0zcbA2IHtxInvEwp
Response
{ "token_type": "Bearer", "expires_in": 1296000, "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImp0aSI6ImIwYz MyNGY3ZmU1ZWZjODAyN2VjNmIxYmFiNTAzOTExNGZiODBjODYyYTI4ZmQyOTI2NTNhZ GY0NDAxMTVkNmNhNWE0ZmE3MzM3YmQzMjg0In0.eyJhdWQiOiI3MzQ2NzQxNyIsImp0 aSI6ImIwYzMyNGY3ZmU1ZWZjODAyN2VjNmIxYmFiNTAzOTExNGZiODBjODYyYTI4ZmQ yOTI2NTNhZGY0NDAxMTVkNmNhNWE0ZmE3MzM3YmQzMjg0IiwiaWF0IjoxNTY3NDkyNz QwLCJuYmYiOjE1Njc0OTI3NDAsImV4cCI6MTU2ODc4ODc0MCwic3ViIjoiIiwic2Nvc GVzIjpbXX0.hO51-EaYqhC2lfbSj5R6NE6g-cWZh7fw9SAA-jJMgqo1bHaPVK-uR3uC 1VDPjPgWYXbTh1QxmZk-IhXc-LFdZX7LCgXaFgtN2aG-jj4_qdJY7SdrcNW35Q6E4nF CNvO811-9meJW4h1Ht9tJ2S7vl6PXzZUKm-q4s6Zzp3seerw14JPlSF_x-hqsIHli7c 7Dh33j5e4S-lyx-X4Cjwciox42haEFbG2Zl9V_DK3uCGBN1PKlql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