@voidmerge/doc
    Preparing search index...

    Class ResponseFnOk

    Success response type for a function request.

    Index

    Constructors

    • Construct a new FnOk response instance.

      Parameters

      • Optionalinput: { body: Uint8Array; headers?: { [header: string]: string }; status: number }

      Returns ResponseFnOk

    Properties

    body: Uint8Array

    Response body.

    headers: { [header: string]: string }

    Response headers.

    status: number

    Status code (i.e. 200).

    type: "fnResOk"

    Type marker.

    Methods

    • Set json body content.

      Parameters

      • json: any
      • Optionalpretty: boolean

      Returns ResponseFnOk

    • Set text body content.

      Parameters

      • text: string

      Returns ResponseFnOk

    • Set the body.

      Parameters

      • body: Uint8Array

      Returns ResponseFnOk

    • Set a header.

      Parameters

      • key: string
      • val: string

      Returns ResponseFnOk

    • Set the status code.

      Parameters

      • status: number

      Returns ResponseFnOk