How to get the Calendly user and organization details which require to call the API - rest

I have created a account with Calendly and want to consume the API's. Here is the link for API's
I have created a token using "Personal Access Token" mechanism provided by Calendly.
If we refer the document, it require some parameter pass to the API like organization, user etc.
I have gone through all the account which I created in Calendly but not able to found these details. Here is the reference where I am expecting it.
Anyone has any idea how can I get this info in Calendly so I can able to call these API's.
Thanks,
Atul

Found the way to get the info.
If you have valid account and valid "Personal Access Token" then you can get the info by calling this API of Calendly.
Refer the screeshot:
This is how you get the details for the user and organization. Then this info you can use to call the API's.
Thanks,
Atul

Related

Facebook API - How do I create an ad account?

I am currently trying to create an ad account using fb's api. After checking out their documentation I ended up with this source. Here it states that we can make a call to
/{business_id}/adaccount given the appropriate body to create an ad account, and therefore I went to give it a try.
On my test, I tried sending a POST request to that endpoint:
POST {FB_API_PATH}/{business_id}/adaccount?access_token={FB_ACCESS_TOKEN}
BODY
{
"name": "Test",
"currency": "USD",
"timezone_id": 1,
"end_advertiser": "{FB_APP_ID}",
"media_agency": "{FB_AGENCY_ID}",
"partner": "NONE",
"funding_id": "{FB_FUNDING_ID}"
}
but ended up getting:
Unsupported post request. Object with ID '{business_id}' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api.
This is not because I'm using an incorrect {business_id}, all of my other test calls that are using the same {business_id} are working perfectly.
It seems to me that for some reason, I cannot make a call to /adaccount. I went to check the facebook graph explorer and wasn't able to get the autocomplete trigger for that endpoint when inputing the {business_id}.
Am I doing something wrong, or was this endpoint never working and I need to keep doing it manually?
You need to have Advanced Access to business_management permission.
You can submit app review for advanced access, if it approved, you can call /bm-id/adaccount to create ad account with required parameter.
Also, you can't create an ad account on a real FB user. It works with test users well, but you need special permissions from FB to do this on a real user's account.

How to make an api call anonymously with Sylius-standard?

I'm looking for a way with Sylius to dynamically display the product list. Like asking the server for a specific set of products (search with parameters I suppose) asynchronously.
The doc seems to suggest the use of oauth authentication is mandatory but it's not what I'd like, or at least not systematically. So my question is, can I and how can I make an api call for "public" parts like product list but anonymously?
Thank you.
From the documentation :
Sylius has the OAuth2 authorization configured. The authorization process is a standard procedure. Authorize as admin and enjoy the API!
User has to have the ROLE_API_ACCESS role in order to access /api resources
So unless you create your own public api set to display products informations this is not possible with base Sylius api.
You can use the SyliusShopApiPlugin, which is currently in development. With it you can make anonymous and public API calls, e.g.:
/shop-api/taxons/t-shirts/products/?channel=US_WEB
to get all products in the t-shirts category.
I didn't find yet any documentation, but you can check the tests, e.g. https://github.com/Sylius/SyliusShopApiPlugin/blob/master/tests/Controller/ShowProductCatalogApiTest.php to get more examples.

How would I create an access token for the NFL Shield API?

The NFL appears to have an API service here: https://api.nfl.com/docs/getting-started/index.html
Accessing the API endpoints requires obtaining an OAuth2 access token. Which, if I am not mistaken, requires a client_id and client_secret.
I have read through the documentation and I am not sure how I would obtain a client_id and client_secret. Is there something I am missing to create these?
Finally got an answer on this. The documentation does say that the API is public and free for everyone, but they changed that policy and haven't updated the documentation.
Hi Dominic,
Thanks for reaching out. As of Feb. 18th, the NFL has secured the APIs and will only grant access to contractual partners. Unfortunately, if you are NOT a NFL Partner you will no longer have access to the feeds or able to obtain access to this feed.
Thanks,
Jonathan Vu
Product Operations Manager

Search client transactions data

I'm building an application that resembles personal financing. For that, I need to fetch information about that customer's transactions.
I managed to run the GetBasicPersonalData example within the permissions service.
Here it says that requesting TRANSACTION_SEARCH will allow me to use TransactionSearch on behalf of the customer.
There is no such endpoint and calling the NVP service with METHOD=TransactionSearch and similarly constructed X-PAYPAL-AUTHORIZATION header doesn't do it either.
How can I use the token and token secret retrieved from the permissions service to list that customer's transactions?
Update: According to FAQ#6 here, the X-PAYPAL-AUTHORIZATION is supposed to be used to replace the USER, PWD, and SIGNATURE params. When I call the nvp service that way I get:
TIMESTAMP=2016%2d11%2d07T15%3a35%3a36Z&CORRELATIONID=f50b7296c2d28&ACK=Failure&VERSION=94%2e0&BUILD=24616352&L_ERRORCODE0=10002&L_SHORTMESSAGE0=Authentication%2fAuthorization%20Failed&L_LONGMESSAGE0=You%20do%20not%20have%20permissions%20to%20make%20this%20API%20call&L_SEVERITYCODE0=Error
I'd like to share below useful documents for your reference:
TransactionSearch API guide here;
TransactionSearch API reference here;
PayPal API Endpoint here(Refere Merchant APIs);

Facebook graph api returns no email

I'm calling
https://graph.facebook.com/<user_id>/?access_token=<valid_token>
or just
https://graph.facebook.com/me/?access_token=<valid_token>
and getting back json object that doesn't contain primary user email which I need.
I setup email permission for the app and no effect.
What can be wrong?
Did you remember to ask for the email permission in the login request? You do this by adding the scope parameter like this in the login request (&scope=email):
https://www.facebook.com/dialog/oauth?client_id=YOUR_APP_ID&redirect_uri=YOUR_REDIRECT_URI&state=SOME_ARBITRARY_BUT_UNIQUE_STRING&scope=email
Facebook API reference
You probably do not have email permissions in your access token.
You can verify it with the Acess Token Debugger
I believe that your question is, even after granting permission to access email, you are not able to get email information through the Graph API. In newer versions, you need to pass fields param to the API to get additional information such as email. By default, it only provides id and name in response. Please find a sample below on how to get other info from graph :
https://graph.facebook.com/me?fields=id,email,first_name,gender,last_name,link,locale,name,timezone,updated_time,verified&access_token=<value of access_token>&debug=all
Hope this helps.
It is possible that the email is not verified in facebook. In this case facebook doesn't make it available via the API. Make sure your code handles this case.
Since the release of API version 2.5 you can get user email like this: https://graph.facebook.com/v2.5/me?fields=id,name,email