Kernel::GenericInterface::Invoker::ITSM::ConfigItem

NAME

Kernel::GenericInterface::Invoker::ITSM::ConfigItem – GenericInterface for ITSM ConfigItems

SYNOPSIS

GenericInterface for ITSM ConfigItems

PUBLIC INTERFACE

new()

usually, you want to create an instance of this by using Kernel::GenericInterface::Invoker->new();

PrepareRequest()

prepare the invocation of the configured remote web service. This will just return the data that was passed to the function.

    my $Result = $InvokerObject->PrepareRequest(
        Data => {                               # data payload
            ...
        },
    );

    $Result = {
        Success         => 1,                   # 0 or 1
        ErrorMessage    => '',                  # in case of error
        Data            => {                    # data payload after Invoker
            ...
        },
    };
HandleResponse()

handle response data of the configured remote web service. This will just return the data that was passed to the function.

    my $Result = $InvokerObject->HandleResponse(
        ResponseSuccess      => 1,              # success status of the remote web service
        ResponseErrorMessage => '',             # in case of web service error
        Data => {                               # data payload
            ...
        },
    );

    $Result = {
        Success         => 1,                   # 0 or 1
        ErrorMessage    => '',                  # in case of error
        Data            => {                    # data payload after Invoker
            ...
        },
    };
Error()

Write error message to OTRS log and return exit structure.

    my $ExitStructure = $CommonObject->Error(
        ErrorMessage    => 'an error message',
    );

returns

    $ExitStructure = {
        Success      => 0,
        ErrorMessage => 'an error message',
    };
Success()

Write LastRunTimestamp cache entry and return exit structure.

    my $ExitStructure = $CommonObject->Success(
        Data => $ReturnData,
    );

returns

    $ExitStructure = {
        Success => 1,
        Data    => $ReturnData,
    };
Scroll to Top