> This page is for Web API.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://ibkrcampus.com/docs/llms.txt.

# Get Required Forms

GET https://localhost:5000/gw/api/v1/forms/required-forms

Get required forms**Scope**: `accounts.read`**Security Policy**: `HTTPS`

Reference: https://ibkrcampus.com/docs/web-api/api-reference/account-management/account-management-utilities/list-forms-required-forms

## Authentication

- `Authorization` header (bearer token, required) — RS256-signed JWT access token signed with your registered private key.

## Servers

- `https://localhost:5000` (Client Portal Gateway, default)
- `https://api.ibkr.com` (Production)
- `https://qa.interactivebrokers.com` (Sandbox)

## Request

### Query parameters

- `requiredFormsRequest` (RequiredFormsRequest, required)

## Response

### 200

Get required forms

- `forms` (list of string, optional)
- `error` (ErrorResponse, optional)
- `hasError` (boolean, optional)
- `errorDescription` (string, optional)

## Errors

### 400 Bad Request Error

Returns error description representing bad request

- `type` (string, optional)
- `title` (string, optional)
- `status` (long, optional)
- `detail` (string, optional)
- `instance` (string, optional)

### 401 Unauthorized Error

Returns error description representing access issue

- `type` (string, optional)
- `title` (string, optional)
- `status` (long, optional)
- `detail` (string, optional)
- `instance` (string, optional)

### 403 Forbidden Error

Returns error description representing access issue

- `type` (string, optional)
- `title` (string, optional)
- `status` (long, optional)
- `detail` (string, optional)
- `instance` (string, optional)

### 500 Internal Server Error

Returns error description representing internal server error

- `type` (string, optional)
- `title` (string, optional)
- `status` (long, optional)
- `detail` (string, optional)
- `instance` (string, optional)

## Types

### RequiredFormsRequest

- `residenceCountry` (string, optional)
- `accountType` (string, optional)
- `applicantType` (string, optional)
- `processType` (string, optional)
- `ira` (boolean, optional)
- `iraType` (string, optional)
- `requestedSYEP` (boolean, optional)
- `requestedFCBP` (boolean, optional)
- `additionalAccount` (boolean, optional)
- `additionalApplicant` (boolean, optional)
- `mifidCategory` (string, optional)
- `tradingPermissions` (list of string, optional)
- `capability` (list of string, optional)
- `faTradingAccount` (boolean, optional)

### ErrorResponse

- `status` (long, optional)
- `error` (string, optional)
- `message` (string, optional)

## Examples

**Request**

```json
{
  "accountType": "Individual",
  "additionalAccount": false,
  "additionalApplicant": false,
  "applicantType": "Primary",
  "capability": [
    "Margin",
    "ShortSelling"
  ],
  "faTradingAccount": false,
  "ira": false,
  "iraType": "",
  "mifidCategory": "Professional",
  "processType": "NewAccount",
  "requestedFCBP": false,
  "requestedSYEP": false,
  "residenceCountry": "US",
  "tradingPermissions": [
    "Stocks",
    "Options"
  ]
}
```

**Response**

```json
{
  "forms": [
    "W-9",
    "Client Agreement",
    "Margin Agreement"
  ],
  "error": {
    "status": 0,
    "error": "",
    "message": ""
  },
  "hasError": false,
  "errorDescription": ""
}
```

**SDK Code**

```python
import requests

url = "https://localhost:5000/gw/api/v1/forms/required-forms"

querystring = {"requiredFormsRequest":"{}"}

payload = {
    "accountType": "Individual",
    "additionalAccount": False,
    "additionalApplicant": False,
    "applicantType": "Primary",
    "capability": ["Margin", "ShortSelling"],
    "faTradingAccount": False,
    "ira": False,
    "iraType": "",
    "mifidCategory": "Professional",
    "processType": "NewAccount",
    "requestedFCBP": False,
    "requestedSYEP": False,
    "residenceCountry": "US",
    "tradingPermissions": ["Stocks", "Options"]
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.get(url, json=payload, headers=headers, params=querystring)

print(response.json())
```

```javascript
const url = 'https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D';
const options = {
  method: 'GET',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: '{"accountType":"Individual","additionalAccount":false,"additionalApplicant":false,"applicantType":"Primary","capability":["Margin","ShortSelling"],"faTradingAccount":false,"ira":false,"iraType":"","mifidCategory":"Professional","processType":"NewAccount","requestedFCBP":false,"requestedSYEP":false,"residenceCountry":"US","tradingPermissions":["Stocks","Options"]}'
};

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

```go
package main

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

func main() {

	url := "https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D"

	payload := strings.NewReader("{\n  \"accountType\": \"Individual\",\n  \"additionalAccount\": false,\n  \"additionalApplicant\": false,\n  \"applicantType\": \"Primary\",\n  \"capability\": [\n    \"Margin\",\n    \"ShortSelling\"\n  ],\n  \"faTradingAccount\": false,\n  \"ira\": false,\n  \"iraType\": \"\",\n  \"mifidCategory\": \"Professional\",\n  \"processType\": \"NewAccount\",\n  \"requestedFCBP\": false,\n  \"requestedSYEP\": false,\n  \"residenceCountry\": \"US\",\n  \"tradingPermissions\": [\n    \"Stocks\",\n    \"Options\"\n  ]\n}")

	req, _ := http.NewRequest("GET", 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
require 'uri'
require 'net/http'

url = URI("https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D")

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

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"accountType\": \"Individual\",\n  \"additionalAccount\": false,\n  \"additionalApplicant\": false,\n  \"applicantType\": \"Primary\",\n  \"capability\": [\n    \"Margin\",\n    \"ShortSelling\"\n  ],\n  \"faTradingAccount\": false,\n  \"ira\": false,\n  \"iraType\": \"\",\n  \"mifidCategory\": \"Professional\",\n  \"processType\": \"NewAccount\",\n  \"requestedFCBP\": false,\n  \"requestedSYEP\": false,\n  \"residenceCountry\": \"US\",\n  \"tradingPermissions\": [\n    \"Stocks\",\n    \"Options\"\n  ]\n}"

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

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"accountType\": \"Individual\",\n  \"additionalAccount\": false,\n  \"additionalApplicant\": false,\n  \"applicantType\": \"Primary\",\n  \"capability\": [\n    \"Margin\",\n    \"ShortSelling\"\n  ],\n  \"faTradingAccount\": false,\n  \"ira\": false,\n  \"iraType\": \"\",\n  \"mifidCategory\": \"Professional\",\n  \"processType\": \"NewAccount\",\n  \"requestedFCBP\": false,\n  \"requestedSYEP\": false,\n  \"residenceCountry\": \"US\",\n  \"tradingPermissions\": [\n    \"Stocks\",\n    \"Options\"\n  ]\n}")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D', [
  'body' => '{
  "accountType": "Individual",
  "additionalAccount": false,
  "additionalApplicant": false,
  "applicantType": "Primary",
  "capability": [
    "Margin",
    "ShortSelling"
  ],
  "faTradingAccount": false,
  "ira": false,
  "iraType": "",
  "mifidCategory": "Professional",
  "processType": "NewAccount",
  "requestedFCBP": false,
  "requestedSYEP": false,
  "residenceCountry": "US",
  "tradingPermissions": [
    "Stocks",
    "Options"
  ]
}',
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'Content-Type' => 'application/json',
  ],
]);

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

```csharp
using RestSharp;

var client = new RestClient("https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer <token>");
request.AddHeader("Content-Type", "application/json");
request.AddParameter("application/json", "{\n  \"accountType\": \"Individual\",\n  \"additionalAccount\": false,\n  \"additionalApplicant\": false,\n  \"applicantType\": \"Primary\",\n  \"capability\": [\n    \"Margin\",\n    \"ShortSelling\"\n  ],\n  \"faTradingAccount\": false,\n  \"ira\": false,\n  \"iraType\": \"\",\n  \"mifidCategory\": \"Professional\",\n  \"processType\": \"NewAccount\",\n  \"requestedFCBP\": false,\n  \"requestedSYEP\": false,\n  \"residenceCountry\": \"US\",\n  \"tradingPermissions\": [\n    \"Stocks\",\n    \"Options\"\n  ]\n}", ParameterType.RequestBody);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
]
let parameters = [
  "accountType": "Individual",
  "additionalAccount": false,
  "additionalApplicant": false,
  "applicantType": "Primary",
  "capability": ["Margin", "ShortSelling"],
  "faTradingAccount": false,
  "ira": false,
  "iraType": "",
  "mifidCategory": "Professional",
  "processType": "NewAccount",
  "requestedFCBP": false,
  "requestedSYEP": false,
  "residenceCountry": "US",
  "tradingPermissions": ["Stocks", "Options"]
] as [String : Any]

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

let request = NSMutableURLRequest(url: NSURL(string: "https://localhost:5000/gw/api/v1/forms/required-forms?requiredFormsRequest=%7B%7D")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
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()
```