curl --request PATCH \
--url https://api.recoupable.dev/api/accounts \
--header 'Content-Type: application/json' \
--data '
{
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"instruction": "<string>",
"organization": "<string>",
"image": "<string>",
"jobTitle": "<string>",
"roleType": "<string>",
"companyName": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
'import requests
url = "https://api.recoupable.dev/api/accounts"
payload = {
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"instruction": "<string>",
"organization": "<string>",
"image": "<string>",
"jobTitle": "<string>",
"roleType": "<string>",
"companyName": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
accountId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
name: '<string>',
instruction: '<string>',
organization: '<string>',
image: '<string>',
jobTitle: '<string>',
roleType: '<string>',
companyName: '<string>',
knowledges: [{url: '<string>', name: '<string>', type: '<string>'}]
})
};
fetch('https://api.recoupable.dev/api/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.recoupable.dev/api/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'accountId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'name' => '<string>',
'instruction' => '<string>',
'organization' => '<string>',
'image' => '<string>',
'jobTitle' => '<string>',
'roleType' => '<string>',
'companyName' => '<string>',
'knowledges' => [
[
'url' => '<string>',
'name' => '<string>',
'type' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.recoupable.dev/api/accounts"
payload := strings.NewReader("{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.recoupable.dev/api/accounts")
.header("Content-Type", "application/json")
.body("{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.recoupable.dev/api/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"email": "jsmith@example.com",
"wallet": "<string>",
"image": "<string>",
"instruction": "<string>",
"organization": "<string>",
"job_title": "<string>",
"role_type": "<string>",
"company_name": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
}{
"status": "error",
"message": "<string>"
}{
"status": "error",
"message": "<string>"
}{
"status": "error",
"message": "<string>"
}Update Account
Update an existing account’s profile information including name, organization, image, instruction, job title, role type, company name, and knowledges. Requires authentication via x-api-key or Authorization Bearer token. The authenticated account may update itself or a permitted account_id override.
curl --request PATCH \
--url https://api.recoupable.dev/api/accounts \
--header 'Content-Type: application/json' \
--data '
{
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"instruction": "<string>",
"organization": "<string>",
"image": "<string>",
"jobTitle": "<string>",
"roleType": "<string>",
"companyName": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
'import requests
url = "https://api.recoupable.dev/api/accounts"
payload = {
"accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"instruction": "<string>",
"organization": "<string>",
"image": "<string>",
"jobTitle": "<string>",
"roleType": "<string>",
"companyName": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
accountId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
name: '<string>',
instruction: '<string>',
organization: '<string>',
image: '<string>',
jobTitle: '<string>',
roleType: '<string>',
companyName: '<string>',
knowledges: [{url: '<string>', name: '<string>', type: '<string>'}]
})
};
fetch('https://api.recoupable.dev/api/accounts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.recoupable.dev/api/accounts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'accountId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'name' => '<string>',
'instruction' => '<string>',
'organization' => '<string>',
'image' => '<string>',
'jobTitle' => '<string>',
'roleType' => '<string>',
'companyName' => '<string>',
'knowledges' => [
[
'url' => '<string>',
'name' => '<string>',
'type' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.recoupable.dev/api/accounts"
payload := strings.NewReader("{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://api.recoupable.dev/api/accounts")
.header("Content-Type", "application/json")
.body("{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.recoupable.dev/api/accounts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"accountId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"name\": \"<string>\",\n \"instruction\": \"<string>\",\n \"organization\": \"<string>\",\n \"image\": \"<string>\",\n \"jobTitle\": \"<string>\",\n \"roleType\": \"<string>\",\n \"companyName\": \"<string>\",\n \"knowledges\": [\n {\n \"url\": \"<string>\",\n \"name\": \"<string>\",\n \"type\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"email": "jsmith@example.com",
"wallet": "<string>",
"image": "<string>",
"instruction": "<string>",
"organization": "<string>",
"job_title": "<string>",
"role_type": "<string>",
"company_name": "<string>",
"knowledges": [
{
"url": "<string>",
"name": "<string>",
"type": "<string>"
}
]
}
}{
"status": "error",
"message": "<string>"
}{
"status": "error",
"message": "<string>"
}{
"status": "error",
"message": "<string>"
}Body
Account fields to update
The unique identifier of the account to update
Display name for the account
Custom instruction or bio for the account
Organization name associated with the account
URL of the account's profile image
Job title of the account holder
Role type within the organization
Company name associated with the account
Knowledge base files attached to this account
Show child attributes
Show child attributes
Response
Account updated successfully
The account data
Show child attributes
Show child attributes
Was this page helpful?
