Skip to content

/AWS1/CL_GUR=>TAGRESOURCE()

About TagResource

Adds one or more tags to an associated repository.

Method Signature

IMPORTING

Required arguments:

iv_resourcearn TYPE /AWS1/GURASSOCIATIONARN /AWS1/GURASSOCIATIONARN

The Amazon Resource Name (ARN) of the RepositoryAssociation object. You can retrieve this ARN by calling ListRepositoryAssociations.

it_tags TYPE /AWS1/CL_GURTAGMAP_W=>TT_TAGMAP TT_TAGMAP

An array of key-value pairs used to tag an associated repository. A tag is a custom attribute label with two parts:

  • A tag key (for example, CostCenter, Environment, Project, or Secret). Tag keys are case sensitive.

  • An optional field known as a tag value (for example, 111122223333, Production, or a team name). Omitting the tag value is the same as using an empty string. Like tag keys, tag values are case sensitive.

RETURNING

oo_output TYPE REF TO /aws1/cl_gurtagresourcersp /AWS1/CL_GURTAGRESOURCERSP

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_gur~tagresource(
  it_tags = VALUE /aws1/cl_gurtagmap_w=>tt_tagmap(
    (
      VALUE /aws1/cl_gurtagmap_w=>ts_tagmap_maprow(
        key = |string|
        value = new /aws1/cl_gurtagmap_w( |string| )
      )
    )
  )
  iv_resourcearn = |string|
).

This is an example of reading all possible response values