# Tag Manager API . accounts . containers

## Instance Methods

Returns the macros Resource.

Returns the rules Resource.

Returns the tags Resource.

Returns the triggers Resource.

Returns the variables Resource.

Returns the versions Resource.

Creates a Container.

Deletes a Container.

Gets a Container.

Lists all Containers that belongs to a GTM Account.

Updates a Container. This method supports patch semantics.

Updates a Container.

### Method Details

`create(accountId, body)`

    Creates a Container.

    Args:
      accountId: string, The GTM Account ID. (required)
      body: object, The request body. (required)
        The object takes the form of:

    { # Represents a Google Tag Manager Container.
      "timeZoneId": "A String", # Container Time Zone ID.
      "timeZoneCountryId": "A String", # Container Country ID.
      "publicId": "A String", # Container Public ID.
      "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
      "domainName": [ # Optional list of domain names associated with the Container.
        "A String",
      ],
      "notes": "A String", # Container Notes.
      "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
        "A String",
      ],
      "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
      "accountId": "A String", # GTM Account ID.
      "name": "A String", # Container display name.
    }

    Returns:
      An object of the form:

        { # Represents a Google Tag Manager Container.
        "timeZoneId": "A String", # Container Time Zone ID.
        "timeZoneCountryId": "A String", # Container Country ID.
        "publicId": "A String", # Container Public ID.
        "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
        "domainName": [ # Optional list of domain names associated with the Container.
          "A String",
        ],
        "notes": "A String", # Container Notes.
        "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
          "A String",
        ],
        "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
        "accountId": "A String", # GTM Account ID.
        "name": "A String", # Container display name.
      }

`delete(accountId, containerId)`

    Deletes a Container.

    Args:
      accountId: string, The GTM Account ID. (required)
      containerId: string, The GTM Container ID. (required)

`get(accountId, containerId)`

    Gets a Container.

    Args:
      accountId: string, The GTM Account ID. (required)
      containerId: string, The GTM Container ID. (required)

    Returns:
      An object of the form:

        { # Represents a Google Tag Manager Container.
        "timeZoneId": "A String", # Container Time Zone ID.
        "timeZoneCountryId": "A String", # Container Country ID.
        "publicId": "A String", # Container Public ID.
        "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
        "domainName": [ # Optional list of domain names associated with the Container.
          "A String",
        ],
        "notes": "A String", # Container Notes.
        "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
          "A String",
        ],
        "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
        "accountId": "A String", # GTM Account ID.
        "name": "A String", # Container display name.
      }

`list(accountId)`

    Lists all Containers that belongs to a GTM Account.

    Args:
      accountId: string, The GTM Account ID. (required)

    Returns:
      An object of the form:

        { # List Containers Response.
        "containers": [ # All Containers of a GTM Account.
          { # Represents a Google Tag Manager Container.
            "timeZoneId": "A String", # Container Time Zone ID.
            "timeZoneCountryId": "A String", # Container Country ID.
            "publicId": "A String", # Container Public ID.
            "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
            "domainName": [ # Optional list of domain names associated with the Container.
              "A String",
            ],
            "notes": "A String", # Container Notes.
            "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
              "A String",
            ],
            "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
            "accountId": "A String", # GTM Account ID.
            "name": "A String", # Container display name.
          },
        ],
      }

`patch(accountId, containerId, body, fingerprint=None)`

    Updates a Container. This method supports patch semantics.

    Args:
      accountId: string, The GTM Account ID. (required)
      containerId: string, The GTM Container ID. (required)
      body: object, The request body. (required)
        The object takes the form of:

    { # Represents a Google Tag Manager Container.
      "timeZoneId": "A String", # Container Time Zone ID.
      "timeZoneCountryId": "A String", # Container Country ID.
      "publicId": "A String", # Container Public ID.
      "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
      "domainName": [ # Optional list of domain names associated with the Container.
        "A String",
      ],
      "notes": "A String", # Container Notes.
      "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
        "A String",
      ],
      "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
      "accountId": "A String", # GTM Account ID.
      "name": "A String", # Container display name.
    }

      fingerprint: string, When provided, this fingerprint must match the fingerprint of the container in storage.

    Returns:
      An object of the form:

        { # Represents a Google Tag Manager Container.
        "timeZoneId": "A String", # Container Time Zone ID.
        "timeZoneCountryId": "A String", # Container Country ID.
        "publicId": "A String", # Container Public ID.
        "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
        "domainName": [ # Optional list of domain names associated with the Container.
          "A String",
        ],
        "notes": "A String", # Container Notes.
        "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
          "A String",
        ],
        "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
        "accountId": "A String", # GTM Account ID.
        "name": "A String", # Container display name.
      }

`update(accountId, containerId, body, fingerprint=None)`

    Updates a Container.

    Args:
      accountId: string, The GTM Account ID. (required)
      containerId: string, The GTM Container ID. (required)
      body: object, The request body. (required)
        The object takes the form of:

    { # Represents a Google Tag Manager Container.
      "timeZoneId": "A String", # Container Time Zone ID.
      "timeZoneCountryId": "A String", # Container Country ID.
      "publicId": "A String", # Container Public ID.
      "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
      "domainName": [ # Optional list of domain names associated with the Container.
        "A String",
      ],
      "notes": "A String", # Container Notes.
      "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
        "A String",
      ],
      "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
      "accountId": "A String", # GTM Account ID.
      "name": "A String", # Container display name.
    }

      fingerprint: string, When provided, this fingerprint must match the fingerprint of the container in storage.

    Returns:
      An object of the form:

        { # Represents a Google Tag Manager Container.
        "timeZoneId": "A String", # Container Time Zone ID.
        "timeZoneCountryId": "A String", # Container Country ID.
        "publicId": "A String", # Container Public ID.
        "containerId": "A String", # The Container ID uniquely identifies the GTM Container.
        "domainName": [ # Optional list of domain names associated with the Container.
          "A String",
        ],
        "notes": "A String", # Container Notes.
        "usageContext": [ # List of Usage Contexts for the Container. Valid values include: web, android, ios.
          "A String",
        ],
        "fingerprint": "A String", # The fingerprint of the GTM Container as computed at storage time. This value is recomputed whenever the account is modified.
        "accountId": "A String", # GTM Account ID.
        "name": "A String", # Container display name.
      }