Skip to content

/AWS1/CL_IOT=>CREATEPACKAGE()

About CreatePackage

Creates an IoT software package that can be deployed to your fleet.

Requires permission to access the CreatePackage and GetIndexingConfiguration actions.

Method Signature

IMPORTING

Required arguments:

iv_packagename TYPE /AWS1/IOTPACKAGENAME /AWS1/IOTPACKAGENAME

The name of the new software package.

Optional arguments:

iv_description TYPE /AWS1/IOTRESOURCEDESCRIPTION /AWS1/IOTRESOURCEDESCRIPTION

A summary of the package being created. This can be used to outline the package's contents or purpose.

it_tags TYPE /AWS1/CL_IOTTAGMAP_W=>TT_TAGMAP TT_TAGMAP

Metadata that can be used to manage the package.

iv_clienttoken TYPE /AWS1/IOTCLIENTTOKEN /AWS1/IOTCLIENTTOKEN

A unique case-sensitive identifier that you can provide to ensure the idempotency of the request. Don't reuse this client token if a new idempotent request is required.

RETURNING

oo_output TYPE REF TO /aws1/cl_iotcreatepackagersp /AWS1/CL_IOTCREATEPACKAGERSP

Domain /AWS1/RT_ACCOUNT_ID
Primitive Type NUMC

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->/aws1/if_iot~createpackage(
  it_tags = VALUE /aws1/cl_iottagmap_w=>tt_tagmap(
    (
      VALUE /aws1/cl_iottagmap_w=>ts_tagmap_maprow(
        value = new /aws1/cl_iottagmap_w( |string| )
        key = |string|
      )
    )
  )
  iv_clienttoken = |string|
  iv_description = |string|
  iv_packagename = |string|
).

This is an example of reading all possible response values

lv_packagename = lo_result->get_packagename( ).
lv_packagearn = lo_result->get_packagearn( ).
lv_resourcedescription = lo_result->get_description( ).