# 添加

## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /shortLink/add:
    post:
      summary: 添加
      deprecated: false
      description: 添加短链接
      tags:
        - 短链接
      parameters:
        - name: Authorization
          in: header
          description: Bearer Token
          required: false
          example: Bearer 20K86nfDiOy0DVQ87bfuMnhpw7JBkMqKh
          schema:
            type: string
        - name: SecretID
          in: header
          description: ''
          required: false
          example: ''
          schema:
            type: string
        - name: SecretKey
          in: header
          description: ''
          required: false
          example: ''
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                link:
                  type: string
                  description: Link address
                validity:
                  type: integer
                  description: Timestamp
                  nullable: true
              required:
                - link
              x-apifox-orders:
                - link
                - validity
            example:
              link: https://vdse.bdstatic.com/192d9a98d782d9c74c96f09db9378d93.mp4
              validity: 1234567890
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                  data:
                    type: object
                    properties:
                      linkID:
                        type: string
                    required:
                      - linkID
                    x-apifox-orders:
                      - linkID
                  msg:
                    type: string
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 200
                data:
                  linkID: aBq
                msg: success
          headers: {}
          x-apifox-name: 成功
        x-200:Internal Server Error:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 500
                data: null
                msg: internal server error
          headers: {}
          x-apifox-name: Internal Server Error
        x-200:Permission Denied:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 801
                data: null
                msg: permission denied
          headers: {}
          x-apifox-name: Permission Denied
        x-200:Missing Parameter:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: object
                    properties:
                      exampleA:
                        type: string
                        description: 服务器获取到的参数
                      exampleB:
                        type: string
                        description: 服务器获取到的参数
                    required:
                      - exampleA
                      - exampleB
                    description: 数据
                    x-apifox-orders:
                      - exampleA
                      - exampleB
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 800
                data:
                  exampleA: Content
                  exampleB: Nothing Here
                msg: missing parameter
          headers: {}
          x-apifox-name: Missing Parameter
        x-200:Too Many Requests:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 429
                data: null
                msg: too many requests
          headers: {}
          x-apifox-name: Too Many Requests
        x-200:No Package Available:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 802
                data: null
                msg: no package available
          headers: {}
          x-apifox-name: No Package Available
        x-200:Application Not Found:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 803
                data: null
                msg: application not found
          headers: {}
          x-apifox-name: Application Not Found
        x-200:Link Invalid:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                  data:
                    type: 'null'
                  msg:
                    type: string
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 805
                data: null
                msg: link invalid
          headers: {}
          x-apifox-name: Link Invalid
        x-200:Validity Invalid:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                  data:
                    type: 'null'
                  msg:
                    type: string
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 806
                data: null
                msg: validity invalid
          headers: {}
          x-apifox-name: Validity Invalid
        x-200:Upstream Not Available:
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: integer
                    description: 状态码
                  data:
                    type: 'null'
                    description: 数据
                  msg:
                    type: string
                    description: 信息
                required:
                  - code
                  - data
                  - msg
                x-apifox-orders:
                  - code
                  - data
                  - msg
              example:
                code: 804
                data: null
                msg: upstream not available
          headers: {}
          x-apifox-name: Upstream Not Available
      security: []
      x-apifox-folder: 短链接
      x-apifox-status: released
      x-run-in-apifox: https://app.apifox.com/web/project/6547178/apis/api-367373535-run
components:
  schemas: {}
  securitySchemes: {}
servers:
  - url: https://api.gh.ink/v3
    description: 正式环境
security: []

```
