TagoIO Dictionary API

Manage Dictionary Slugs and Keys for TagoRUN (Profile Token).

OpenAPI Specification

tago-io-dictionary-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: TagoIO Access Management Dictionary API
  description: "#### **How to use this documentation**\nThe documentation is split by which token you're required to use in the request.  \nTagoIO provides 4 different tokens:\n- **Device-Token**: The token from your device, which you can get from the device's page.\n    \n- **Profile-Token**: Also know as Account-Token. You get from your profile settings page.\n    \n- **Network-Token**: Is the token from your Network. Only available if you're owner of the network in your integrations page.\n    \n- **Analysis-Token:** The token from your analysis, available in the analysis page.\n---\n#### Setting the API Endpoint Region\nWhen making a request to the TagoIO API, you must also specify the appropriate regional endpoint. Choose one of the following endpoints based on your geographical region:\n\n- **United States East 1:**  \n    Use this endpoint when your application is based in the eastern United States.  \n    **URL:** `https://api.us-e1.tago.io/`\n    \n- **Europe West 1:**  \n    Use this endpoint when your application is based in Western Europe.  \n    **URL:** `https://api.eu-w1.tago.io/`\n\n- **Tago Deploy:**  \n  You should use your own API URL that is available in your Domains section of the TagoDeploy."
  version: 1.0.0
  contact: {}
servers:
- url: https://api.us-e1.tago.io
- url: https://api.eu-w1.tago.io
security:
- ProfileToken: []
tags:
- name: Dictionary
  description: Manage Dictionary Slugs and Keys for TagoRUN (Profile Token).
paths:
  /dictionary:
    get:
      tags:
      - Dictionary
      summary: List Dictionaries
      description: List of Dictionaries
      operationId: getDictionaryList
      responses:
        '200':
          description: Getting the dictionary list
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: array
                    items:
                      type: object
                      properties:
                        created_at:
                          type: string
                          example: '2023-02-13T16:56:53.086Z'
                        fallback:
                          type: string
                          example: en-US
                        id:
                          type: string
                          example: 63ea6bd581db210009ff8f1d
                        languages:
                          type: array
                          items:
                            type: object
                            properties:
                              active:
                                type: boolean
                                example: true
                              code:
                                type: string
                                example: en-US
                          example:
                          - active: true
                            code: en-US
                          - active: true
                            code: es-ES
                          - active: true
                            code: pt-BR
                        name:
                          type: string
                          example: Admin Dashboard
                        slug:
                          type: string
                          example: ADM
                        updated_at:
                          type: string
                          example: '2023-02-13T16:56:53.086Z'
                    example:
                    - created_at: '2023-02-13T16:56:53.086Z'
                      fallback: en-US
                      id: 63ea6bd581db210009ff8f1d
                      languages:
                      - active: true
                        code: en-US
                      - active: true
                        code: es-ES
                      - active: true
                        code: pt-BR
                      name: Admin Dashboard
                      slug: ADM
                      updated_at: '2023-02-13T16:56:53.086Z'
                  status:
                    type: boolean
                    example: true
    post:
      tags:
      - Dictionary
      summary: Create Dictionary
      description: Create Dictionary
      operationId: createDictionary
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
              - name
              - slug
              properties:
                name:
                  type: string
                  example: dic.DICT
                slug:
                  type: string
                  example: DIC
                fallback:
                  type: string
                  example: fr-FR
                languages:
                  type: array
                  items:
                    type: object
                    properties:
                      code:
                        type: string
                        example: fr-FR
                      message:
                        type: string
                        example: 'true'
                  example:
                  - code: fr-FR
                    message: 'true'
            examples:
              Create Dictionary:
                value:
                  fallback: fr-FR
                  languages:
                  - code: fr-FR
                    message: 'true'
                  name: dic.DICT
                  slug: DIC
      responses:
        '201':
          description: Creating a dictionary
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: object
                    properties:
                      dictionary:
                        type: string
                        example: 654bdc4449769c00097fee32
                  status:
                    type: boolean
                    example: true
  /dictionary/{dictionary_id}:
    parameters:
    - name: dictionary_id
      in: path
      required: true
      schema:
        type: string
        example: (Type Dictionary ID)
      description: Can be obtained in the GET Dictionary response
    get:
      tags:
      - Dictionary
      summary: Dictionary Information
      description: Get Dictionary Details
      operationId: getDictionaryDetails
      responses:
        '200':
          description: Getting the Dictionary details
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: object
                    properties:
                      created_at:
                        type: string
                        example: '2023-02-13T16:56:53.086Z'
                      fallback:
                        type: string
                        example: en-US
                      languages:
                        type: array
                        items:
                          type: object
                          properties:
                            active:
                              type: boolean
                              example: true
                            code:
                              type: string
                              example: en-US
                        example:
                        - active: true
                          code: en-US
                        - active: true
                          code: es-ES
                        - active: true
                          code: pt-BR
                      name:
                        type: string
                        example: Admin Dashboard
                      slug:
                        type: string
                        example: ADM
                      updated_at:
                        type: string
                        example: '2023-02-13T16:56:53.086Z'
                  status:
                    type: boolean
                    example: true
    put:
      tags:
      - Dictionary
      summary: Update Dictionary
      description: Update Dictionary
      operationId: updateDictionary
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                fallback:
                  type: string
                  example: fr-FR
                languages:
                  type: array
                  items:
                    type: object
                    properties:
                      active:
                        type: boolean
                        example: true
                      code:
                        type: string
                        example: fr-FR
                  example:
                  - active: true
                    code: fr-FR
                  - active: true
                    code: pt-BR
                name:
                  type: string
                  example: updated.test
                slug:
                  type: string
                  example: TEEEE
            examples:
              Update Dictionary:
                value:
                  fallback: fr-FR
                  languages:
                  - active: true
                    code: fr-FR
                  - active: true
                    code: pt-BR
                  name: updated.test
                  slug: TEEEE
      responses:
        '200':
          description: Updating a Dictionary name
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: string
                    example: Successfully Updated
                  status:
                    type: boolean
                    example: true
    delete:
      tags:
      - Dictionary
      summary: Delete Dictionary
      description: Delete Dictionary
      operationId: deleteDictionary
      responses:
        '200':
          description: Delete Dictionary
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: string
                    example: Successfully Removed
                  status:
                    type: boolean
                    example: true
  /dictionary/{dictionary_id}/{language}:
    parameters:
    - name: dictionary_id
      in: path
      required: true
      schema:
        type: string
        example: (Type Dictionary ID)
      description: Can be obtained in the GET Dictionary response
    - name: language
      in: path
      required: true
      schema:
        type: string
        example: Language Code
      description: Language that will be updated
    put:
      tags:
      - Dictionary
      summary: Update Dictionary Language
      description: Update Dictionary Language
      operationId: updateDictionaryLanguage
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                dictionary:
                  type: object
                  properties:
                    test:
                      type: string
                      example: teste
            examples:
              Update Dictionary Language:
                value:
                  dictionary:
                    test: teste
      responses:
        '200':
          description: Put Dictionary Language
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: string
                    example: Dictionary language Successfully Updated
                  status:
                    type: boolean
                    example: true
  /dictionary/{slug_or_dictionary_id}/{language}:
    parameters:
    - name: slug_or_dictionary_id
      in: path
      required: true
      schema:
        type: string
        example: (Type Slug or Dictionary ID)
      description: Can be obtained in the GET Dictionary response
    - name: language
      in: path
      required: true
      schema:
        type: string
        example: Language Code
      description: Language that will be returned keys
    get:
      tags:
      - Dictionary
      summary: Get Dictionary Language Details
      description: Get Dictionary Language Details
      operationId: getDictionaryLanguageDetails
      responses:
        '200':
          description: Getting a dictionary language details
          content:
            application/json:
              schema:
                type: object
                properties:
                  result:
                    type: object
                    properties:
                      key:
                        type: string
                        example: value
                  status:
                    type: boolean
                    example: true
components:
  securitySchemes:
    Device-Token:
      type: apiKey
      description: A Device-Token that is unique to your device. Generate a token by accessing your Device's page.
      name: Device-Token
      in: header
      x-example: 5e12345a-d70a-4e2d-b83d-5c0123456789
    Network-Token:
      type: apiKey
      description: A Network Token that is unique to your Network. Access Integrations > Network > Tokens to generate a token for your Network.
      name: Token
      in: header
      x-DisplayName: Network-Token
      x-example: fd549ad2-813c-4d66-bf72-508e5b98afe3
    Profile-Token:
      type: apiKey
      description: A Profile token that is unique to your entire profile. Generate in your account settings.
      name: Profile-Token
      in: header
      x-example: a15ea5ea-dd2d-4c63-8945-92b54da4772a
x-tagGroups:
- name: Device Token (Device-level)
  tags:
  - Device Data
- name: Network Token (Network-level)
  tags:
  - Network Ingest
- name: Device Management
  tags:
  - Devices
  - Device Tokens
  - Configuration Param
  - Import/Export
  - Immutable Device
- name: Tago RUN
  tags:
  - Tago RUN
  - Users
  - Dictionary
  - Notifications
- name: Dashboards
  tags:
  - Dashboards
  - Widgets
- name: File(s) Management
  tags:
  - Files
  - Upload
- name: Profile
  tags:
  - Account
  - Profile
  - Statistics / Billing
- name: Entities
  tags:
  - Entity
  - Entity Data
- name: Resources
  tags:
  - Access Management