REST call /transactions only returns sent transaction? - aptos

This REST call only returns sent transactions - is there a way to get all transactions for an account via the REST API?
curl "https://fullnode.mainnet.aptoslabs.com/v1/accounts/0xae1a6f3d3daccaf77b55044cea133379934bba04a11b9d0bbd643eae5e6e9c70/transactions?start=69794&limit=25"

Related

Can we get data as Response using Post Method for API Testing using RestAssured Cucumber

Here is the full question :
As a Portfolio API, I should be able to retrieve details for a given Account and Account type from Balance API, so that i can pass over the same to the UI for the end users to view the same.
Scenario 1 - Verify the response when Portfolio API invokes the
POST /v1/accDetails endpoint for a given account details (Checking)
Given client has a valid auth token for the api
And Portfolio API has the following
Account Number 1234567890 (10 characters).
Account Type 'CHQ' (3 characters)
When Portfolio API sends a POST request to Balance API
Then Portfolio API will receive the response code as <00>
And response body will have the following (not limited to below fields)
Account Type, Account Number, Account ID, Account Name, Account Balance, Product TypABA Number, Interest Rate, Interest Earned to DateStatus.
Now my question is we can do this using GET Method but can we do this using POST method or not? When we use post that mean we are going to add something but I do not want to add any account. I just want to get account details.
Since you have only a few parameters to send via GET, the best approach is to use [GET].
We can use the [POST] if we really need it to do so.
But if you can use [GET] for that, then the best approach is to use [GET].
Also can refer: REST API using POST instead of GET.

Yodlee get_accounts sometimes returns zero result / empty response

Here is the scenario:
User logins to the bank successfully (via Fastlink)
Right after user logs in, I get user's provider_accounts (via /providerAccounts API)
Then when I call to get the accounts, (via /accounts) I sometimes get empty response (zero accounts found?)
When I try later (seconds or minutes after) I get some accounts information back.
Is this because Yodlee is still trying to gather account information when I'm making /accounts api call?
This is because the accounts are still being added/linked.
Using the requestId and providerAccountId provided by FastLink callback, you need to poll continuously to know the refresh status of the account linking process and once it's done, you can call the get accounts.
Read more about the refresh status in the "Add/Update Account Process Status" section.
Yodlee makes things easier now with webhooks. Read more here:
Using Webhooks with the Yodlee Core API
TL/DR: You need to wait for the add/link completion before retrieving the accounts.

How to send Trustpilot invitations through Trustpilot API?

In our app we are using this API call to retrieve our average rating score and display it on our website:
https://api.trustpilot.com/v1/business-units/{{BUSINESS_UNIT_ID}}/?apikey={{API_KEY}}
This works great.
Now if we want to send an invitation to rate our services to one of our customers, we use a very similar API call:
https://invitations-api.trustpilot.com/v1/private/business-units/{{BUSINESS_UNIT_ID}}/invitations?apikey={{API_KEY}}
Unfortunately, this doesn't work. We are getting this error:
{"fault":{"faultstring":"Invalid access token","detail":{"errorcode":"oauth.v2.InvalidAccessToken"}}}
What are we missing here?
We can't see why our API key works for the first call, but not for the second.
Thanks for any help.
In the first API call you are calling a public endpoint. For all public endpoints API key is enough because you are not accessing restricted data.
For your second API call (the invitations one), you are calling a private endpoint.
For all private APIs you need to authenticate yourself using the OAuth2 flow and include the access token in your request.
You can read more about the flow at:
https://developers.trustpilot.com/authentication

How to get payout using PayPal API, with only batch_sender_id

Sometimes the PayPal API fails to give back a payout_id but still processes a payment (i.e. because the server is down).
I have some payments that I would like to fetch information for, but only have the batch_sender_id (the id that I gave each payment).
Is there a way to get the payment information with PayPal's API? There doesn't seem to be a way to fetch payments without the payout_id.
Resubmit with the same batch_sender_id, it should return html code 400 with a link to the resource that contains the previously submitted request. So before making a request to PayPal be sure to store the batch_sender_id so you can re-request later if you do not get a response.

Retrieve MemSiteAccId from Yodlee

The API Call - getSiteRefreshInfo in Yodlee API asks for the memSiteAccId.
I thought it is the same as itemAccountId that we got from Transactions. However, its not the same. Then, how do I retrieve memSiteAccId ?
Whenever you add an account using Site Based API(addSiteAccount1) you'll get- siteAccountId in the response. This is same as MemSiteAccountId, and you need to use the same to pass as an input in getSiteRefreshInfo.