@camunda8/sdk
    Preparing search index...

    Interface JsonApiEndpointRequest<T>

    interface JsonApiEndpointRequest<T> {
        body?: T;
        formData?: FormData;
        headers?: { [key: string]: string | number | boolean };
        json?: true;
        method: "GET" | "POST" | "PUT" | "DELETE";
        parseJson?: (
            text: string,
            reviver?: (this: any, key: string, value: any) => any,
        ) => any;
        queryParams?: { [key: string]: undefined | string | number | boolean };
        urlPath: string;
    }

    Type Parameters

    • T

    Hierarchy (View Summary)

    Index

    Properties

    body?: T

    The request body.

    formData?: FormData

    TODO: multi-part form support needs to be implemented

    headers?: { [key: string]: string | number | boolean }

    The headers.

    json?: true

    JSON-parse response? Default: true

    method: "GET" | "POST" | "PUT" | "DELETE"
    parseJson?: (
        text: string,
        reviver?: (this: any, key: string, value: any) => any,
    ) => any

    A custom JSON parsing function

    Type declaration

      • (text: string, reviver?: (this: any, key: string, value: any) => any): any
      • Converts a JavaScript Object Notation (JSON) string into an object.

        Parameters

        • text: string

          A valid JSON string.

        • Optionalreviver: (this: any, key: string, value: any) => any

          A function that transforms the results. This function is called for each member of the object. If a member contains nested objects, the nested objects are transformed before the parent object is.

        Returns any

    queryParams?: { [key: string]: undefined | string | number | boolean }

    The query parameters.

    urlPath: string

    The URL path of the API endpoint.