How to call Bitrix24's API using Postman? - api

I researched on google and I'm stuck while I try to find out Bitrix24 API docs for users using PostMan. Is there an available resource that could help me solve my trouble? , I hope I could retrieve a document or some things like this. Thanks for reading <3

Try this endpoint on your postman
https://example.bitrix24.id/rest/crm.product.list
This is for the CRM Product List
https://training.bitrix24.com/rest_help/crm/products/crm_product_list.php
if this dosent work you can put .json
https://example.bitrix24.id/rest/crm.product.list.json
for the authentication you can go to Developer Resources - Other - Local Application
and put Postman callback on the Handler (https://oauth.pstmn.io/v1/callback).
dont forget to click the Script Only.

Related

Twinfield API: how to get accesstoken using postman?

I'm trying to connect to the Twinfield API. I have registered an app in the developer portal, and created a callback URI. My call looks as follows:
https://login.twinfield.com/auth/authentication/connect/authorize?redirect_uri=https://oauth.pstmn.io/v1/callback&response_type=id_token+token&client_id=###&client_secret=#####
Link to twinfield api documentation
However I get the error stating that the client application is not known or is not authorized.
Can someone help me with this problem?
Think you are missing the code, see below the response_type
&response_type=code&scope=openid+twf.user+twf.organisation+twf.organisationUser+offline_access&redirect_uri=https://oauth.pstmn.io/v1/callback&
Once you've run this, you get a code and together with basic64encoding of your client_id:client_secret would profide you an access code.
The whole request should look like:
https://login.twinfield.com/auth/authentication/connect/authorize?client_id={xxxx}&response_type=code&scope=openid+twf.user+twf.organisation+twf.organisationUser+offline_access&redirect_uri=https://oauth.pstmn.io/v1/callback&state=SOME_RANDOM_STATE&nonce=SOME_RANDOM_NONCE
for me to get this working in postman I need to copy the whole link into the browser, login there and then get from the return link the code when you see the page "Your call is authenticated"

Try it out functionality of tmdb api not working

When I tried to see data through try it out functionality then it is showing the following error
Error: Network Error
Check the developer tools console, it might have more information on the error.
If you are using an Adblocker, it is possible your Adblocker is blocking the request.
I also tried after disabling adblocker but it also does not work
console showing like this
Why this is happening and what is the solution for this?
Thanks in advance
Try the url in your browser with the API key. You can see the response.
Example :
https://api.themoviedb.org/3/movie/popular?api_key=your_api_key
Found out this is due to extension 'stoplight' in their site. Site Manager has said
"I believe Stoplight has temporarily blocked the "Try it out" feature for our account because too many people were using it as the source
for their apps, and not using api.themoviedb.org for some reason. No
timeline on getting it restored, but that's the problem. - Travis Bell"
follow this thread, In case it gets sorted in future.
https://www.themoviedb.org/talk/600184fc6aa8e0004077e364?page=1#6001bbacbe4b36003d514ac3
Apparently it depends on the way you try to access the data.
In my React application I was using Axios.Which ended up with ReferenceError: response is not defined. (got no response)
Afterwards I tried using the javascript fetch API. It worked good for me
So if you are trying to use it in an app you might want to use the fetch API. If you just encounter network error while using Try it out function on site - then you can copy the link and paste it directly, it should work fine.
Currently, I am using it in my dashboard and I have JWT authentication for the API that I'm using. I have implemented the interceptor to update HTTP HEADERS so I saw I'm passing a header name 'token' and checked there if any unnecessary headers were given or not with not accepting the TMDB API server. So I have sent a clean HTTP request and it's working fine.
All you have to just remove the unnecessary HTTP HEADERS

How to access OData URLs with authentication

I have a OData Server which returns me a json.
When I accessing the URL through a browser i need to input the username/password.
Doesn't accept the entries which I do in the pop-up. Need to cancel it and then it shows me a dialog box after which i can see the required json.
I am not able to figure out the kind of authentication in use.
Using basic authentication in Postman client is not working.
Any suggestions as to how do I go about using this URL both in postman and inside an Anuglar JS or Node JS program.
You can install interceptor in postman. Go to cookies tab next to body and install the interceptor then turn it on.After installing interceptor you can login with your user/pass and then send your request.
See this picture.enter image description here
Thanks for the input.
But I got access to the code implementation which is accessing the URI which I want.
So There is a Sharepoint/C# application in the universe which is doing a Forms based authentication to get the data required. :/
Will try to reverse engineer that get it working in my Node App.
Cheers. :)

Shopify private app api post request

I am writing a private integration app from MS NAV to shopify api. I can use the api for Get Request, e.g.
https://API_KEY:PASSWORD#wolf-wiegand-and-davis1433.myshopify.com/admin/orders.xml
However, the post request doesn't work for this formate: https://API_KEY:PASSWORD#wolf-wiegand-and-davis1433.myshopify.com/admin/products.xml.
I got a 403 status error.
anyone knows what could be wrong? or the api doesn't support post for the request.
thanks.
It appears that your app's permissions have been corrupted. Creating a new app will give you credentials that should include all permissions.
the response xml, it seems a permision issue :
You do not have products write permissions.

Access an “Anyone with the link” Google Spreadsheet via the API

Try the following workflow:
Create a Google Spreadsheet. Set its ACL to “Anyone with the link”
Get its key (https://spreadsheets0.google.com/spreadsheet/ccc?key=HEREISTHEKEY)
Try accessing it with the HTTP API: https://spreadsheets.google.com/feeds/list/HEREISTHEKEY/o6d/public/full (try with private instead of public also)
Get a 404 error
It seems that the Google Spreadsheet API does not allow accessing a private link from the API when you are not authenticated, but maybe I'm wrong somewhere.
It's kind of illogical because you don't need to be logged in when accessing this spreadsheet from a browser.
Any thoughts (I'll fill up a bug report)?
Thanks!
One thought, and I'm not sure if this is applicable to your situation, is that you might try building a dummy Google account and having your interface access the HTTP API using those dummy credentials. It's dirty, but it might work, as once you're logged in you should definitely be authenticated. Right?
To be able to access it via the API, you need to "publish" the spreadsheet. You can do this via the file menu:
File > "Publish to the web..."
You'll then be able it via the API with the URL you gave. I had this issue initially too!