defs

defs lists definitions inside a library.

Description

Use the defs endpoint and a path name to return a list of definition types and names inside a library.

URL

https://[host]/[1010-version]/api/defs/[library_path]

Response

The list of types and names of definitions inside the given library.

User Interface Example

In https://[host]/[1010-version]/api/defs/[library_path], click the example api/defs/default.test.workbook. The following table appears:

default.test.workbook is a library that contains four blocks, named ws0, ws1, ws2, and ws3.

You can also display the definitions as JSON or plain text.

curl Example

The following example in curl returns the definitions inside the library default.test.workbook:
$ curl -s -b cookie.txt 
    'https://www2.1010data.com/beta-latest/api/defs/default.test.workbook':text

The response contains the blocks within the library:

kind   name 
 ------ -----
  block   ws0
  block   ws1
  block   ws2
  block   ws3