apidocs
ApiDocs API wrapper.
Attributes
APIDOCS_INDEX = 'https://static.apidocs.co/apidocs_index.json'
module-attribute
APIDOCS_LOOKUP_TEMPLATE = 'https://api.apidocs.co/resolve/{app_name}/{app_version}/?asset_id={asset_type}:{asset_id}'
module-attribute
APIDocsApp = namedtuple('APIDocsApp', ['apptitle', 'appslug', 'versionslug'])
module-attribute
Functions
get_apps()
Returns a list of application available on apidocs.
Returns:
Type | Description |
---|---|
list[APIDocsApp]
|
applictations documented on apidocs |
Source code in pyrevitlib/pyrevit/coreutils/apidocs.py
make_namespace_uri(namespace, app_name='revit', app_version=str(HOST_APP.version))
Returns the URI of a namespace.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
namespace |
str
|
name of the namespace |
required |
app_name |
str
|
name of the application. Defaults to "revit". |
'revit'
|
app_version |
str
|
version of the application. Defaults to str(HOST_APP.version). |
str(version)
|
Returns:
Type | Description |
---|---|
str
|
URI of the namespace |
Source code in pyrevitlib/pyrevit/coreutils/apidocs.py
make_type_uri(type_name, app_name='revit', app_version=str(HOST_APP.version))
Returns the URI of a type.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
type_name |
str
|
name of the type |
required |
app_name |
str
|
name of the application. Defaults to "revit". |
'revit'
|
app_version |
str
|
version of the application. Defaults to str(HOST_APP.version). |
str(version)
|
Returns:
Type | Description |
---|---|
str
|
URI of the type |
Source code in pyrevitlib/pyrevit/coreutils/apidocs.py
make_event_uri(event_name, app_name='revit', app_version=str(HOST_APP.version))
Returns the URI of an event.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
event_name |
str
|
name of the event. |
required |
app_name |
str
|
name of the application. Defaults to "revit". |
'revit'
|
app_version |
str
|
version of the application. |
str(version)
|
Returns:
Type | Description |
---|---|
str
|
URI of the event |