#Nishanth-reports
1 messages ยท Page 1 of 1 (latest)
Also is there no API endpoint to download the csv directly without the username and password?
@zenith vale Can you plz help me?
We give you details on how to retrieve the results of you report run here:
For authentication your API key is the user name, and we don't need a password (see https://stripe.com/docs/api/authentication?lang=curl)
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Thanks, can you please keep this conversation open for an hour?
So that I can ask any doubts I get
We usually leave threads open an hour and then close them if we haven't heard from you - if your thread gets closed just let us konw and we can always reopen it
Okay thanks. What is the average time required for the report status to change from "pending" to "succeeded"?
So that I can include a Delay in my code
There is not "average time" - it really depends on the kind of report and how much data is being processed
okay
Hi, need some more help
How do I authorize through the code? I am getting 401 unauthorized with the below code:
WebClient webClient = new WebClient();
webClient.Headers.Add(HttpRequestHeader.Authorization, key);
var data = webClient.DownloadData(response.Result.Url.ToString());
hey there @queen coyote -- can you share the request ID of the error you encounter?
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Find help and support for Stripe. Our support center provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.
frr_1KGqJxDR9GxscM5OaXnBoela
Its just a 401 Unauthorized error
I wanted to know how do we authorize the request via C# code. I tried adding headers but didn't work
Sure but can you share the request ID? Do you have a request-id header in the response you receive?
Are you using the dotnet stripe client, or making manual HTTP requests?
Request ID : frr_1KGqJxDR9GxscM5OaXnBoela
I'm using the dotnet stripe client but using WebClient to download the csv to local computer. Do let me know if there is a better alternative?
I was able to authorize it using below:
webClient.Credentials = new NetworkCredential(key, key);
How do I set the report columns to "All"?
that is not a request id, that is a report id. a request id looks like req_123456
No prob, I figured out how to authorize the request
Hmm I'm not sure what WebClient is or how it works.
You got your key added in the header?
Excellent ๐
Yes, it worked
๐
Can you help me with
How do I set the report columns to "All"?
I mean here
var options = new ReportRunCreateOptions
{
ReportType = "connected_account_balance_change_from_activity.itemized.1",
Parameters = new ReportRunParametersOptions
{
IntervalStart = new DateTime(2021, 12, 1),
IntervalEnd = new DateTime(2022, 1, 10),
ConnectedAccount = "acct_1GhhMiEzb8Wd40Wx",
},
};
I don't believe "all" is an option, you either omit the array to get the default set or provide an explicit array of columns: https://stripe.com/docs/api/reporting/report_run/create#create_reporting_report_run-parameters-columns
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
NP!