Audio recorder audio

Audio recorder (audio)

The audio recorder Question is referenced by its Question type in the code, which is audio. This Question allows students to record an answer in audio form, using their device microphone.


  • is_math boolean

    Set to true to have LaTeX or MathML contents to be rendered with MathJax.

    Default: false

  • metadata object

    Object containing additional information about the Question.

  • metadata.distractor_rationale string

    Used to display individual response feedback/rationale to the learner.

  • metadata.rubric_reference string

    A unique identifier for the rubric to be used with the Question - defaults to course rubric if assigned in Activity

  • metadata.sample_answer string

    A sample answer to be displayed on the Learnosity Reports API. HTML is supported.

  • metadata.acknowledgements string

    References for any text passages, documents, images etc. used in the Question.

  • stimulus string

    The Question stimulus. This can include text, tables, images, resources and LaTeX entered via the math editor.

  • stimulus_review string

    HTML/Text content displayed only in review state rendered above the response area. Supports embedded Feature <span> tags. Will override stimulus in review state.

  • instructor_stimulus string

    HTML/Text content displayed when showInstructorStimulus is set to true on the Activity. Supports embedded Feature <span> Tags.

  • type string

    Type of Question being asked, e.g. 'association'.

    Default: "audio"

  • ui_style object

    Object used to control different aspects of the UI.

  • ui_style.fontsize string

    Controls the size of base font for this question. Options are among 'small', 'normal', 'large', 'xlarge' and 'xxlarge'.

    Default: "normal"

  • ui_style.download_link boolean

    If true, a link to download the audio asset is displayed in the UI.

  • ui_style.pause boolean

    Defines whether the pause button is displayed in the UI.

    Default: true

  • ui_style.pause_recording boolean

    When the pause button is enabled, it is visible to the student.

    Default: true

  • boolean

    Defines whether the play button is displayed in the UI.

    Default: true

  • ui_style.play_bubble boolean

    A bubble will appear on Play to show recording information (time, play/pause button, waveform, etc.) Only available in the Button UI.

    Default: true

  • ui_style.progress_bar boolean

    A visual indicator to the student, displaying how much time they have to record. In playback mode, it will indicate how long is left.

    Default: true

  • ui_style.record_bubble boolean

    Defines whether recording bubble is displayed in the UI, only available for 'button' type.

    Default: true

  • boolean

    The learner will be able to change the play position by clicking on the Progress Bar. The Play button and Progress Bar must be enabled.

    Default: true

  • ui_style.start_recording boolean

    When the record button is enabled, it is visible to the student.

    Default: true

  • ui_style.stop_recording boolean

    Defines whether the pause recording button is enabled.

    Default: true

  • ui_style.timer boolean

    The length of the recording will be displayed to the student.

    Default: true

  • ui_style.type string

    Defines the rendering type of audio question. Values: "block", "button".

    Default: "block"

  • ui_style.volume_control boolean

    Defines whether the volume control is displayed in the UI.

    Default: true

  • ui_style.volume_meter boolean

    Volume meter will be displayed to the user on playback. Play button must be enabled. Only available in Block UI.

    Default: true

  • ui_style.waveform boolean

    A wave UI will be displayed to the user on playback. The play button must be enabled.

    Default: true

  • ui_style.responsive_layout boolean

    The audio recorder size is scaled responsively, based on the size of its container.

    Default: true

  • validation object

    In this section, configure the correct answer(s) for the question.

  • validation.max_score number

    The highest score a marker can award to this question response.

  • validation.min_score_if_attempted number

    Positive value indicating the minimum score if a learner attempted the Question.

    Default: 0

  • validation.unscored boolean

    When enabled, this option will remove all scoring from the question. This is useful for creating practice questions.

    Default: false

  • description string

    Deprecated See stimulus_review.
    Description of the question and its context to be displayed. It supports HTML entities.

  • counter object

    When enabled, shows a message and a countdown in seconds to the recording start time.

  • counter.length number

    Required countdown in seconds to start recording.

    Default: 5

  • counter.template string

    Specify custom message to wrap around the counter. If custom message is not provided then default message is used. Requires {num} in custom message for the counter to be injected.

    Default: "Beginning in {num} seconds..."

  • max_length number

    The length of audio, in seconds, allowed to be recorded by the student. Maximum value is 3600 (1 hour), default value is 600 (10 minutes)

    Default: "600"

  • overwrite_warning boolean

    Set to false to suppress the overwrite warning when user attempts to re-record.

    Default: true

  • recording_cue boolean

    Set to false if the beep is NOT to be played before recording is started.

    Default: true

  • show_download_link boolean

    A link to download the student's recorded audio file will appear in review state.

    Default: false

  • silence_stop_duration number

    Duration of audio silence, in seconds, that is allowed before recording is stopped. This value is set to 0 by default, which means the silence detection is turned off.

    Default: 0

Response format

The data returned in the response format for this Question has information about the recorded audio file, which the student has recorded in response to the Question.

Response format examples

    "location": "0034/questionresponse/2019/265/0034_testing_user_01__4cbd3128-e3ab-412a-ab8f-aaf2ef96ed0d.v0",
    "type": "audio+png",
    "length": 3065,
    "created": "2019-09-23T04:12:35.678Z",
    "apiVersion": "v2.173.0",
    "revision": 1,
    "uris": {
        "mp3": "https://.../....mp3",
        "png": "https://.../....png"

Response attributes

  • location string

    The location of the recorded audio file.

  • type string

    Informs the scoring engine about what kind of data to expect in the values entered by the student. For this Question type, you must always supply a string for this attribute with the value "audio+png".

  • length numeric

    The length (in bytes) of the recorded audio file.

  • apiVersion string

    The version of the Questions API that returned this response.

  • revision numeric

    Keeps track of the number of Question attempt submissions, i.e. how many times the student answered the Question and submitted it.

  • uris object

    Universal Resource Indicators (links) for the recorded MP3 audio file and PNG graphic file of the waveform.

Was this article helpful?

Did you arrive here by accident? If so, learn more about Learnosity.