Semarchy xDM v5.x includes a generator to create a language-specific API client library (generate an SDK) to simplify integration work. This API client library makes it easy to use xDM's REST API.
This client library generation is based on the OpenAPI Generator.
Available API Client Library Domains
xDM allows to generate API clients for the following domains:
- data: Consume data from a Semarchy xDM data hub, or publish data into a hub.
- admin: Administer a Semarchy xDM instance.
- app_builder: Manage models including export, import, and deployment to data locations.
- dashboard_builder: Manage dashboards including export and import.
Available Languages
- bash
- CSharp
- java
- PowerShell
- python
- many more: complete list of client library generators
URL Format
REST API client generator is executed by calling a REST service:
<code>http://<strong>[host]</strong>/semarchy/api/rest/api-docs/codegen/<strong>[language]</strong>?domain=<strong>[client-library-domain]</strong></code>
URL Samples
http://localhost:8088/semarchy/api/rest/api-docs/codegen/csharp?domain=data
http://localhost:8088/semarchy/api/rest/api-docs/codegen/python?domain=admin
http://localhost:8088/semarchy/api/rest/api-docs/codegen/bash?domain=app_builder
Replace localhost:8088 with the correct host and port for your environment
Step-by-step example
- Access your REST API documentation main page:
- Choose the domain for which you want to generate the code sample
- Copy the URL from your browser's address bar, and edit it.
- Replace in the URL "
api-ui/index.html
" by "api-docs/codegen/[language]
". - This downloads a zip containing the SDK (code and documentation) in the specified language.
For example: on a typical local development instance, the initial URL for the REST API will look like this:
<code>http://localhost:8088/semarchy/api/rest/api-ui/index.html?domain=admin</code>
Edit this URL to transform it this way:
<code>http://localhost:8088/semarchy/api/rest/api-docs/codegen/python?domain=admin</code>