đŸ› ī¸
Developer docs
Start BuildingGuides
  • ✨Getting Started
  • đŸŽ›ī¸Self Hosted Config
  • âœī¸SSO Login
    • Saml Identity Provider (Idp)
    • Oidc Identity Provider (Idp)
  • đŸŽžī¸Framework Specific Guide
    • âš›ī¸Reactjs
    • âš›ī¸Nextjs
    • âš›ī¸Vuejs
    • âš›ī¸Angular
    • âš›ī¸Svelte
    • âš›ī¸Solid
    • âš›ī¸Vanilla JS
  • â„šī¸Token
  • đŸ›ī¸Multi-Tenant Access Control
  • Embed using iFrame (Not Recommended approach)
  • 🔑License Key Validation for Self-Hosted App
  • Test
  • 👩‍đŸ’ģHelpers
    • âœŗī¸Token Body
    • ✅Options
      • Custom Fiscal Year filter setup in DataBrain
    • đŸˆ‚ī¸Server Event
    • Embed Functions
    • Override Language
    • âœˆī¸Embedding Architecture
    • âœˆī¸LLM Architecture
    • ✨LLM Connectors
      • Open AI
      • Claude AI
      • Azure Open AI
      • Llama
      • Mixtral
    • 🆔Dashboard ID
    • 🆔Metric ID
    • 🆔API Token
    • 🆔End User Metric Creation
    • Embedding APIs
      • Sync Datasource
  • Metric App Filter
  • Dashboard App Filter
  • Chat Mode
    • Step 1: Create Datamart and Workspace
    • Step 2: Create Data App and Embed ID
  • ✨Solutions Alchemy
    • Dashboards for Client Groups
    • Dashboard for Multiple Clients
    • Embedding: Role based Dashboard Filtering
    • Localized Currency Symbols
    • Manage Metrics
Powered by GitBook
On this page
  • Overview
  • API Endpoints
  • Cloud Databrain Endpoint
  • Self-hosted Databrain Endpoint
  • API Methods
  • Sync Datasource
  • Get AWSS3 sync Progress status
  1. Helpers
  2. Embedding APIs

Sync Datasource

Sync Datasource using the API

Overview

The Databrain APIs provides endpoints to sync you Datasource in both Cloud Databrain and Selfhosted Databrain environment. To use the API, you need to pass a parameter datasourceId.

API Endpoints

Cloud Databrain Endpoint

POST https://api.usedatabrain.com/api/v2/datasource/sync

Self-hosted Databrain Endpoint

POST <SELF_HOSTED_URL>/api/v2/datasource/sync

Headers

Name
Type
Description

Authorization*

String

API Methods

Sync Datasource

Endpoint:

POST /datasource/sync

Request Body:

{
    "input": {
        "datasourceId": "ba8e6e45-d864-4d00-a07a-008507828114" // ?id=
    }
}

Response Body:

{
    "data": {
        "message": "Sync completed"
    }
}

Get your datasourceId from the URL query params on the datasource page:

Get AWSS3 sync Progress status

Endpoint:

POST /datasource/getDatasourceProgress

Request Body:

{
    "input": {
        "datasourceId": "ba8e6e45-d864-4d00-a07a-008507828114" // ?id=
    }
}

Response Body:

{
    "status": {
        "progress": "16/16",
        "error": ""
    }
}

Response Body:

Below is a response when no sync is completed for AWSS3:

{
    "status": {
        "progress": "0/...",
        "error": ""
    }
}

Response Error:

Below is a response error when while syncing AWSS3 throws an error:

{
    "status": {
        "progress": "0/...",
        "error": "Error: Bind error data type"
    }
}
PreviousEmbedding APIsNextMetric App Filter

Last updated 2 months ago

Bearer

👩‍đŸ’ģ
API TOKEN