Accept an offer manually
curl --request POST \
--url https://coreapi.io/api/offers/{id}/accept \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form acceptedAt=2023-11-07T05:31:56Z \
--form file='@example-file'import requests
url = "https://coreapi.io/api/offers/{id}/accept"
files = { "file": ("example-file", open("example-file", "rb")) }
payload = { "acceptedAt": "2023-11-07T05:31:56Z" }
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('acceptedAt', '2023-11-07T05:31:56Z');
form.append('file', '<string>');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://coreapi.io/api/offers/{id}/accept', 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://coreapi.io/api/offers/{id}/accept",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"acceptedAt\"\r\n\r\n2023-11-07T05:31:56Z\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"status": "open",
"signedAt": "2023-11-07T05:31:56Z"
}Angebote
Accept an offer manually
Beta. This endpoint is unstable and may still change without notice. Pin against the dated version and watch the changelog.
Records a manual acceptance on behalf of the recipient, with an optional signed PDF upload. Use this for offers accepted outside the recipient view.
POST
/
api
/
offers
/
{id}
/
accept
Accept an offer manually
curl --request POST \
--url https://coreapi.io/api/offers/{id}/accept \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form acceptedAt=2023-11-07T05:31:56Z \
--form file='@example-file'import requests
url = "https://coreapi.io/api/offers/{id}/accept"
files = { "file": ("example-file", open("example-file", "rb")) }
payload = { "acceptedAt": "2023-11-07T05:31:56Z" }
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('acceptedAt', '2023-11-07T05:31:56Z');
form.append('file', '<string>');
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://coreapi.io/api/offers/{id}/accept', 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://coreapi.io/api/offers/{id}/accept",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"acceptedAt\"\r\n\r\n2023-11-07T05:31:56Z\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"file\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n<string>\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"status": "open",
"signedAt": "2023-11-07T05:31:56Z"
}Autorisierungen
API token of the organisation. Send it as Authorization: Bearer api_... The token is bound to exactly one organisation.
Pfadparameter
Offer ID (ULID).
Body
multipart/form-data
War diese Seite hilfreich?