> For a complete page index, fetch https://docs.transak.com/llms.txt # Submit Source of Income POST https://api-gateway-stg.transak.com/api/v2/user/source-of-income Content-Type: application/json **Submit Source of Income** is an **authenticated** API call that allows the submission of a user’s income source details as part of the KYC verification process. This step may be mandatory based on jurisdictional or regulatory requirements and is used for compliance validation. The valid source of income information must be provided as part of the **Enhanced KYC flow** Reference: https://docs.transak.com/api/whitelabel/kyc/submit-source-of-income ## Request ### Headers - `x-user-ip` (string, required) — End user's originating IP. More details [here](/guides/mandatory-security-changes#user-ip-header-in-apis) - `x-api-key` (string, required) — Partner API Key present in Transak Dashboard. - `authorization` (string, optional) — Authorization token is the accessToken received from the API -` api/v2/auth/verify` Note: This is not applicable for [Auth Reliance Flows](/features/auth-reliance) - `x-user-identifier` (string, optional) — Your authenticated user Email Id address. Note: This is applicable only for [Auth Reliance Flows](/features/auth-reliance) - `x-access-token` (string, optional) — Your Partner Access Token. Please refer [here](/guides/how-to-create-partner-access-token) for a tutorial on generating your access token. Note: This is applicable only for [Auth Reliance Flows](/features/auth-reliance) ### Body (application/json) This endpoint expects an object. - `monthlyVolume` (string, required) - `sourceOfFundsType` (string, required) — value from SOURCE_OF_INCOME form options ## Response ### 200 200 - Success - `data` (ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaData, required) ## Errors ### 400 Bad Request Error 400 - Bad Request - `error` (ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaError, required) ### 401 Unauthorized Error 401 - Unauthorized - `error` (ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaError, required) ### 404 Not Found Error 404 - User Not Found - `error` (ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaError, required) ### 500 Internal Server Error 500 - Internal Server Error - `error` (ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaError, required) ## Types ### ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaData - `status` (string, required) ### ApiV2UserSourceOfIncomePostResponsesContentApplicationJsonSchemaError - `statusCode` (integer, required) - `message` (string, required) ## Examples **Request** ```json { "monthlyVolume": "", "sourceOfFundsType": "" } ``` **Response** ```json { "data": { "status": "SUBMITTED" } } ``` **SDK Code** ```python Submitted Source of Income import requests url = "https://api-gateway-stg.transak.com/api/v2/user/source-of-income" payload = { "monthlyVolume": "", "sourceOfFundsType": "" } headers = { "x-api-key": "", "x-user-ip": "", "Content-Type": "application/json" } response = requests.post(url, json=payload, headers=headers) print(response.json()) ``` ```javascript Submitted Source of Income const url = 'https://api-gateway-stg.transak.com/api/v2/user/source-of-income'; const options = { method: 'POST', headers: {'x-api-key': '', 'x-user-ip': '', 'Content-Type': 'application/json'}, body: '{"monthlyVolume":"","sourceOfFundsType":""}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go Submitted Source of Income package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api-gateway-stg.transak.com/api/v2/user/source-of-income" payload := strings.NewReader("{\n \"monthlyVolume\": \"\",\n \"sourceOfFundsType\": \"\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("x-api-key", "") req.Header.Add("x-user-ip", "") 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 Submitted Source of Income require 'uri' require 'net/http' url = URI("https://api-gateway-stg.transak.com/api/v2/user/source-of-income") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["x-api-key"] = '' request["x-user-ip"] = '' request["Content-Type"] = 'application/json' request.body = "{\n \"monthlyVolume\": \"\",\n \"sourceOfFundsType\": \"\"\n}" response = http.request(request) puts response.read_body ``` ```java Submitted Source of Income import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api-gateway-stg.transak.com/api/v2/user/source-of-income") .header("x-api-key", "") .header("x-user-ip", "") .header("Content-Type", "application/json") .body("{\n \"monthlyVolume\": \"\",\n \"sourceOfFundsType\": \"\"\n}") .asString(); ``` ```php Submitted Source of Income request('POST', 'https://api-gateway-stg.transak.com/api/v2/user/source-of-income', [ 'body' => '{ "monthlyVolume": "", "sourceOfFundsType": "" }', 'headers' => [ 'Content-Type' => 'application/json', 'x-api-key' => '', 'x-user-ip' => '', ], ]); echo $response->getBody(); ``` ```csharp Submitted Source of Income using RestSharp; var client = new RestClient("https://api-gateway-stg.transak.com/api/v2/user/source-of-income"); var request = new RestRequest(Method.POST); request.AddHeader("x-api-key", ""); request.AddHeader("x-user-ip", ""); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"monthlyVolume\": \"\",\n \"sourceOfFundsType\": \"\"\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift Submitted Source of Income import Foundation let headers = [ "x-api-key": "", "x-user-ip": "", "Content-Type": "application/json" ] let parameters = [ "monthlyVolume": "", "sourceOfFundsType": "" ] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api-gateway-stg.transak.com/api/v2/user/source-of-income")! 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() ```