All URIs are relative to https://scrapebadger.com
| Method | HTTP request | Description |
|---|---|---|
| AccountGetAccountInfo | GET /v1/account/me | Get account info |
AccountInfo AccountGetAccountInfo ()
Get account info
Get account details for the authenticated API key. Returns credit balances, tier, rate limit, and subscription details. No credits are deducted for this call.
using System.Collections.Generic;
using System.Diagnostics;
using System.Net.Http;
using ScrapeBadger.Api;
using ScrapeBadger.Client;
using ScrapeBadger.Model;
namespace Example
{
public class AccountGetAccountInfoExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://scrapebadger.com";
// Configure API key authorization: ApiKeyAuth
config.AddApiKey("X-API-Key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("X-API-Key", "Bearer");
// create instances of HttpClient, HttpClientHandler to be reused later with different Api classes
HttpClient httpClient = new HttpClient();
HttpClientHandler httpClientHandler = new HttpClientHandler();
var apiInstance = new AccountApi(httpClient, config, httpClientHandler);
try
{
// Get account info
AccountInfo result = apiInstance.AccountGetAccountInfo();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling AccountApi.AccountGetAccountInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Get account info
ApiResponse<AccountInfo> response = apiInstance.AccountGetAccountInfoWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling AccountApi.AccountGetAccountInfoWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Successful Response | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]