---
sourceDocument: Referência de API do Brasil
sourceDocumentLink: https://servicenow-prod.fluidtopics.net/r/pt-BR/api-reference

 Release :

    - brazil

ft:locale :

    - pt-BR

ft:publication_title :

    - Referência de API do Brasil

ft:clusterId :

    - crapiref

bundleId :

    - crapiref

workflow :

    - Creator


---

# NowDataSDK classe - Android

# NowDataSDK classe - Android {#ariaid-title1}

Versão de lançamento: Brazil  
Atualizado 10 de set. de 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 3 min. de leitura  
A classe NowDataSDK fornece funções que permitem a criação e inicialização de vários serviços de recursos, como NowGraphQLService, NowAttachmentService, NowTableService e NowAPIService.

## NowDataSDK - makeGraphQLService(instanceURL: URL) {#ariaid-title2}

Cria e inicializa uma instância do recurso NowGraphQLService. Este serviço habilita o acesso à API GraphQL na sua ServiceNow instância.
Para obter mais informações sobre a ServiceNow API GraphQL, consulte [Dados de registro de consulta usando a estrutura da API GraphQL](https://servicenow-prod.fluidtopics.net/7rlhyP00XK7nksXGXjBC7g "Crie uma API GraphQL personalizada para consultar dados de registro de um componente ou um sistema de terceiros.").
{#NDataSDK-makeGraphQLService_S_O_O__table_nvx_zbt_4pb__entry__3}

| Nome | Tipo | Descrição |
|-|-|-|
| InstanceURL | [URL](https://developer.android.com/reference/kotlin/java/net/URL.html) | URL da ServiceNow instância a ser acessada. Por exemplo, `"https://instance.servicenow.com"` |
[Tabela 1. Parâmetros]

{#NDataSDK-makeGraphQLService_S_O_O__table_nvx_zbt_4pb} {#NDataSDK-makeGraphQLService_S_O_O__table_ovx_zbt_4pb__entry__2}

| Tipo | Descrição |
|-|-|
| \<NowGraphQLService\> | Objeto NowGraphQLService encapsulado em um [objeto de resultado de kotlin](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-result/). |
[Tabela 2. Retorna]

{#NDataSDK-makeGraphQLService_S_O_O__table_ovx_zbt_4pb}  
O exemplo de código a seguir mostra como chamar esta função.

    private var nowGraphQLService: NowGraphQLService? = null

    /**
      * Create the NowGraphQLService once in the lifetime of the application, inside the Application class
      * or another manager class that will be injected into other classes via dagger/hilt.
      * NowGraphQLService should be created after initializing the NowSDK.
      */
    suspend fun getNowGraphQLService(): NowGraphQLService? {
      if (nowGraphQLService != null) return nowGraphQLService

      return NowDataSDK.makeGraphQLService(URL("https://instance-name.service-now.com")).getOrThrow()
        .also { this.nowGraphQLService = it }
    }

## NowDataSDK - makeNow APIService(instanceURL: URL) {#ariaid-title3}

Cria e inicializa uma instância do serviço NowAPIService. Este serviço permite que você acesse as REST APIs públicas expostas pela sua ServiceNow instância.
Além disso, você pode desenvolver REST APIs com script personalizadas em sua ServiceNow instância e acessá-las em sua Android aplicação usando a [NowAPIService interface - Android](https://servicenow-prod.fluidtopics.net/VO_~__esnUhjPnJEnr5i6g#NowAPIServiceAndroidInterface "A interface do NowAPIService fornece a capacidade de executar solicitações em uma ServiceNow REST API especificada.") API NowAPIService. Para obter informações adicionais sobre ServiceNow APIs REST, consulte [REST com script](https://servicenow-prod.fluidtopics.net/0f1~6iABhMZftaJuzkmalw "O recurso REST API com script permite que os desenvolvedores de aplicações criem APIs de serviço web personalizadas.").
{#NDataSDK-makeNowAPIService_S_O_O__table_rjf_lft_4pb__entry__3}

| Nome | Tipo | Descrição |
|-|-|-|
| InstanceURL | [URL](https://developer.android.com/reference/kotlin/java/net/URL.html) | URL da ServiceNow instância a ser acessada. Por exemplo, `"https://instance.servicenow.com"` |
[Tabela 3. Parâmetros]

{#NDataSDK-makeNowAPIService_S_O_O__table_rjf_lft_4pb} {#NDataSDK-makeNowAPIService_S_O_O__table_sjf_lft_4pb__entry__2}

| Tipo | Descrição |
|-|-|
| \<NowAPIService\> | NowAPIService encapsulado em um [objeto de resultado de kotlin](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-result/). |
[Tabela 4. Retorna]

{#NDataSDK-makeNowAPIService_S_O_O__table_sjf_lft_4pb}  
O exemplo de código a seguir mostra como chamar esta função.

    private var nowApiService: NowAPIService? = null

    /**
      * Create the NowAPIService once in the lifetime of the application inside the Application class
      * or another manager class that will be injected into other classes via dagger/hilt.
      * NowAPIService should be created after initializing the NowSDK
      */
    suspend fun getNowApiService(): NowAPIService? {
      if (nowApiService != null) return nowApiService

      return NowDataSDK.makeAPIService(URL("https://instance-name.service-now.com")).getOrThrow()
        .also { this.nowApiService = it }
    }

## NowDataSDK - makeNow AttachmentService(instanceURL: URL) {#ariaid-title4}

Cria e inicializa uma instância do recurso Now AttachmentService.
Este serviço permite carregar, baixar e excluir arquivos de anexo da sua ServiceNow instância. Depois que você carrega um anexo para sua instância, ele gera metadados para o anexo que você pode baixar para sua Android aplicação.

Para obter informações adicionais sobre ServiceNow anexos, consulte [API de anexo](https://servicenow-prod.fluidtopics.net/DeDKnZV_eBdwiripfTEVPA#c_AttachmentAPI "A API de anexos fornece endpoints que permitem carregar e consultar anexos de arquivo.").
{#NDataSDK-makeNowAttachService_S_O_O__table_bnd_qgt_4pb__entry__3}

| Nome | Tipo | Descrição |
|-|-|-|
| InstanceURL | [URL](https://developer.android.com/reference/kotlin/java/net/URL.html) | URL da ServiceNow instância a ser acessada. Por exemplo, `"https://instance.servicenow.com"` |
[Tabela 5. Parâmetros]

{#NDataSDK-makeNowAttachService_S_O_O__table_bnd_qgt_4pb} {#NDataSDK-makeNowAttachService_S_O_O__table_cnd_qgt_4pb__entry__2}

| Tipo | Descrição |
|-|-|
| \<NowAttachmentService\> | Objeto NowAttachmentService encapsulado em um [objeto de resultado de kotlin](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-result/). |
[Tabela 6. Retorna]

{#NDataSDK-makeNowAttachService_S_O_O__table_cnd_qgt_4pb}  
O exemplo de código a seguir mostra como chamar este método.

    private var nowAttachmentService: NowAttachmentService? = null

    /**
      * Create the NowAttachmentService once in the lifetime of the application inside the Application
      * class or another manager class that will be injected into other classes via dagger/hilt.
      * NowAttachmentService should be created after initializing the NowSDK.
      */
    suspend fun getNowAttachmentService(): NowAttachmentService? {
      if (nowAttachmentService != null) return nowAttachmentService

      return NowDataSDK.makeAttachmentService(URL("https://instance-name.service-now.com"))
        .getOrThrow()
        .also { this.nowAttachmentService = it }
    }

## NowDataSDK - makeTableService(instanceURL: URL) {#ariaid-title5}

Cria e inicializa uma instância do recurso NowTableService.
Este serviço permite que você acesse a API da tabela REST em uma ServiceNow instância. Para obter informações adicionais sobre a API da tabela REST, consulte [API da tabela](https://servicenow-prod.fluidtopics.net/olM43ayVpe9s6o5IiuYwNQ#c_TableAPI "A API Tabela fornece endpoints que permitem executar operações de criação, leitura, atualização e exclusão (CRUD) em tabelas existentes.").
{#NDataSDK-makeTableService_S_O_O__table_jxh_vht_4pb__entry__3}

| Nome | Tipo | Descrição |
|-|-|-|
| InstanceURL | [URL](https://developer.android.com/reference/kotlin/java/net/URL.html) | URL da ServiceNow instância a ser acessada. Por exemplo, `"https://instance.servicenow.com"` |
[Tabela 7. Parâmetros]

{#NDataSDK-makeTableService_S_O_O__table_jxh_vht_4pb} {#NDataSDK-makeTableService_S_O_O__table_kxh_vht_4pb__entry__2}

| Tipo | Descrição |
|-|-|
| \<NowTableService\> | Objeto NowTableService encapsulado em um [objeto de resultado de kotlin](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-result/). |
[Tabela 8. Retorna]

{#NDataSDK-makeTableService_S_O_O__table_kxh_vht_4pb}  
O exemplo de código a seguir mostra como chamar esta função.

    private var nowTableService: NowTableService? = null

    /**
      * Create the NowTableService once in the lifetime of the application inside the Application
      * class or another manager class that will be injected into other classes via dagger/hilt.
      * NowTableService should be created after initializing the NowSDK.
      */
    suspend fun getNowTableService(): NowTableService? {
      if (nowTableService != null) return nowTableService

      return NowDataSDK.makeTableService(URL("https://instance-name.service-now.com")).getOrThrow()
        .also { this.nowTableService = it }
    }


