---
# System prepended metadata

title: Automatic Speech Recognition (eng)
tags: [automatic_speech_recognition_eng.yaml, Microservice Docs, yaml]

---

Automatic Speech Recognition (eng)
===
###### tags: `Microservice Docs` `yaml` `automatic_speech_recognition_eng.yaml`
---

openapi: 3.0.1
info:
  title: Automatic Speech Recognition ENG
  description: |+
    This Voice microservice takes in an audio file (in WAV format at 16kHz) and transcribes English speech content within the input file into text.
    
    The Automatic Speech Recognition (ASR) AI model is employed to understand the mapping of sound features to actual words in English.
    
    Use this microservice if the audio file consists of mostly speech with no long pauses in between.
    
  version: '0.1'
servers:
  - url: 'https://apis.sentient.io'
tags:
- name: "v0.1"
  description: "Published Date - Jun 18, 2018"
paths:
  /microservices/voice/asreng/v0.1/getpredictions:
    post:
      tags:
        - v0.1
      responses:
        '200':
          description: success response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/success'
              example:
                message: Hi there
                status: success
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/unauthorized'
        '402':
          description: Payment Required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/paymentrequired'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/forbidden'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/notfound'
        '419':
          description: Input Field Missing
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/inputfieldmissing'
        '420':
          description: Input Limit Exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/inputlimitexceeded'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/servererror'
        '504':
          description: Gateway Timeout
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/gatewaytimeout'
      security:
        - APIAuthorizer: []
      requestBody:
        content:
          application/json:
              schema:
                $ref: '#/components/schemas/input'
        required: true
components:
  schemas:
    success:
      type: object
      properties:
              message:
                x-name: message
                type: string
                example: Hi there
                description: Converted Text
              status:
               x-name: status
               type: string
               example: success
               description: The status of the API call success/failure
    unauthorized:
      type: object
      properties:
        message:
          type: string
          example: Missing Authentication Token
        status:
          type: string
          example: Failure
    forbidden:
      type: object
      properties:
        message:
          type: string
          example: Access Denied Unauthorized User
        status:
          type: string
          example: Failure
    paymentrequired:
      type: object
      properties:
        message:
          type: string
          example: Insufficient Credits Kindly Top Up
        status:
          type: string
          example: Failure
    notfound:
      type: object
      properties:
        message:
          type: string
          example: Invalid Request URL
        status:
          type: string
          example: Failure
    servererror:
      type: object
      properties:
        message:
          type: string
          example: Internal Server Error
        status:
          type: string
          example: Failure
    gatewaytimeout:
      type: object
      properties:
        message:
          type: string
          example: Request Timeout
        status:
          type: string
          example: Failure
    inputfieldmissing:
      type: object
      properties:
        message:
          type: string
          example: Input Field Missing
        status:
          type: string
          example: Failure
    inputlimitexceeded:
      type: object
      properties:
        message:
          type: string
          example: Input Limit Exceeded
        status:
          type: string
          example: Failure
    input:
      type: object
      required:
        - audio 
      properties:
        audio:
          x-name: audio
          type: string
          default: true
          example: data:audio/wav;base64,UklGRkbiBABXQVZFZm10IBAAAAABA...
          description: |+
            Input file in base64 format and needs to be prefixed by the data type and encoding
            data:audio/wav;base64,<wav in base64 string>
    versions:
      type: object
      properties: 
        v0.1:
         type: array
         items:
          oneOf:
            - type: string
              example: Published Date - Jun 18,2018
              description: Initial version release
  securitySchemes:
    APIAuthorizer:
      type: apiKey
      name: x-api-key
      in: header
      x-amazon-apigateway-authtype: custom
      description: Authentication is done using the x-api-key in the request header

