Update task
curl --request PATCH \
--url https://shelfforce.ai/api/v1/tasks/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "in_progress",
"assignedTo": "usr_qrs789",
"notes": "Completed verification. Display looks correct.",
"dueDate": "2026-03-20"
}
'import requests
url = "https://shelfforce.ai/api/v1/tasks/{id}"
payload = {
"status": "in_progress",
"assignedTo": "usr_qrs789",
"notes": "Completed verification. Display looks correct.",
"dueDate": "2026-03-20"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
status: 'in_progress',
assignedTo: 'usr_qrs789',
notes: 'Completed verification. Display looks correct.',
dueDate: '2026-03-20'
})
};
fetch('https://shelfforce.ai/api/v1/tasks/{id}', 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://shelfforce.ai/api/v1/tasks/{id}",
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([
'status' => 'in_progress',
'assignedTo' => 'usr_qrs789',
'notes' => 'Completed verification. Display looks correct.',
'dueDate' => '2026-03-20'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://shelfforce.ai/api/v1/tasks/{id}"
payload := strings.NewReader("{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://shelfforce.ai/api/v1/tasks/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://shelfforce.ai/api/v1/tasks/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "tsk_xyz789",
"title": "Check Coca-Cola facing at Walmart #4523",
"status": "in_progress",
"updatedAt": "2026-02-23T11:00:00Z",
"placeId": "pl_abc123",
"assignedTo": "usr_qrs789",
"dueDate": "2026-03-20",
"notes": "Completed verification."
}
}{
"error": {
"code": "INVALID_API_KEY",
"message": "The provided API key is invalid or has been revoked."
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Analysis 'an_g7h8j9k0' not found."
}
}{
"error": {
"code": "VALIDATION_FAILED",
"message": "The 'imageUrl' field must be a valid URL."
}
}{
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 12 seconds."
}
}{
"error": {
"code": "INTERNAL_ERROR",
"message": "An unexpected error occurred. Please try again or contact support with request ID."
}
}Update task
Updates mutable fields on a task. Status transitions are validated: pending -> in_progress, pending -> cancelled, in_progress -> completed, in_progress -> cancelled.
PATCH
/
api
/
v1
/
tasks
/
{id}
Update task
curl --request PATCH \
--url https://shelfforce.ai/api/v1/tasks/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "in_progress",
"assignedTo": "usr_qrs789",
"notes": "Completed verification. Display looks correct.",
"dueDate": "2026-03-20"
}
'import requests
url = "https://shelfforce.ai/api/v1/tasks/{id}"
payload = {
"status": "in_progress",
"assignedTo": "usr_qrs789",
"notes": "Completed verification. Display looks correct.",
"dueDate": "2026-03-20"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
status: 'in_progress',
assignedTo: 'usr_qrs789',
notes: 'Completed verification. Display looks correct.',
dueDate: '2026-03-20'
})
};
fetch('https://shelfforce.ai/api/v1/tasks/{id}', 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://shelfforce.ai/api/v1/tasks/{id}",
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([
'status' => 'in_progress',
'assignedTo' => 'usr_qrs789',
'notes' => 'Completed verification. Display looks correct.',
'dueDate' => '2026-03-20'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://shelfforce.ai/api/v1/tasks/{id}"
payload := strings.NewReader("{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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://shelfforce.ai/api/v1/tasks/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://shelfforce.ai/api/v1/tasks/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"status\": \"in_progress\",\n \"assignedTo\": \"usr_qrs789\",\n \"notes\": \"Completed verification. Display looks correct.\",\n \"dueDate\": \"2026-03-20\"\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "tsk_xyz789",
"title": "Check Coca-Cola facing at Walmart #4523",
"status": "in_progress",
"updatedAt": "2026-02-23T11:00:00Z",
"placeId": "pl_abc123",
"assignedTo": "usr_qrs789",
"dueDate": "2026-03-20",
"notes": "Completed verification."
}
}{
"error": {
"code": "INVALID_API_KEY",
"message": "The provided API key is invalid or has been revoked."
}
}{
"error": {
"code": "NOT_FOUND",
"message": "Analysis 'an_g7h8j9k0' not found."
}
}{
"error": {
"code": "VALIDATION_FAILED",
"message": "The 'imageUrl' field must be a valid URL."
}
}{
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 12 seconds."
}
}{
"error": {
"code": "INTERNAL_ERROR",
"message": "An unexpected error occurred. Please try again or contact support with request ID."
}
}Authorizations
API key with sf_live_ prefix. Pass as Authorization: Bearer sf_live_...
Headers
Unique key for idempotent requests. If a request with the same key was already processed within the last 24 hours, the cached response is returned with X-Idempotent-Replayed: true.
Example:
"idk_550e8400-e29b-41d4-a716-446655440000"
Path Parameters
Task ID.
Example:
"tsk_xyz789"
Body
application/json
New status. Must follow valid transition rules.
Available options:
pending, in_progress, completed, cancelled Example:
"in_progress"
User ID to reassign the task to.
Example:
"usr_qrs789"
Updated notes.
Example:
"Completed verification. Display looks correct."
Updated due date.
Example:
"2026-03-20"
Response
Task updated.
Show child attributes
Show child attributes