> For a complete documentation index, fetch https://docs.voximplant.ai/llms.txt

# GetAccountInfo

POST https://api.voximplant.com/platform_api/GetAccountInfo

Gets the account's info such as account_id, account_name, account_email etc.

**Example request:** Get the account's info.

Reference: https://docs.voximplant.ai/api-reference/management-api/reference/accounts/get-account-info

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: management-api
  version: 1.0.0
paths:
  /GetAccountInfo:
    post:
      operationId: get-account-info
      summary: GetAccountInfo
      description: >-
        Gets the account's info such as account_id, account_name, account_email
        etc.


        **Example request:** Get the account's info.
      tags:
        - subpackage_accounts
      parameters:
        - name: return_live_balance
          in: query
          description: Whether to get the account's live balance
          required: false
          schema:
            type: boolean
            default: true
        - name: Authorization
          in: header
          description: >-
            Voximplant Management API uses signed JWT tokens generated from your
            service-account private key. Pass the token in the `Authorization`
            header as a Bearer value:


            ```

            Authorization: Bearer $VOXIMPLANT_TOKEN

            ```


            See [Authorization](/api-reference/management-api/authorization) for
            ready-to-copy snippets in bash, Python, Node.js and Go that turn
            your `credentials.json` into a token.
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/accounts_GetAccountInfo_Response_200'
servers:
  - url: https://api.voximplant.com/platform_api
components:
  schemas:
    BillingLimitInfoType:
      type: object
      properties:
        min_amount:
          type: number
          format: double
          description: The minimum amount
        currency:
          type: string
          description: The currency
      description: The payment limit info.
      title: BillingLimitInfoType
    BankCardBillingLimitInfoType:
      type: object
      properties:
        min_amount:
          type: number
          format: double
          description: The minimum amount
        currency:
          type: string
          description: The currency
        max_day_payment:
          type: number
          format: double
      description: The payment limit info.
      title: BankCardBillingLimitInfoType
    BillingLimitsType:
      type: object
      properties:
        robokassa:
          $ref: '#/components/schemas/BillingLimitInfoType'
          description: The Robokassa limits
        bank_card:
          $ref: '#/components/schemas/BankCardBillingLimitInfoType'
          description: The bank card limits
        invoice:
          $ref: '#/components/schemas/BillingLimitInfoType'
          description: The invoice limits
      description: >-
        The payments limits applicable to each payment method. Payments that are
        beyond limits are declined.
      title: BillingLimitsType
    AccountInfoType:
      type: object
      properties:
        account_id:
          type: integer
          description: The account's ID
        account_name:
          type: string
          description: The account's name
        account_email:
          type: string
          description: The account's email
        api_key:
          type: string
          description: >-
            The account API key. Use password or api_key authentication to show
            the api_key
        account_first_name:
          type: string
          description: The first name
        account_last_name:
          type: string
          description: The last name
        created:
          type: string
          description: |-
            Timestamp in YYYY-MM-DD HH:mm:ss format.

            The UTC account created time in 24-h format: YYYY-MM-DD HH:mm:ss
        language_code:
          type: string
          description: >-
            The notification language code (2 symbols, ISO639-1). Examples: en,
            ru
        location:
          type: string
          description: >-
            The account location (timezone). Examples: America/Los_Angeles,
            Etc/GMT-8, Etc/GMT+10
        min_balance_to_notify:
          type: number
          format: double
          description: The min balance value to notify by email or SMS
        account_notifications:
          type: boolean
          description: Whether Voximplant notifications are required
        tariff_changing_notifications:
          type: boolean
          description: Whether Voximplant plan changing notifications are required
        news_notifications:
          type: boolean
          description: Whether Voximplant news notifications are required
        billing_address_name:
          type: string
          description: The company or businessman name
        billing_address_country_code:
          type: string
          description: >-
            The billing address country code (2 symbols, ISO 3166-1 alpha-2).
            Examples: US, RU, GB
        billing_address_address:
          type: string
          description: The office address
        billing_address_zip:
          type: string
          description: The office ZIP
        billing_address_phone:
          type: string
          description: The office phone number
        billing_address_state:
          type: string
          description: >-
            The office state (US) or province (Canada), up to 100 characters.
            Examples: California, Illinois, British Columbia
        active:
          type: boolean
          description: Whether the account is active
        frozen:
          type: boolean
          description: Whether account is blocked by Voximplant admins
        balance:
          type: number
          format: double
          description: The account's money
        credit_limit:
          type: number
          format: double
          description: The account's credit limit
        currency:
          type: string
          description: The currency code (USD, RUR, EUR, ...)
        support_robokassa:
          type: boolean
          description: Whether Robokassa payments are allowed
        support_bank_card:
          type: boolean
          description: Whether Bank card payments are allowed
        support_invoice:
          type: boolean
          description: Whether Bank invoices are allowed
        account_custom_data:
          type: string
          description: The custom data
        access_entries:
          type: array
          items:
            type: string
          description: The allowed access entries (the API function names)
        with_access_entries:
          type: boolean
          default: false
          description: Whether the admin user permissions are granted
        callback_url:
          type: string
          description: >-
            If URL is specified, Voximplant cloud makes HTTP POST requests to it
            when something happens. For a full list of reasons see the **type**
            field of the [AccountCallback] structure. The HTTP request has a
            JSON-encoded body that conforms to the [AccountCallbacks] structure
        callback_salt:
          type: string
          description: >-
            If salt string is specified, each HTTP request made by the
            Voximplant cloud toward the **callback_url** has a **salt** field
            set to MD5 hash of account information and salt. That hash can be
            used be a developer to ensure that HTTP request is made by the
            Voximplant cloud
        send_js_error:
          type: boolean
          description: Whether to send an email when a JS error occurs
        billing_limits:
          $ref: '#/components/schemas/BillingLimitsType'
          description: The payments limits applicable to each payment method
        a2p_sms_enabled:
          type: boolean
          description: Whether to activate one-way SMS
        max_sip_registrations:
          type: integer
        fixed_balance:
          type: number
          format: double
        money_on_hold:
          type: number
          format: double
        bank_card_provider:
          type: string
        enabled_3ds:
          type: boolean
        record_storage_id:
          type: integer
        mobile_phone:
          type: string
        allow_invoice:
          type: boolean
        is_bank_card_auto_charge_prohibited:
          type: boolean
        taxpayer_type:
          type: string
        custom_pricing:
          type: boolean
        grace_credit:
          type: integer
        record_storage_name:
          type: string
        credit_limit_aware_balance_notifications:
          type: boolean
        live_balance:
          type: number
          format: double
      description: The [GetAccountInfo] function result.
      title: AccountInfoType
    accounts_GetAccountInfo_Response_200:
      type: object
      properties:
        result:
          $ref: '#/components/schemas/AccountInfoType'
          description: Account's info as the [AccountInfoType] object instance
        api_address:
          type: string
          description: The preferred address for the Management API requests
        debugger_address:
          type: string
      title: accounts_GetAccountInfo_Response_200
  securitySchemes:
    JwtAuth:
      type: http
      scheme: bearer
      description: >-
        Voximplant Management API uses signed JWT tokens generated from your
        service-account private key. Pass the token in the `Authorization`
        header as a Bearer value:


        ```

        Authorization: Bearer $VOXIMPLANT_TOKEN

        ```


        See [Authorization](/api-reference/management-api/authorization) for
        ready-to-copy snippets in bash, Python, Node.js and Go that turn your
        `credentials.json` into a token.

```

## SDK Code Examples

```python Account's info
import requests

url = "https://api.voximplant.com/platform_api/GetAccountInfo"

payload = {}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.json())
```

```javascript Account's info
const url = 'https://api.voximplant.com/platform_api/GetAccountInfo';
const options = {
  method: 'POST',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Account's info
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.voximplant.com/platform_api/GetAccountInfo"

	payload := strings.NewReader("{}")

	req, _ := http.NewRequest("POST", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Account's info
require 'uri'
require 'net/http'

url = URI("https://api.voximplant.com/platform_api/GetAccountInfo")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
```

```java Account's info
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.post("https://api.voximplant.com/platform_api/GetAccountInfo")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{}")
  .asString();
```

```php Account's info
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('POST', 'https://api.voximplant.com/platform_api/GetAccountInfo', [
  'body' => '{}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

echo $response->getBody();
```

```csharp Account's info
using RestSharp;

var client = new RestClient("https://api.voximplant.com/platform_api/GetAccountInfo");
var request = new RestRequest(Method.POST);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift Account's info
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [] as [String : Any]

let postData = JSONSerialization.data(withJSONObject: parameters, options: [])

let request = NSMutableURLRequest(url: NSURL(string: "https://api.voximplant.com/platform_api/GetAccountInfo")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "POST"
request.allHTTPHeaderFields = headers
request.httpBody = postData as Data

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```