# API - Obtendo Objetos Customizados do Lead

### Rota

<mark style="color:green;">`GET`</mark> `/lead/customobjects/id-do-lead?apitoken=seu-token&i=sua-instancia`

Endpoint completo: <mark style="color:green;"><https://sprinthub-api-master.sprinthub.app/lead/customobjects/id-do-lead?apitoken=seu-token\\&i=sua-instancia></mark>

### Query Params

<table><thead><tr><th width="291">Key/Chave</th><th width="450">Descrição</th></tr></thead><tbody><tr><td>i</td><td>Identificador da sua instância, subdomínio.</td></tr><tr><td>apitoken</td><td>Token da API.</td></tr></tbody></table>

## Obtendo Objetos Customizados do Lead

O envio da requisição foi feito utilizando o software *Postman*. A resposta esperada é uma lista de objetos com todos os Objetos Customizados.

<figure><img src="/files/vKp3LLBCX8PMXJMpa1BG" alt=""><figcaption><p><em>Objeto "Pedidos de Suporte".</em></p></figcaption></figure>

<figure><img src="/files/WS2RfoJeUpGTh6H1F2rP" alt=""><figcaption><p><em>Resposta da requisição.</em></p></figcaption></figure>

### Obtendo a definição dos Objetos Customizados

A resposta da chamada anterior retorna o "*definitionId*", que é o identificador do Objeto Customizado da instância, para obter uma lista das definições, pode ser utilizada a seguinte chamada:

<mark style="color:green;">`GET`</mark> `/customobjects/def?query={definitions{id,name,pluralName,relationship{id},isPublished,allowDynamicInsert,fields{label,alias,defaultValue,type,required,uniqueIdentifier,properties}}}&apitoken=seu-token&i=sua-instancia`

Endpoint completo: <mark style="color:green;"><https://sprinthub-api-master.sprinthub.app/customobjects/def?query={definitions{id,name,pluralName,relationship{id},isPublished,allowDynamicInsert,fields{label,alias,defaultValue,type,required,uniqueIdentifier,properties\\}}}\\&apitoken=seu-token\\&i=sua-instancia></mark>

<figure><img src="/files/6Eb2Ck5CgQkgaojVUn48" alt=""><figcaption><p><em>Obtendo definições dos Objetos.</em></p></figcaption></figure>


---

# 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.sprinthub.com/topicos/api/api-obtendo-objetos-customizados-do-lead.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.
