Content API
Health
Section titled “Health”GET /content/health (health)
response:
{ "healthy": true, "dependencies": {}, "memstats": { "Alloc": 9, "HeapAlloc": 9, "HeapSys": 14, "HeapIdle": 2, "HeapInUse": 12, "TotalAlloc": 453, "Sys": 23, "NumGC": 95 }, "version": ""}GET /content/ready (ready)
response:
ready:trueSync diffed queries
Section titled “Sync diffed queries”POST /content/entities/diff/sync ( sync diffed queries )
response:
{ "message": "queries ran successfully", "queries": ""}Sync diffed entity
Section titled “Sync diffed entity”POST /content/entities/diff/sync/:entity ( sync diffed entity )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| entity | tag | string | entity name |
response:
{ "message": "queries ran successfully", "queries": ""}Get different queries
Section titled “Get different queries”GET /content/entities/diff ( get different queries )
response:
{ "queries": ""}List entities
Section titled “List entities”GET /content/entities/list ( list entities )
| key | value | data type | description |
|---|---|---|---|
| store | photos | string | list the entities based on store name |
| tag | foo | string | list the entities based on tag name |
response:
{ "datastore": "hotei", "entities": [ { "name": "asset", "source": "content", "store": "customer" }, { "name": "assetwithsimplestateflow", "source": "content", "store": "customer" }, { "name": "tag", "source": "content", "store": "customer" }, { "name": "photos_asset", "source": "content", "store": "customer" }, { "name": "assetwithcomplexstateflow", "source": "content", "store": "customer" }, { "name": "category", "source": "content", "store": "customer" }, { "name": "photos_folder", "source": "content", "store": "customer" }, { "name": "contentapptemplate", "source": "content", "store": "customer" }, { "name": "folder", "source": "content", "store": "customer" } ]}Get entity details
Section titled “Get entity details”GET /content/entities/list/:entity ( get entity details )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| entity | assest | string | entity name |
response:
{ "entity": { "description": "", "fields": [ { "name": "id", "description": "", "type": "ULID", "arraytype": "None", "enum": "", "embeddables": null, "computed": true, "serial": false, "inherited": false, "subfields": null, "annotations": [] } ], "name": "asset", "service": "content" }}List content stores
Section titled “List content stores”GET /content/contentstore/list ( get list content stores )
| key | value | data type | description |
|---|---|---|---|
| name | photos | string | name of the content store |
response:
{ "contentstore": { "photos": { "name": "photos", "assetentityname": "photos_asset", "folderentityname": "photos_folder", "active": true, "version": { "enabled": true }, "locale": true, "cacheexpiry": 86400000000000, "parent": "01HCYX1Z5CV3DZ17N26BBVZ28P" } }}List content apps
Section titled “List content apps”GET /content/contentapp/list ( get list content apps )
| key | value | data type | description |
|---|---|---|---|
| name | caretaker | string | name of the content app |
response:
{ "contentapp": { "caretakerapp": { "name": "caretakerapp", "contenttypes": [ "photos" ], "contentstores": { "photos": { "name": "photos", "assetentityname": "photos_asset", "folderentityname": "photos_folder", "active": true, "version": { "enabled": true }, "locale": true, "cacheexpiry": 86400000000000, "parent": "01HCYX1Z5CV3DZ17N26BBVZ28P" } }, "active": true, "version": { "enabled": true }, "locale": { "defaultlocale": "en-US", "supportedlocales": [ "en-US", "in-HI" ] }, "entities": "contenttypedefinition" } }}Content store create asset
Section titled “Content store create asset”POST /content/store/:contentstore/asset?filename=wallpaper.jpg ( content store create asset )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| filename | wallpaper.jpg | image | name of file |
| locale | en_US | string | files in specified region |
| path | abc/ | string | path of the file |
| overwrite | true | boolean | It just overwrite the existing file |
| createfolders | true | boolean | It just create folders in content store |
| contentstore | photos | string | name of contentstore |
| description | a beautiful wallpaper | string | sets the description field in uploaded asset and will be returned on X-Description header while fetching the asset |
request:
| key | value |
|---|---|
| file | wallpaper.jpg |
response:
{ "content-type": "image/jpeg", "en_US:1": { "meta": { "access": [], "bytes": 39290, "createdon": "2023-10-18T11:21:15+05:30", "deletedby": null, "deletedon": null, "sha": "6e384c248a1840b7e1e3563c7a531528231173a0", "updatedon": "2023-10-18T11:21:15+05:30", "version": 1 } }, "id": "01HD0ND5ARFBPJTTH6K0YPNEM6", "meta": {}, "name": "wallpaper.jpg", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD0ND5ARFBPJTTH6K0YPNEM6&locale=en_US"}Content store update asset
Section titled “Content store update asset”PUT /content/store/:contentstore/asset?id=01HD0ND5ARFBPJTTH6K0YPNEM6 ( content store update asset )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| id | 01HD0ND5ARFBPJTTH6K0YPNEM6 | ulid | id of file |
| locale | en_US | string | files in specified region |
| path | abc/ | string | path of the file |
| overwrite | true | boolean | It just overwrite the existing file |
| createfolders | true | boolean | It just create folders in content store |
| transforms | resize,w_100,h_100 | string | It able to resize the given file based on given width and height |
| contentstore | photos | string | name of contentstore |
request:
| key | value |
|---|---|
| file | spider.png |
response:
{ "content-type": "image/png", "en_US:2": { "meta": { "access": [], "bytes": 48983, "createdon": "2023-10-18T11:21:15+05:30", "deletedby": null, "deletedon": null, "sha": "684dbfa513d78c28219133f31064379252492717", "updatedon": "2023-10-18T12:00:51+05:30", "version": 2 } }, "id": "01HD0ND5ARFBPJTTH6K0YPNEM6", "meta": {}, "name": "wallpaper.jpg", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD0ND5ARFBPJTTH6K0YPNEM6&locale=en_US"}Content store download asset by id
Section titled “Content store download asset by id”GET /content/store/:contentstore/asset/id/:id ( content store download asset by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| id | 01HD0R90TDNWG51FH7D57E2BPP | ulid | id of file |
| locale | en_US | string | files in specified region |
| metadata | true | boolean | It gives details of file |
| version | 2 | int | It gives file based on version |
| transforms | resize,w_100,h_100 | string | It able to resize the given file based on given width and height |
| contentstore | photos | string | name of contentstore |
response:
imageContent store download asset by path
Section titled “Content store download asset by path”GET /content/store/:contentstore/asset/path/:path ( content store download asset by path )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| path | mylogo.jpg | jpg | path of file |
| locale | en_US | string | files in specified region |
| metadata | true | boolean | It gives details of file |
| version | 2 | int | It gives file based on version |
| transforms | resize,w_100,h_100 | string | It able to resize the given file based on given width and height |
| contentstore | photos | string | name of contentstore |
response:
imageContent store download asset
Section titled “Content store download asset”GET /content/store/:contentstore/asset?path=mylogo.jpg ( content store download asset )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| path | mylogo.jpg | jpg | path of file |
| locale | en_US | string | files in specified region |
| metadata | true | boolean | It gives details of file |
| version | 2 | int | It gives file based on version |
| transforms | resize,w_100,h_100 | string | It able to resize the given file based on given width and height |
| contentstore | photos | string | name of contentstore |
response:
imageContent store delete asset
Section titled “Content store delete asset”DELETE /content/store/:contentstore/asset?path=images/car.jpg ( content store delete asset )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| path | images/car.jpg | string | path of the file |
| contentstore | photos | string | name of contentstore |
response:
asset deleted successfullyContent store add folder
Section titled “Content store add folder”POST /content/store/:contentstore/folder?name=abc1&path=/kreshnaa&createfolders=true ( content store add folder )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| path | /kreshnaa | string | path of folder |
| name | /abc1 | string | name of folder |
| createfolders | true | boolean | access to create folder |
| contentstore | photos | string | name of contentstore |
response:
{ "data": { "photos_folder": { "contentstore": "photos", "createdon": "2023-10-18T13:49:27+05:30", "deletedby": null, "deletedon": null, "description": null, "id": "01HD0XWH3Z4C09B9BGGD0M68E1", "meta": {}, "name": "abc1", "parentid": "01HD0XWH3N8C8RSKYF4ZH80ZRC", "updatedon": "2023-10-18T13:49:27+05:30", "version": 1 } }}Content store get folder list
Section titled “Content store get folder list”GET /content/store/:contentstore/list?path=/&depth=10 ( content store get folder list )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentstore | photos | string | name of contentstore |
response:
{ "assets": [ "bg.png", "wallpaper.jpg", "logo.jpg", "first.jpg", "second.jpg", "mylogo.jpg", "myspider.png" ], "folders": [ { "kreshnaa": { "assets": [], "folders": [ { "abc1": { "assets": [], "folders": [] } } ] } } ]}Content store update folder
Section titled “Content store update folder”PUT /content/store/:contentstore/folder?currentpath=/kreshnaa&newpath=/maddi ( content store update folder )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| currentpath | /kreshnaa | string | path of folder |
| newpath | /maddi | string | path of new folder |
| contentstore | photos | string | name of contentstore |
request:
{ "parentid": "01HD0XWH3Z4C09B9BGGD0M68E1"}response:
{ "data": { "photos_folder": { "contentstore": "photos", "createdon": "2023-10-18T13:49:27+05:30", "deletedby": null, "deletedon": null, "description": null, "id": "01HD0XWH3N8C8RSKYF4ZH80ZRC", "meta": {}, "name": "maddi", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "updatedon": "2023-10-18T13:51:06+05:30", "version": 2 } }}Content store delete folder
Section titled “Content store delete folder”DELETE /content/store/:contentstore/folder?path=/maddi&forcedelete=true ( content store delete folder )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| path | /maddi | string | path of folder |
| contentstore | photos | string | name of contentstore |
response:
{ "success": true, "message": "folder deleted successfully"}Create content app type
Section titled “Create content app type”POST /content/app/:contentapp/contenttype ( create content app type )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
request:
{ "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n - name: images\n type: array(string)\n ", "name": "photos"}response:
{ "data": { "contenttypedefinition": { "contentapp": "caretakerapp", "createdon": "2023-10-18T14:03:20+05:30", "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n - name: images\n type: array(string)\n ", "deletedby": null, "deletedon": null, "id": "01HD0YNYVPB9HR9WM8X30F0PC6", "name": "photos", "properties": {}, "updatedon": "2023-10-18T14:03:20+05:30", "version": 1 } }}Get content app type
Section titled “Get content app type”GET /content/app/:contentapp/contenttype ( get content app type )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
response:
{ "data": { "contenttypedefinition": { "contentapp": "caretakerapp", "createdon": "2023-10-18T14:03:20+05:30", "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n - name: images\n type: array(string)\n ", "deletedby": null, "deletedon": null, "id": "01HD0YNYVPB9HR9WM8X30F0PC6", "name": "photos", "properties": {}, "updatedon": "2023-10-18T14:03:20+05:30", "version": 1 } }}Get content app type by id
Section titled “Get content app type by id”GET /content/app/:contentapp/contenttype/:id ( get content app type by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| id | 01HD0YNYVPB9HR9WM8X30F0PC6 | ulid | id of contentapp |
response:
{ "data": { "contenttypedefinition": { "contentapp": "caretakerapp", "createdon": "2023-10-18T14:03:20+05:30", "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n - name: images\n type: array(string)\n ", "deletedby": null, "deletedon": null, "id": "01HD0YNYVPB9HR9WM8X30F0PC6", "name": "photos", "properties": {}, "updatedon": "2023-10-18T14:03:20+05:30", "version": 1 } }}Update content app type
Section titled “Update content app type”PUT /content/app/:contentapp/contenttype ( update content app type )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
request:
{ "id": "01HD0YNYVPB9HR9WM8X30F0PC6", "contentapp": "carecaretakerapp", "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n "}response:
{ "data": { "contenttypedefinition": { "contentapp": "caretakerapp", "createdon": "2023-10-18T14:03:20+05:30", "definition": "---\nentities:\n- name: photos\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: patientname\n type: string\n validations:\n - type: required\n - name: carername\n type: string\n validations:\n - type: required\n ", "deletedby": null, "deletedon": null, "id": "01HD0YNYVPB9HR9WM8X30F0PC6", "name": "photos", "properties": {}, "updatedon": "2023-10-18T14:12:42+05:30", "version": 2 } }}Delete content app type by id
Section titled “Delete content app type by id”DELETE /content/app/:contentapp/contenttype/:id ( delete content app type by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| id | 01HE239S5XTAZYNKJV9SRNPYY6 | ulid | id of contentapp |
response:
{ "data": { "contenttypedefinition": { "contentapp": "caretakerapp", "contenttypedefinition_history": null, "createdon": "2023-10-31T10:59:00+05:30", "definition": "---\nentities:\n- name: blog10\n inherits: kisai.common\n fields:\n - name: id\n type: ulid\n defaultvalue: ulid()\n validations:\n - type: required\n - type: unique\n message: id field needs to be unique\n - type: final\n message: id field cannot be updated\n - name: name\n type: string\n validations:\n - type: required\n - name: assets\n type: array(string)\n validations:\n - type: required\n - name: file\n type: string\n validations:\n - type: required", "deletedon": "2023-10-31T10:59:12+05:30", "id": "01HE239S5XTAZYNKJV9SRNPYY6", "name": "blog10", "properties": {}, "updatedon": "2023-10-31T10:59:00+05:30", "version": 1 } }}Content type create entry
Section titled “Content type create entry”POST /content/app/:contentapp/type/:contenttype ( content type create entry )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
request:
formdata
Section titled “formdata”| key | value |
|---|---|
| data | {"patientname": "jorge","carername": "ramu"} |
| images | files |
response:
{ "assets": { "images": { "assets": [ { "content-type": "image/jpeg", "en-US:1": { "meta": { "access": [], "bytes": 8699, "createdon": "2023-10-18T14:26:19+05:30", "deletedby": null, "deletedon": null, "sha": "f19a88ad812968296db7cb9d91d25a3f7e8239c4", "updatedon": "2023-10-18T14:26:19+05:30", "version": 1 } }, "id": "01HD1000YAN48D6H1XFEEJJSY2", "meta": {}, "name": "anyalsis1.jpg", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD1000YAN48D6H1XFEEJJSY2&locale=en-US" } ] } }, "data": { "photos": { "carername": "ramu", "createdon": "2023-10-18T14:26:19+05:30", "deletedby": null, "deletedon": null, "id": "01HD1000YJV0BQDEYT0TKAMQ9V", "images": [ "01HD1000YAN48D6H1XFEEJJSY2" ], "patientname": "jorge", "updatedon": "2023-10-18T14:26:19+05:30" } }}Content type create entry json
Section titled “Content type create entry json”POST /content/app/:contentapp/type/:contenttype (content type create entry json )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
request:
{ "patientname": "Michkel", "carername": "ravi"}response:
{ "assets": {}, "data": { "photos": { "carername": "ravi", "createdon": "2023-10-18T14:43:09+05:30", "deletedby": null, "deletedon": null, "id": "01HD10YVFZMY2AXXBWGSZQZV17", "images": null, "patientname": "Michkel", "updatedon": "2023-10-18T14:43:09+05:30" } }}Content type update entry with json body
Section titled “Content type update entry with json body”PUT /content/app/:contentapp/type/:contenttype (content type update entry with json body )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
request:
{ "id": "01HD10YVFZMY2AXXBWGSZQZV17", "carername": "Abhi"}response:
{ "assets": {}, "data": { "photos": { "carername": "Abhi", "createdon": "2023-10-18T14:43:09+05:30", "deletedby": null, "deletedon": null, "id": "01HD10YVFZMY2AXXBWGSZQZV17", "images": null, "patientname": "Michkel", "updatedon": "2023-10-18T14:51:33+05:30" } }}Content type update entry
Section titled “Content type update entry”PUT /content/app/:contentapp/type/:contenttype (content type update entry )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
request:
| key | value |
|---|---|
| data | {"id": "01HD1000YJV0BQDEYT0TKAMQ9V", "carername": "Rathol"} |
| images | file |
response:
{ "assets": { "images": { "assets": [ { "content-type": "image/png", "en-US:1": { "meta": { "access": [], "bytes": 52909, "createdon": "2023-10-18T16:35:44+05:30", "deletedby": null, "deletedon": null, "sha": "10bee6c29c865f8c56e22875542c1c93f677720b", "updatedon": "2023-10-18T16:35:44+05:30", "version": 1 } }, "id": "01HD17D0BR6DARFEK6Z5S5HB6Y", "meta": {}, "name": "encryption-algorithms-what-is-cryptography-edurek.png", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD17D0BR6DARFEK6Z5S5HB6Y&locale=en-US" } ] } }, "data": { "photos": { "carername": "Rathol", "createdon": "2023-10-18T14:26:19+05:30", "deletedby": null, "deletedon": null, "id": "01HD1000YJV0BQDEYT0TKAMQ9V", "images": [ "01HD1000YAN48D6H1XFEEJJSY2", "01HD17D0BR6DARFEK6Z5S5HB6Y" ], "patientname": "jorge", "updatedon": "2023-10-18T16:35:44+05:30" } }}Content type update asset file
Section titled “Content type update asset file”PUT /content/app/:contentapp/type/:contenttype/:contenttypeid/asset/id/:id/upload ( content type download asset file by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| contenttypeid | 01HD1000YJV0BQDEYT0TKAMQ9V | ulid | id of contenttype row |
| id | 01HD1000YAN48D6H1XFEEJJSY2 | ulid | defining id |
request:
| key | value |
|---|---|
| images | file |
response:
{ "content-type": "image/png", "en_US:2": { "meta": { "access": [], "bytes": 48983, "createdon": "2023-10-18T11:21:15+05:30", "deletedby": null, "deletedon": null, "sha": "684dbfa513d78c28219133f31064379252492717", "updatedon": "2023-10-18T12:00:51+05:30", "version": 2 } }, "id": "01HD0ND5ARFBPJTTH6K0YPNEM6", "meta": {}, "name": "wallpaper.jpg", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD0ND5ARFBPJTTH6K0YPNEM6&locale=en_US"}Content type update by id
Section titled “Content type update by id”PUT /content/app/:contentapp/type/:contenttype/:contenttypeid/asset/field/:field/id/:id ( Content type update by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| contenttypeid | 01HD1000YJV0BQDEYT0TKAMQ9V | ulid | id of contenttype row |
| id | 01HD1000YAN48D6H1XFEEJJSY2 | ulid | defining id |
| field | images | string | defining field |
request:
| key | value |
|---|---|
| images | file |
response:
{ "content-type": "image/png", "en_US:2": { "meta": { "access": [], "bytes": 48983, "createdon": "2023-10-18T11:21:15+05:30", "deletedby": null, "deletedon": null, "sha": "684dbfa513d78c28219133f31064379252492717", "updatedon": "2023-10-18T12:00:51+05:30", "version": 2 } }, "id": "01HD1000YJV0BQDEYT0TKAMQ9V", "meta": {}, "name": "wallpaper.jpg", "parentid": "01HCYX1Z5CV3DZ17N26BBVZ28P", "state": null, "store": "photos", "tags": null, "url": "/store/photos/asset?id=01HD0ND5ARFBPJTTH6K0YPNEM6&locale=en_US"}Content type download asset file by id
Section titled “Content type download asset file by id”GET /content/app/:contentapp/type/:contenttype/:contenttypeid/asset/:field/download/id/:id ( content type download asset file by id )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| contenttypeid | 01HD1000YJV0BQDEYT0TKAMQ9V | ulid | id of contenttype row |
| field | images | string | defining field name |
| id | 01HD1000YAN48D6H1XFEEJJSY2 | ulid | defining id of folder |
response: image
Content type get entry
Section titled “Content type get entry”GET /content/app/:contentapp/type/:contenttype?limit=1&offset=1 ( content type get entry )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| limit | 1 | int | how many to get |
| offset | 1 | int | where to start |
response:
{ "data": { "photos": { "carername": "Rathol", "createdon": "2023-10-18T14:26:19+05:30", "deletedby": null, "deletedon": null, "id": "01HD1000YJV0BQDEYT0TKAMQ9V", "images": [ "01HD1000YAN48D6H1XFEEJJSY2", "01HD17D0BR6DARFEK6Z5S5HB6Y" ], "patientname": "jorge", "updatedon": "2023-10-18T16:35:44+05:30" } }}Content type get entry with body
Section titled “Content type get entry with body”PATCH /content/app/:contentapp/type/:contenttype?limit=1&offset=1 ( content type get entry with body )
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| limit | 1 | int | how many to get |
| offset | 1 | int | where to start |
request:
{ "filter": "id = '01HD1000YJV0BQDEYT0TKAMQ9V'"}response:
{ "data": { "photos": { "carername": "Rathol", "createdon": "2023-10-18T14:26:19+05:30", "deletedby": null, "deletedon": null, "id": "01HD1000YJV0BQDEYT0TKAMQ9V", "images": [ "01HD1000YAN48D6H1XFEEJJSY2", "01HD17D0BR6DARFEK6Z5S5HB6Y" ], "patientname": "jorge", "updatedon": "2023-10-18T16:35:44+05:30" } }}Content type get entry by id
Section titled “Content type get entry by id”GET /content/app/:contentapp/type/:contenttype?limit=1&offset=1&filter=id='01HD1C7XRSN7KE743R0A1GMC4R' ( content type get entry by id)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of contenttype |
| limit | 1 | int | how many to get |
| offset | 1 | int | where to start |
| id | 01HD1C7XRSN7KE743R0A1GMC4R | ulid | id of contenttype |
response:
{ "data": { "photos": { "carername": "ramu", "createdon": "2023-10-18T18:00:20+05:30", "deletedby": null, "deletedon": null, "id": "01HD1C7XRSN7KE743R0A1GMC4R", "images": [ "01HD1C7XR7B7JRET0N5172G36D" ], "patientname": "jorge", "updatedon": "2023-10-18T18:00:20+05:30" } }}Content type delete entry by id
Section titled “Content type delete entry by id”DELETE /content/app/:contentapp/type/:contenttype/:id (content type delete entry by id)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| contenttype | photos | string | name of type |
| id | 01HE27G5H3YAW1M1BDYRF3A6MT | ulid | id of type |
response:
{ "data": { "photos": { "carername": "c1", "createdon": "2023-10-31T12:12:24+05:30", "deletedon": "2023-10-31T12:23:24+05:30", "id": "01HE27G5H3YAW1M1BDYRF3A6MT", "images": null, "patientname": "p1", "updatedon": "2023-10-31T12:12:24+05:30" } }}Create content app template
Section titled “Create content app template”POST /content/app/:contentapp/template (create content app template)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
request:
{ "name": "template1", "content": "carer {{id}}"}response:
{ "data": { "contentapptemplate": { "content": "carer {{id}}", "contentapp": "caretakerapp", "createdon": "2023-10-19T10:05:43+05:30", "deletedby": null, "deletedon": null, "id": "01HD33FJJ7MFTWFJ5X0RSDVEYZ", "name": "template1", "path": "/", "updatedon": "2023-10-19T10:05:43+05:30", "version": 1 } }}Read content app template by path
Section titled “Read content app template by path”GET /content/app/:contentapp/template/:path (read content app template by path)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| path | template1 | string | path of contenttype |
response:
carer {{id}}Update content app template by path
Section titled “Update content app template by path”PUT /content/app/:contentapp/template/path/:path (update content app template by path)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| path | template1 | string | path of contenttype |
request:
{ "content": "carer updated {{id}}"}response:
{ "data": { "contentapptemplate": { "content": "carer updated {{id}}", "contentapp": "caretakerapp", "createdon": "2023-10-19T10:05:43+05:30", "deletedby": null, "deletedon": null, "id": "01HD33FJJ7MFTWFJ5X0RSDVEYZ", "name": "template1", "path": "/", "updatedon": "2023-10-19T10:36:37+05:30", "version": 2 } }}Update content app template by id
Section titled “Update content app template by id”PUT /content/app/:contentapp/template/id/:id (update content app template by id)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| id | 01HD33FJJ7MFTWFJ5X0RSDVEYZ | ulid | path of contenttype |
request:
{ "content": "carer updated ver 2 {{id}}"}response:
{ "data": { "contentapptemplate": { "content": "carer updated ver 2 {{id}}", "contentapp": "caretakerapp", "createdon": "2023-10-19T10:05:43+05:30", "deletedby": null, "deletedon": null, "id": "01HD33FJJ7MFTWFJ5X0RSDVEYZ", "name": "template1", "path": "/", "updatedon": "2023-10-19T10:46:46+05:30", "version": 3 } }}Content app graphql get content type entries
Section titled “Content app graphql get content type entries”POST /content/app/:contentapp/graphql (update content app template by id)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
request:
Query{ photos_folder { id }}response:
{ "data": { "photos_folder": { "id": "01HCYX1Z5CV3DZ17N26BBVZ28P" } }}Content app bulk content entry query
Section titled “Content app bulk content entry query”PATCH /content/app/:contentapp (content app bulk content entry query)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
request:
{ "queries":[ { "query": "photos(id:\"01HD1000YAN48D6H1XFEEJJSY2\"){}" } ]}response:
{ "data": { "photos": null }}Delete content app template by path
Section titled “Delete content app template by path”DELETE /content/app/:contentapp/template/path/:path (delete content app template by path)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| path | template1 | string | path of template |
response:
{ "data": { "contentapptemplate": { "content": "carer updated ver 2 {{id}}", "contentapp": "caretakerapp", "contentapptemplate_history": null, "createdon": "2023-10-19T10:05:43+05:30", "deletedon": "2023-10-19T10:56:06+05:30", "id": "01HD33FJJ7MFTWFJ5X0RSDVEYZ", "name": "template1", "path": "/", "updatedon": "2023-10-19T10:46:46+05:30", "version": 3 } }}Delete content app template by id
Section titled “Delete content app template by id”DELETE /content/app/:contentapp/template/id/:id (delete content app template by id)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| id | 01HD33FJJ7MFTWFJ5X0RSDVEYZ | ulid | id of template |
response:
{ "data": { "contentapptemplate": { "content": "carer updated ver 2 {{id}}", "contentapp": "caretakerapp", "contentapptemplate_history": null, "createdon": "2023-10-19T10:05:43+05:30", "deletedon": "2023-10-19T10:56:06+05:30", "id": "01HD33FJJ7MFTWFJ5X0RSDVEYZ", "name": "template1", "path": "/", "updatedon": "2023-10-19T10:46:46+05:30", "version": 3 } }}Render template by path with graphql
Section titled “Render template by path with graphql”POST /content/app/:contentapp/template/:template (render template by path with graphql)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| template | template1 | string | name of template |
request:
{ photos{ id }}response:
carerRender content app template by path with data
Section titled “Render content app template by path with data”PATCH /content/app/:contentapp/template/:template (render content app template by path with data)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| template | template1 | string | name of template |
request:
{ "queries":[ { "query": "photos(id:\"01HD1000YAN48D6H1XFEEJJSY2\"){}" } ]}response:
carerRender content app template by path with custom data
Section titled “Render content app template by path with custom data”PATCH /content/app/:contentapp/template/:template (render content app template by path with custom data)
Parameters
Section titled “Parameters”| key | value | data type | description |
|---|---|---|---|
| contentapp | caretakerapp | string | name of contentapp |
| template | template1 | string | name of template |
request:
{ "data":{ "photos.id": "Custom example" }}response:
carer Custom example