Post Closed
31
Views
7
Comments
Omise Api parameter problem
Question

Hi everyone, I am not so familiar with API and i'm integrating payment gateway "Omise" in my web site using their API. The problem is when i use their API "https://api.omise.co/charges" and send the values like this       "https://api.omise.co/charges?{key}:&amount={Amount}¤cy=sgd&card={Token}".

Then i get the 401 Unauthorized error. In their website they show sample on how to send values.

I don't know how to send these values in api link. Here is my full screen shot.

Any suggestion? 


With regards.

2021-02-02 11-55-27
Tushar Panpaliya

Hope you are passing the key and token for this correctly. Those would be used for authorization I guess. 

2019-10-21 07-27-24
Zaw Phone Thet

Tushar Panpaliya wrote:

Hope you are passing the key and token for this correctly. Those would be used for authorization I guess. 

Yes, i have valid key and token but i'm not sure passing format is correct or not.


2021-02-02 11-55-27
Tushar Panpaliya

Phone wrote:

Tushar Panpaliya wrote:

Hope you are passing the key and token for this correctly. Those would be used for authorization I guess. 

Yes, i have valid key and token but i'm not sure passing format is correct or not.


did you try using the test option to try different combinations ? additionally you can try something like postman to test API calls.


2021-04-09 11-42-43
assif_tiger
 
MVP




Hi,

Simulate the above CURL into Postman request & then you can easily identify how to prepare the request.

  1. Open POSTMAN
  2. Click on "import" tab on the upper left side.
  3. Select the Raw Text option and paste your cURL command.
  4. Hit import and you will have the command in your Postman builder!
  5. Click Send to post the command

Ref: https://stackoverflow.com/questions/27957943/simulate-a-specific-curl-in-postman

Hope it helps,

Assif

2019-10-21 07-27-24
Zaw Phone Thet

assif_tiger wrote:




Hi,

Simulate the above CURL into Postman request & then you can easily identify how to prepare the request.

  1. Open POSTMAN
  2. Click on "import" tab on the upper left side.
  3. Select the Raw Text option and paste your cURL command.
  4. Hit import and you will have the command in your Postman builder!
  5. Click Send to post the command

Ref: https://stackoverflow.com/questions/27957943/simulate-a-specific-curl-in-postman

Hope it helps,

Assif

Hi assif_tiger, what should i put in username and password?

Thank you,

UserImage.jpg
Venkatesh Ks

Hi,

Can you find the answer for the above issue?. please share here

2020-09-15 13-07-23
Kilian Hekhuis
 
MVP

Hi Venkatesh,

This is an old post, with a very specific question. Of you have a similar question, please start a new topic, thanks.