curl --request PATCH \
--url https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"shares": 1500.5
}
'import requests
url = "https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}"
payload = { "shares": 1500.5 }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({shares: 1500.5})
};
fetch('https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}', 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.syntage.com/shareholders/{shareholderId}/relations/{relationId}",
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([
'shares' => 1500.5
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.syntage.com/shareholders/{shareholderId}/relations/{relationId}"
payload := strings.NewReader("{\n \"shares\": 1500.5\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.syntage.com/shareholders/{shareholderId}/relations/{relationId}")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"shares\": 1500.5\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"shares\": 1500.5\n}"
response = http.request(request)
puts response.read_body{
"id": "82cd9012-3456-7890-abcd-ef1234567890",
"link": "/entities/91ab5678-1234-5678-9abc-def012345678",
"shareholder": {
"id": "91ab5678-1234-5678-9abc-def012345678",
"name": "JUAN MANUEL PEREZ GONZALEZ",
"type": "physical",
"rfc": "PEIC211118IS0",
"relations": "<array>",
"entity": "/entities/91ab5678-1234-5678-9abc-def012345678",
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678",
"@type": "Shareholder"
},
"relationType": "shareholders",
"sources": [
{
"id": "73de0123-4567-8901-bcde-f23456789012",
"relation": "<unknown>",
"shareholder": {
"id": "91ab5678-1234-5678-9abc-def012345678",
"name": "JUAN MANUEL PEREZ GONZALEZ",
"type": "physical",
"rfc": "PEIC211118IS0",
"relations": "<array>",
"entity": "/entities/91ab5678-1234-5678-9abc-def012345678",
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678",
"@type": "Shareholder"
},
"sourceName": "manual",
"sourceId": "64ef1234-5678-9012-cdef-345678901234",
"shares": 1500.5,
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678/relations/82cd9012-3456-7890-abcd-ef1234567890/sources/73de0123-4567-8901-bcde-f23456789012",
"@type": "ShareholderRelationsSource"
}
],
"shares": 1500.5,
"totalShares": 10000,
"ownership": 0.15,
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678/relations/82cd9012-3456-7890-abcd-ef1234567890",
"@type": "ShareholderRelation"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Update a shareholder relation
Updates manually editable details for a shareholder relation, such as the number of shares.
curl --request PATCH \
--url https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"shares": 1500.5
}
'import requests
url = "https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}"
payload = { "shares": 1500.5 }
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({shares: 1500.5})
};
fetch('https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}', 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.syntage.com/shareholders/{shareholderId}/relations/{relationId}",
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([
'shares' => 1500.5
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$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.syntage.com/shareholders/{shareholderId}/relations/{relationId}"
payload := strings.NewReader("{\n \"shares\": 1500.5\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
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.syntage.com/shareholders/{shareholderId}/relations/{relationId}")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"shares\": 1500.5\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.syntage.com/shareholders/{shareholderId}/relations/{relationId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"shares\": 1500.5\n}"
response = http.request(request)
puts response.read_body{
"id": "82cd9012-3456-7890-abcd-ef1234567890",
"link": "/entities/91ab5678-1234-5678-9abc-def012345678",
"shareholder": {
"id": "91ab5678-1234-5678-9abc-def012345678",
"name": "JUAN MANUEL PEREZ GONZALEZ",
"type": "physical",
"rfc": "PEIC211118IS0",
"relations": "<array>",
"entity": "/entities/91ab5678-1234-5678-9abc-def012345678",
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678",
"@type": "Shareholder"
},
"relationType": "shareholders",
"sources": [
{
"id": "73de0123-4567-8901-bcde-f23456789012",
"relation": "<unknown>",
"shareholder": {
"id": "91ab5678-1234-5678-9abc-def012345678",
"name": "JUAN MANUEL PEREZ GONZALEZ",
"type": "physical",
"rfc": "PEIC211118IS0",
"relations": "<array>",
"entity": "/entities/91ab5678-1234-5678-9abc-def012345678",
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678",
"@type": "Shareholder"
},
"sourceName": "manual",
"sourceId": "64ef1234-5678-9012-cdef-345678901234",
"shares": 1500.5,
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678/relations/82cd9012-3456-7890-abcd-ef1234567890/sources/73de0123-4567-8901-bcde-f23456789012",
"@type": "ShareholderRelationsSource"
}
],
"shares": 1500.5,
"totalShares": 10000,
"ownership": 0.15,
"createdAt": "2020-01-01T12:15:00.000Z",
"updatedAt": "2020-01-01T12:15:00.000Z",
"@id": "/shareholders/91ab5678-1234-5678-9abc-def012345678/relations/82cd9012-3456-7890-abcd-ef1234567890",
"@type": "ShareholderRelation"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}Authorizations
Your API key is available in the Production and Sandbox dashboards.
Path Parameters
The shareholder ID
The relation ID
Body
Updated number of shares represented by the relation
x >= 0.011500.5
Response
Shareholder Relation updated successfully
Unique shareholder relation ID
"82cd9012-3456-7890-abcd-ef1234567890"
Entity connected to this shareholder relation
"/entities/91ab5678-1234-5678-9abc-def012345678"
Shareholder connected by this relation
Show child attributes
Show child attributes
Direction of the ownership relation between the shareholder and entity
shareholders, shareholder_of "shareholders"
Sources that support this shareholder relation
Show child attributes
Show child attributes
Number of shares represented by this relation
1500.5
Total number of shares in the company, when known
10000
Ownership ratio as a decimal value, for example 0.15 means 15%
0.15
Date and time the resource was created
"2020-01-01T12:15:00.000Z"
Date and time the resource was last updated
"2020-01-01T12:15:00.000Z"
ShareholderRelation IRI reference
"/shareholders/91ab5678-1234-5678-9abc-def012345678/relations/82cd9012-3456-7890-abcd-ef1234567890"
Was this page helpful?