curl -X PATCH "https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/<webhookId>" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <token>" \
-d '{
"id": "00000000-0000-0000-0000-000000000000",
"external_id": "string",
"event_type": "document_update",
"notification_url": "string",
"public_key": "string",
"headers": {
"key": "content-type",
"value": "application/json"
}
}'
const response = await fetch(`https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/${webhookId}`, {
method: 'PATCH',
headers: { 'Content-Type': 'application/json', 'Authorization': 'Bearer <token>' },
body: JSON.stringify({
"id": "00000000-0000-0000-0000-000000000000",
"external_id": "string",
"event_type": "document_update",
"notification_url": "string",
"public_key": "string",
"headers": {
"key": "content-type",
"value": "application/json"
}
})
});
const data = await response.json();
import requests
response = requests.request(
"PATCH",
"https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/{webhookId}",
headers={ "Authorization": "Bearer <token>" },
json={
"id": "00000000-0000-0000-0000-000000000000",
"external_id": "string",
"event_type": "document_update",
"notification_url": "string",
"public_key": "string",
"headers": {
"key": "content-type",
"value": "application/json"
}
},
)
data = response.json()
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/<webhookId>");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "PATCH");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["Content-Type: application/json", "Authorization: Bearer <token>"]);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{
"id": "00000000-0000-0000-0000-000000000000",
"external_id": "string",
"event_type": "document_update",
"notification_url": "string",
"public_key": "string",
"headers": {
"key": "content-type",
"value": "application/json"
}
}');
$response = curl_exec($ch);
curl_close($ch);
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
req, _ := http.NewRequest("PATCH", "https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/<webhookId>", strings.NewReader(`{
"id": "00000000-0000-0000-0000-000000000000",
"external_id": "string",
"event_type": "document_update",
"notification_url": "string",
"public_key": "string",
"headers": {
"key": "content-type",
"value": "application/json"
}
}`))
req.Header.Set("Content-Type", "application/json")
req.Header.Set("Authorization", "Bearer <token>")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
data, _ := io.ReadAll(resp.Body)
fmt.Println(string(data))
}
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/<webhookId>"))
.header("Content-Type", "application/json")
.header("Authorization", "Bearer <token>")
.method("PATCH", HttpRequest.BodyPublishers.ofString("{\n \"id\": \"00000000-0000-0000-0000-000000000000\",\n \"external_id\": \"string\",\n \"event_type\": \"document_update\",\n \"notification_url\": \"string\",\n \"public_key\": \"string\",\n \"headers\": {\n \"key\": \"content-type\",\n \"value\": \"application/json\"\n }\n}"))
.build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.body());
require "net/http"
require "uri"
uri = URI("https://api.uat.triple-a.io/api/fiat-payout/v1/webhooks/<webhookId>")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
request = Net::HTTP::Patch.new(uri)
request["Content-Type"] = "application/json"
request["Authorization"] = "Bearer <token>"
request.body = "{\n \"id\": \"00000000-0000-0000-0000-000000000000\",\n \"external_id\": \"string\",\n \"event_type\": \"document_update\",\n \"notification_url\": \"string\",\n \"public_key\": \"string\",\n \"headers\": {\n \"key\": \"content-type\",\n \"value\": \"application/json\"\n }\n}"
response = http.request(request)
puts response.body