> ## Documentation Index
> Fetch the complete documentation index at: https://help.teable.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Post adminannouncementtranslate

> Translate announcement content into other supported languages

Required token scopes: `instance|update`



## OpenAPI

````yaml /swagger.json post /admin/announcement/translate
openapi: 3.0.0
info:
  version: 1.0.0
  title: Teable App
  description: Manage Data as easy as drink a cup of tea
  x-logo:
    backgroundColor: '#F0F0F0'
    altText: Teable logo
servers:
  - url: https://app.teable.ai/api
security: []
tags:
  - name: base
    x-group: project
  - name: base node
    x-group: project node
  - name: base-share
    x-group: project-share
paths:
  /admin/announcement/translate:
    post:
      tags:
        - admin
      description: |-
        Translate announcement content into other supported languages

        Required token scopes: `instance|update`
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                sourceLanguage:
                  type: string
                  enum:
                    - en
                    - zh
                    - it
                    - fr
                    - de
                    - ja
                    - ru
                    - uk
                    - tr
                    - es
                    - ar
                    - he
                title:
                  type: object
                  properties:
                    text:
                      type: string
                      minLength: 1
                      maxLength: 5000
                    targets:
                      type: array
                      items:
                        type: string
                        enum:
                          - en
                          - zh
                          - it
                          - fr
                          - de
                          - ja
                          - ru
                          - uk
                          - tr
                          - es
                          - ar
                          - he
                      minItems: 1
                      maxItems: 12
                  required:
                    - text
                    - targets
                message:
                  type: object
                  properties:
                    text:
                      type: string
                      minLength: 1
                      maxLength: 5000
                    targets:
                      type: array
                      items:
                        type: string
                        enum:
                          - en
                          - zh
                          - it
                          - fr
                          - de
                          - ja
                          - ru
                          - uk
                          - tr
                          - es
                          - ar
                          - he
                      minItems: 1
                      maxItems: 12
                  required:
                    - text
                    - targets
                actionLabel:
                  type: object
                  properties:
                    text:
                      type: string
                      minLength: 1
                      maxLength: 5000
                    targets:
                      type: array
                      items:
                        type: string
                        enum:
                          - en
                          - zh
                          - it
                          - fr
                          - de
                          - ja
                          - ru
                          - uk
                          - tr
                          - es
                          - ar
                          - he
                      minItems: 1
                      maxItems: 12
                  required:
                    - text
                    - targets
              required:
                - sourceLanguage
      responses:
        '201':
          description: Translations keyed by target language
          content:
            application/json:
              schema:
                type: object
                properties:
                  title:
                    type: object
                    properties:
                      en:
                        type: string
                      zh:
                        type: string
                      it:
                        type: string
                      fr:
                        type: string
                      de:
                        type: string
                      ja:
                        type: string
                      ru:
                        type: string
                      uk:
                        type: string
                      tr:
                        type: string
                      es:
                        type: string
                      ar:
                        type: string
                      he:
                        type: string
                  message:
                    type: object
                    properties:
                      en:
                        type: string
                      zh:
                        type: string
                      it:
                        type: string
                      fr:
                        type: string
                      de:
                        type: string
                      ja:
                        type: string
                      ru:
                        type: string
                      uk:
                        type: string
                      tr:
                        type: string
                      es:
                        type: string
                      ar:
                        type: string
                      he:
                        type: string
                  actionLabel:
                    type: object
                    properties:
                      en:
                        type: string
                      zh:
                        type: string
                      it:
                        type: string
                      fr:
                        type: string
                      de:
                        type: string
                      ja:
                        type: string
                      ru:
                        type: string
                      uk:
                        type: string
                      tr:
                        type: string
                      es:
                        type: string
                      ar:
                        type: string
                      he:
                        type: string
      security:
        - bearerAuth: []
      x-codeSamples:
        - lang: Shell
          source: |-
            curl --request POST \
              --url https://app.teable.ai/api/admin/announcement/translate \
              --header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
              --header 'content-type: application/json' \
              --data '{"sourceLanguage":"en","title":{"text":"string","targets":["en"]},"message":{"text":"string","targets":["en"]},"actionLabel":{"text":"string","targets":["en"]}}'
        - lang: JavaScript
          source: >-
            const url =
            'https://app.teable.ai/api/admin/announcement/translate';

            const options = {
              method: 'POST',
              headers: {
                Authorization: 'Bearer REPLACE_BEARER_TOKEN',
                'content-type': 'application/json'
              },
              body: '{"sourceLanguage":"en","title":{"text":"string","targets":["en"]},"message":{"text":"string","targets":["en"]},"actionLabel":{"text":"string","targets":["en"]}}'
            };


            try {
              const response = await fetch(url, options);
              const data = await response.json();
              console.log(data);
            } catch (error) {
              console.error(error);
            }
        - lang: Node.js
          source: |-
            const http = require('https');

            const options = {
              method: 'POST',
              hostname: 'app.teable.ai',
              port: null,
              path: '/api/admin/announcement/translate',
              headers: {
                Authorization: 'Bearer REPLACE_BEARER_TOKEN',
                'content-type': 'application/json'
              }
            };

            const req = http.request(options, function (res) {
              const chunks = [];

              res.on('data', function (chunk) {
                chunks.push(chunk);
              });

              res.on('end', function () {
                const body = Buffer.concat(chunks);
                console.log(body.toString());
              });
            });

            req.write(JSON.stringify({
              sourceLanguage: 'en',
              title: {text: 'string', targets: ['en']},
              message: {text: 'string', targets: ['en']},
              actionLabel: {text: 'string', targets: ['en']}
            }));
            req.end();
        - lang: Python
          source: >-
            import http.client


            conn = http.client.HTTPSConnection("app.teable.ai")


            payload =
            "{\"sourceLanguage\":\"en\",\"title\":{\"text\":\"string\",\"targets\":[\"en\"]},\"message\":{\"text\":\"string\",\"targets\":[\"en\"]},\"actionLabel\":{\"text\":\"string\",\"targets\":[\"en\"]}}"


            headers = {
                'Authorization': "Bearer REPLACE_BEARER_TOKEN",
                'content-type': "application/json"
            }


            conn.request("POST", "/api/admin/announcement/translate", payload,
            headers)


            res = conn.getresponse()

            data = res.read()


            print(data.decode("utf-8"))
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````