Run one command of the catalog on a document or a project's head (BC3/BC4)
curl --request POST \
--url https://api.eddy.engineer/v1/bim.run \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"command": "<string>",
"key": "<string>",
"params": {},
"project": "<string>",
"variant": "<string>"
}
'import requests
url = "https://api.eddy.engineer/v1/bim.run"
payload = {
"command": "<string>",
"key": "<string>",
"params": {},
"project": "<string>",
"variant": "<string>"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
command: '<string>',
key: '<string>',
params: {},
project: '<string>',
variant: '<string>'
})
};
fetch('https://api.eddy.engineer/v1/bim.run', 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.eddy.engineer/v1/bim.run",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'command' => '<string>',
'key' => '<string>',
'params' => [
],
'project' => '<string>',
'variant' => '<string>'
]),
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.eddy.engineer/v1/bim.run"
payload := strings.NewReader("{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.eddy.engineer/v1/bim.run")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eddy.engineer/v1/bim.run")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"after": "<string>",
"before": "<string>",
"changed": true,
"document": {
"bytes": 123,
"elements": 123,
"format": 123,
"key": "<string>",
"levels": 123,
"name": "<string>"
},
"epoch": 123,
"history": 123,
"project": "<string>",
"reply": {},
"step": {
"label": "<string>",
"made": [
[
"<unknown>"
]
],
"removed": [
[
"<unknown>"
]
]
},
"variant": "<string>"
}Bim
Run one command of the catalog on a document or a project's head (BC3/BC4)
An edit is a command plus parameters, run server-side as a pure function of (document, command, params): the document after is stored under its own key and, with project, the project’s head moves — through its live chain when a store is mounted (the CAS on the epoch the head was read at; a lost CAS or a stale key is PROJECT_HEAD_MOVED), through the record otherwise. A refusal changes nothing and is typed, naming the command and the element the engine named: UNKNOWN_COMMAND, COMMAND_USES_FILESYSTEM (the nine file commands and any path parameter), COMMAND_IS_HISTORY (undo/redo: use bim.undo / bim.redo), COMMAND_REPLACES_PROJECT (new/highrise/tower: use bim.project.create), FONT_NOT_BUNDLED, COMMAND_FAILED, LIVE_READ_ONLY.
POST
/
v1
/
bim.run
Run one command of the catalog on a document or a project's head (BC3/BC4)
curl --request POST \
--url https://api.eddy.engineer/v1/bim.run \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"command": "<string>",
"key": "<string>",
"params": {},
"project": "<string>",
"variant": "<string>"
}
'import requests
url = "https://api.eddy.engineer/v1/bim.run"
payload = {
"command": "<string>",
"key": "<string>",
"params": {},
"project": "<string>",
"variant": "<string>"
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
command: '<string>',
key: '<string>',
params: {},
project: '<string>',
variant: '<string>'
})
};
fetch('https://api.eddy.engineer/v1/bim.run', 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.eddy.engineer/v1/bim.run",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'command' => '<string>',
'key' => '<string>',
'params' => [
],
'project' => '<string>',
'variant' => '<string>'
]),
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.eddy.engineer/v1/bim.run"
payload := strings.NewReader("{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://api.eddy.engineer/v1/bim.run")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eddy.engineer/v1/bim.run")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"command\": \"<string>\",\n \"key\": \"<string>\",\n \"params\": {},\n \"project\": \"<string>\",\n \"variant\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"after": "<string>",
"before": "<string>",
"changed": true,
"document": {
"bytes": 123,
"elements": 123,
"format": 123,
"key": "<string>",
"levels": 123,
"name": "<string>"
},
"epoch": 123,
"history": 123,
"project": "<string>",
"reply": {},
"step": {
"label": "<string>",
"made": [
[
"<unknown>"
]
],
"removed": [
[
"<unknown>"
]
]
},
"variant": "<string>"
}Body
application/json
Response
OK