# Getting Started with Dynamic API

### Aurinko account setup

***

First, create your account in the [Aurinko portal](https://app.aurinko.io/), then follow the guide to [get your developer API keys](/getting-started/get-your-developer-api-keys.md).\
\
When presented with the **New Application** dialog choose the CRM feature.

<figure><img src="/files/qVDzMwl5gpzhitO2ORwy" alt="" width="563"><figcaption></figcaption></figure>

Next, navigate to **Settings** and specify your app's OAuth details (clientId+secret) for your Salesforce and Hubspot integrations.

<figure><img src="/files/5dkI3VipwMXfr39MXRjW" alt=""><figcaption></figcaption></figure>

\
Now, navigate to **Accounts** to test creating Salesforce and/or Hubspot accounts.&#x20;

<figure><img src="/files/1I1DKQ5nEc3Y8MuaBDua" alt=""><figcaption></figcaption></figure>

Once a new account is added you can find its Aurinko access token on the **Account** page. You will need this token to make API calls later.

<figure><img src="/files/5kcyNtFs8TnaEGVguhLG" alt=""><figcaption></figcaption></figure>

Upon adding a CRM account, its metadata is automatically loaded into the system. You will be able to examine the provider metadata when adding/ediging object and field mappings.

The **Virtual APIs** tab displays your virtual data models. If you have not created any models yet, start by clicking 'New virtual model'.

<figure><img src="/files/rdqQodfNUEyDGJffY5GV" alt=""><figcaption></figcaption></figure>

You can quickly create a new model from an existing template with a number of CRM provider mappings, i.e. Hubspot, Salesforce, MS Dynamics:\
\
![](/files/WU0Tj4DqR756eEIJHUC6)

Our AurinkoCRM template will clone a model with four objects: Company, Contact, Deal and User.

<figure><img src="/files/B3MFack6TJ8XcV39Ze2D" alt=""><figcaption></figcaption></figure>

and the following mappings/configurations will be pre-populated:\
\
![](/files/Lnxo98NKhqKcKBLvnNfZ)

Choose one of them to see how your virtual model is mapped to a provider model, like Hubspot:

<figure><img src="/files/0z7SpWRZ66Z9XqtD7XND" alt=""><figcaption></figcaption></figure>

Click any object to see its field mappings:

<figure><img src="/files/7whmurhqTyLUVUfgUwIM" alt=""><figcaption></figcaption></figure>

Note the 'Configuration Id', you need to reference this id when using the Dynamic API.

Here is the same Contact object mapped to the Salesforce Contact object (configuration id: 403):

<figure><img src="/files/eCODnCcusUuq8Cos4Iwc" alt=""><figcaption></figcaption></figure>

You can have as many mapping configurations as you need. Many Salesforce and Hubspot instances have their own customizations so you may need a CRM configuration per customer.\
Create them in Aurinko once needed and remember their ids. You will be able to reference a specific configuration when calling the /dynamic API.\
\
**Understanding Dynamic API Endpoints**

Aurinko Dynamic API offers a unified API experience, but with the key advantage of being virtualized. This means the API endpoints are dynamically generated based on your configuration. Here's an overview of the endpoint structure:

* **Metadata Endpoints:**
  * `/dynamic/{configId}/metadata/{objName}`: Retrieves metadata for a specific CRM object (e.g., contacts).
  * `/dynamic/{configId}/metadata/{objName}/{fieldName}`: Retrieves metadata for a particular field within a CRM object.
* **Object Endpoints:**
  * `/dynamic/{configId}/objects/{objName}`: Retrieves a list of objects of a specific type (e.g., all contacts).
  * `/dynamic/{configId}/objects/{objName}/{id}`: Retrieves a single CRM object by its ID.
  * `/dynamic/{configId}/objects/{objName}/{id}/{childRelationship}`: Retrieves data related to a child relationship of a specific CRM object.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.aurinko.io/dynamic-api/getting-started-with-dynamic-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
