invalid signature for travelpayouts hotel api - api

I am trying to send a request to travelpayouts hotel search API, Two days ago I have been trying to get a result using the postMan program but a message appears that there is an error in the signature, although I followed the same instructions mentioned in the documentation for the API, if someone used this API before that please ask me to help me
Api link that I have used
Error message:
{
"message": "Invalid signature",
"status": "error",
"errorCode": 3
}

You could send your signature string to support#travelpayouts.com and mention a link to this question on SO, and we'll take a look at it and suggest how to make it work. As the signature string has your API token, it's better not to post it here.

Related

Cannot call Linkedin GET API

please I need help, the some of the pages from LinkedIn are broken e.g. https://developer.linkedin.com/docs/oauth2#refresh
I want to start with getting me but It fails that authorization is
{
"serviceErrorCode": 65600,
"message": "Invalid access token",
"status": 401
enter image description here
I add to the bearer my Client's Secret
enter image description here
How can I call these APIs? I am lost....
Also, they are talking about oauth-2.0
I don't understand what they mean
https://learn.microsoft.com/en-us/linkedin/shared/integrations/people/profile-api?context=linkedin%2Fconsumer%2Fcontext
Thank you

AWS APIGateway "Missing Authentication Token"

I have been working on AWS APIGateway and I had created one by following one of the youtube videos (https://www.youtube.com/watch?v=0UxiV5sUlcA). I tested the URL using postman and https://reqbin.com/ and it seems to be working (GET).
What I did then is requested EMFIT to send test data to the URL I created, he got back to me and was told that there is a" "message": "Missing Authentication Token" '.
I feel like the GET method is not enough for a third party to send test data to the URL I provided him. (missingauthenticationpicture here are the methods and resources I created) When I tested in postman with POST method (if that is the correct method in order for emfit to send test data), it shows the error above.
Am I missing a method in order for the third party to send test data? Any guidance is greatly appreciated. I am fairly novice and I am learning via feedbacks and some videos.

Some Hangout's API methods are not working

I'm building a chat bot using Hangouts API and some of the API methods are not working, I receive the response:
{
"error": {
"code": 400,
"message": "Request contains an invalid argument.",
"status": "INVALID_ARGUMENT"
}
}
For example, when I get the spaces my bot is a member, it returns all spaces just fine. Then I try to use some of these spaces id to get the member list, and it returns that the request contains an invalid argument. I can't see what I'm doing wrong...
The token can't be the issue because it works fine to get the spaces.
EDIT: The create message method returns a different error:
I figured it out... My company have a lib to generate a token for google's apis and the email that was used in the request was the current user email, but, for the bot it must be used the email associated with the service account, I switched that and it started working. I think it shouldn't generate a token case the credentials are not valid because I couldn't figure out what was wrong.
Source where I found this: https://developers.google.com/hangouts/chat/how-tos/rest-api#authorizing_the_service_account

Liking post/comments using the v2 OAuth 2.0 Linkedin API

I am using the Linkedin API OAuth 2.0 API and trying to like post/comments using the new OAuth 2.0 API.
The following example below shows an POST request to following endpoint:
POST https://api.linkedin.com/v2/socialActions/{commentUrn}/likes
https://api.linkedin.com/v2/socialActions/urn:li:share:543222277889832/likes
with the following POST JSON body
{
"actor": "urn:li:person:0XV6h162Ub",
"object": "urn:li:share:543222277889832"
}
and I get the following result
{
"message": "Unable to obtain activity for urn: 'urn:li:share:543222277889832'",
"status": 404
}
https://learn.microsoft.com/en-us/linkedin/marketing/integrations/community-management/shares/network-update-social-actions#create-a-like-on-a-comment
I am unsure how the urn's work - how do I find the relevant urn for a particular person (as illustrated in the 'actor' below) and the object the Linkedin API documentation seems rather confusing.
Thanks in advance
Maybe the post is not processed by LinkedIn when you make a comment request. You should ask the post status before. If it's ok, launch the comment request.

google oauth2 discovery return wrong token_endpoint

Here is the google oauth2 discovery url.
https://accounts.google.com/.well-known/openid-configuration
And in the response, it looks like this
{
"issuer": "https://accounts.google.com",
"authorization_endpoint":"https://accounts.google.com/o/oauth2/v2/auth",
"token_endpoint": "https://oauth2.googleapis.com/token",
"userinfo_endpoint": "https://www.googleapis.com/oauth2/v3/userinfo",
"revocation_endpoint": "https://oauth2.googleapis.com/revoke",
"jwks_uri": "https://www.googleapis.com/oauth2/v3/certs",
...
The token_endpoint in the google document here https://developers.google.com/identity/protocols/OAuth2WebServer#exchange-authorization-code said it should be https://www.googleapis.com/oauth2/v4/token.
Maybe recently the token_endpoint is updated, but when I use https://oauth2.googleapis.com/token this one to exchange token with code., I will get an error response.
{ "error": { "code": 400, "message": "Request contains an invalid argument.", "status": "INVALID_ARGUMENT" } }
And if I use https://www.googleapis.com/oauth2/v4/token to do the same thing, everything is fine.
Is there anything changed in google identify platform? Thanks!
The OAuth endpoint has been updated a number of times over the last five years. I normally follow the one i the discovery doc but your example shows that that is not always the best course of action all of the time.
I have never heard of google shutting down old endpoints i suggest you use the one that works. As a side note i will contact Google to see if i can get some feed back as to why one call worked and the other didnt.