Replace the tiles on a canvas
curl --request PUT \
--url https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items \
--header 'Content-Type: application/json' \
--header 'authorization: <api-key>' \
--data '
{
"items": [
{
"id": "<string>",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
],
"apiKey": "<string>",
"organizationId": "<string>",
"connectionId": "<string>"
}
'import requests
url = "https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items"
payload = {
"items": [
{
"id": "<string>",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
],
"apiKey": "<string>",
"organizationId": "<string>",
"connectionId": "<string>"
}
headers = {
"authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
items: [
{
id: '<string>',
favorite_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
x: 0,
y: 0,
w: 0,
h: 0
}
],
apiKey: '<string>',
organizationId: '<string>',
connectionId: '<string>'
})
};
fetch('https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items', 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.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'items' => [
[
'id' => '<string>',
'favorite_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'x' => 0,
'y' => 0,
'w' => 0,
'h' => 0
]
],
'apiKey' => '<string>',
'organizationId' => '<string>',
'connectionId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"authorization: <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.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items"
payload := strings.NewReader("{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("authorization", "<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.put("https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items")
.header("authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"data": {
"items": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"canvas_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0,
"created_at": "<unknown>",
"favorite": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_by_project_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "sql",
"name": "<string>",
"thread_id": "<string>",
"chart_config": {},
"chart": {
"v": 3
},
"connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"thumbnail_url": "<string>",
"sql": "<string>",
"snapshot_data": [
{}
],
"is_archived": true,
"created_at": "<unknown>",
"updated_at": "<unknown>",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"copied_from_favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tool_call": {
"connectorKind": "mcp",
"toolName": "<string>"
},
"row_transform": "<string>",
"row_columns": [
{
"name": "<string>",
"type": "<string>"
}
]
}
}
]
}
}{
"status": "error",
"error": {
"message": "<string>",
"code": "<string>",
"details": {}
}
}Canvases
Replace Canvas Items
Replace the tiles on a canvas
PUT
/
v2
/
api
/
projects
/
{projectId}
/
workspaces
/
{workspaceId}
/
canvases
/
{canvasId}
/
items
Replace the tiles on a canvas
curl --request PUT \
--url https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items \
--header 'Content-Type: application/json' \
--header 'authorization: <api-key>' \
--data '
{
"items": [
{
"id": "<string>",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
],
"apiKey": "<string>",
"organizationId": "<string>",
"connectionId": "<string>"
}
'import requests
url = "https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items"
payload = {
"items": [
{
"id": "<string>",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0
}
],
"apiKey": "<string>",
"organizationId": "<string>",
"connectionId": "<string>"
}
headers = {
"authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
items: [
{
id: '<string>',
favorite_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
x: 0,
y: 0,
w: 0,
h: 0
}
],
apiKey: '<string>',
organizationId: '<string>',
connectionId: '<string>'
})
};
fetch('https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items', 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.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'items' => [
[
'id' => '<string>',
'favorite_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'x' => 0,
'y' => 0,
'w' => 0,
'h' => 0
]
],
'apiKey' => '<string>',
'organizationId' => '<string>',
'connectionId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"authorization: <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.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items"
payload := strings.NewReader("{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("authorization", "<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.put("https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items")
.header("authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.upsolve.ai/v2/api/projects/{projectId}/workspaces/{workspaceId}/canvases/{canvasId}/items")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"items\": [\n {\n \"id\": \"<string>\",\n \"favorite_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"x\": 0,\n \"y\": 0,\n \"w\": 0,\n \"h\": 0\n }\n ],\n \"apiKey\": \"<string>\",\n \"organizationId\": \"<string>\",\n \"connectionId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"data": {
"items": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"canvas_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"x": 0,
"y": 0,
"w": 0,
"h": 0,
"created_at": "<unknown>",
"favorite": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organization_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_by_project_user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"type": "sql",
"name": "<string>",
"thread_id": "<string>",
"chart_config": {},
"chart": {
"v": 3
},
"connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"thumbnail_url": "<string>",
"sql": "<string>",
"snapshot_data": [
{}
],
"is_archived": true,
"created_at": "<unknown>",
"updated_at": "<unknown>",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"copied_from_favorite_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"tool_call": {
"connectorKind": "mcp",
"toolName": "<string>"
},
"row_transform": "<string>",
"row_columns": [
{
"name": "<string>",
"type": "<string>"
}
]
}
}
]
}
}{
"status": "error",
"error": {
"message": "<string>",
"code": "<string>",
"details": {}
}
}Authorizations
Path Parameters
The project in the URL. The caller's project user is read from it.
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$PUT /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/items Parameter
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$PUT /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/items Parameter
Pattern:
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$Body
application/json
PUT /v2/api/projects/:projectId/workspaces/:workspaceId/canvases/:canvasId/items Request body
Show child attributes
Show child attributes
Upsolve API key, generated under Account → Developer settings in the Upsolve Hub. Keys are user-scoped: pass organizationId alongside the key to select which org to act on.
Minimum string length:
1The ID of the organization. Required when using Supabase JWT authentication.
The ID of the connection a guest has access to
Was this page helpful?