OINO TS
    Preparing search index...

    Class OINODbApi

    API class with method to process HTTP REST requests.

    Index

    Constructors

    Properties

    datamodel: OINODbDataModel

    API datamodel

    db: OINODb

    API database reference

    hashid: any

    API hashid

    API parameters

    Methods

    • Method for handling a HTTP REST request with batch update using PUT or DELETE methods.

      Parameters

      • method: string

        HTTP method of the REST request

      • rowId: string

        URL id of the REST request

      • rowData: OINODbApiData

        HTTP body data as either serialized string or unserialized JS object or OINODataRow-array or Buffer/Uint8Array binary data

      • OptionalsqlParams: OINODbSqlParams

      Returns Promise<OINODbApiResult>

    • Method for handling a HTTP REST request with GET, POST, PUT, DELETE corresponding to SQL select, insert, update and delete.

      Parameters

      • request: OINOHttpRequest

        OINO HTTP request object containing all parameters of the REST request

      • rowId: string

        URL id of the REST request

      • rowData: OINODbApiData

        HTTP body data as either serialized string or unserialized JS object or OINODataRow-array or Buffer/Uint8Array binary data

      • sqlParams: OINODbSqlParams

        SQL parameters for the REST request

      Returns Promise<OINODbApiResult>

    • Method for handling a HTTP REST request with GET, POST, PUT, DELETE corresponding to SQL select, insert, update and delete.

      Parameters

      • method: string

        HTTP method of the REST request

      • rowId: string

        URL id of the REST request

      • rowData: OINODbApiData

        HTTP body data as either serialized string or unserialized JS object or OINODataRow-array or Buffer/Uint8Array binary data

      • sqlParams: OINODbSqlParams

        SQL parameters for the REST request

      • contentType: OINOContentType = OINOContentType.json

        content type of the HTTP body data, default is JSON

      Returns Promise<OINODbApiResult>

    • Method to check if a field is included in the API params.

      Parameters

      • fieldName: string

        name of the field

      Returns boolean

    • Enable or disable debug output on errors.

      Parameters

      • debugOnError: boolean

        true to enable debug output on errors, false to disable

      Returns void