API Reference
Topic Viewpoint
Create viewpoint
code examples curl location globoff 'https //api catenda com/opencde/bcf/3 0/projects/{topic board id}/topics/{topic id}/viewpoints' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data '{ "orthogonal camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "view to world scale" "", "aspect ratio" "" }, "perspective camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "field of view" "", "aspect ratio" "" }, "lines" \[ { "start point" {}, "end point" {} } ], "clipping planes" \[ { "location" {}, "direction" {} } ], "bitmaps" \[ { "bitmap type" "", "bitmap data" "", "location" {}, "normal" {}, "up" {}, "height" "" } ], "snapshot" { "snapshot type" "", "snapshot data" "" }, "components" { "coloring" \[ { "color" "", "components" \[ {} ] } ], "visibility" {} } }'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var raw = json stringify({ "orthogonal camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "view to world scale" "", "aspect ratio" "" }, "perspective camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "field of view" "", "aspect ratio" "" }, "lines" \[ { "start point" {}, "end point" {} } ], "clipping planes" \[ { "location" {}, "direction" {} } ], "bitmaps" \[ { "bitmap type" "", "bitmap data" "", "location" {}, "normal" {}, "up" {}, "height" "" } ], "snapshot" { "snapshot type" "", "snapshot data" "" }, "components" { "coloring" \[ { "color" "", "components" \[ {} ] } ], "visibility" {} } }); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //api catenda com/opencde/bcf/3 0/projects/{topic board id}/topics/{topic id}/viewpoints", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));require "uri" require "json" require "net/http" url = uri("https //api catenda com/opencde/bcf/3 0/projects/{topic board id}/topics/{topic id}/viewpoints") https = net http new(url host, url port) https use ssl = true request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request body = json dump({ "orthogonal camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "view to world scale" "", "aspect ratio" "" }, "perspective camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "field of view" "", "aspect ratio" "" }, "lines" \[ { "start point" {}, "end point" {} } ], "clipping planes" \[ { "location" {}, "direction" {} } ], "bitmaps" \[ { "bitmap type" "", "bitmap data" "", "location" {}, "normal" {}, "up" {}, "height" "" } ], "snapshot" { "snapshot type" "", "snapshot data" "" }, "components" { "coloring" \[ { "color" "", "components" \[ {} ] } ], "visibility" {} } }) response = https request(request) puts response read body import requests import json url = "https //api catenda com/opencde/bcf/3 0/projects/{topic board id}/topics/{topic id}/viewpoints" payload = json dumps({ "orthogonal camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "view to world scale" "", "aspect ratio" "" }, "perspective camera" { "camera view point" {}, "camera direction" {}, "camera up vector" {}, "field of view" "", "aspect ratio" "" }, "lines" \[ { "start point" {}, "end point" {} } ], "clipping planes" \[ { "location" {}, "direction" {} } ], "bitmaps" \[ { "bitmap type" "", "bitmap data" "", "location" {}, "normal" {}, "up" {}, "height" "" } ], "snapshot" { "snapshot type" "", "snapshot data" "" }, "components" { "coloring" \[ { "color" "", "components" \[ {} ] } ], "visibility" {} } }) headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // ok { "guid" "52959166 dbd2 44eb 81bb 74f955f30e0f", "orthogonal camera" { "camera view point" { "x" 100, "y" 100, "z" 100 }, "camera direction" { "x" 100, "y" 100, "z" 100 }, "camera up vector" { "x" 0, "y" 0, "z" 1 }, "view to world scale" 14, "aspect ratio" 1 }, "perspective camera" { "camera view point" { "x" 100, "y" 100, "z" 100 }, "camera direction" { "x" 100, "y" 100, "z" 100 }, "camera up vector" { "x" 0, "y" 0, "z" 1 }, "field of view" 60, "aspect ratio" 1 }, "lines" \[ { "start point" { "x" 100, "y" 100, "z" 100 }, "end point" { "x" 200, "y" 200, "z" 200 } } ], "clipping planes" \[ { "location" { "x" 100, "y" 100, "z" 100 }, "direction" { "x" 0, "y" 0, "z" 1 } } ], "bitmaps" \[ { "guid" "8c2f8818 e413 49d4 8978 7f7d95d2b27e", "bitmap type" "png", "location" { "x" 100, "y" 100, "z" 100 }, "normal" { "x" 0, "y" 1, "z" 0 }, "up" { "x" 0, "y" 0, "z" 1 }, "height" 20 } ], "snapshot" { "snapshot type" "png" }, "authorization" { "viewpoint actions" \[ "" ] } }