Merchant API . accounts . programs

Instance Methods

close()

Close httplib2 connections.

disable(name, body=None, x__xgafv=None)

Disable participation in the specified program for the account. Executing this method requires admin access.

enable(name, body=None, x__xgafv=None)

Enable participation in the specified program for the account. Executing this method requires admin access.

get(name, x__xgafv=None)

Retrieves the specified program for the account.

list(parent, pageSize=None, pageToken=None, x__xgafv=None)

Retrieves all programs for the account.

list_next()

Retrieves the next page of results.

Method Details

close()
Close httplib2 connections.
disable(name, body=None, x__xgafv=None)
Disable participation in the specified program for the account. Executing this method requires admin access.

Args:
  name: string, Required. The name of the program for which to disable participation for the given account. Format: `accounts/{account}/programs/{program}` (required)
  body: object, The request body.
    The object takes the form of:

{ # Request message for the DisableProgram method.
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Defines participation in a given program for the specified account. Programs provide a mechanism for adding functionality to merchant accounts. A typical example of this is the [Free product listings](https://support.google.com/merchants/topic/9240261?ref_topic=7257954,7259405,&sjid=796648681813264022-EU) program, which enables products from a merchant's store to be shown across Google for free.
  "activeRegionCodes": [ # Output only. The regions in which the account is actively participating in the program. Active regions are defined as those where all program requirements affecting the regions have been met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
    "A String",
  ],
  "documentationUri": "A String", # Output only. The URL of a Merchant Center help page describing the program.
  "name": "A String", # Identifier. The resource name of the program. Format: `accounts/{account}/programs/{program}`
  "state": "A String", # Output only. The participation state of the account in the program.
  "unmetRequirements": [ # Output only. The requirements that the account has not yet satisfied that are affecting participation in the program.
    { # Defines a requirement specified for participation in the program.
      "affectedRegionCodes": [ # Output only. The regions that are currently affected by this requirement not being met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
        "A String",
      ],
      "documentationUri": "A String", # Output only. The URL of a help page describing the requirement.
      "title": "A String", # Output only. Name of the requirement.
    },
  ],
}
enable(name, body=None, x__xgafv=None)
Enable participation in the specified program for the account. Executing this method requires admin access.

Args:
  name: string, Required. The name of the program for which to enable participation for the given account. Format: `accounts/{account}/programs/{program}` (required)
  body: object, The request body.
    The object takes the form of:

{ # Request message for the EnableProgram method.
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Defines participation in a given program for the specified account. Programs provide a mechanism for adding functionality to merchant accounts. A typical example of this is the [Free product listings](https://support.google.com/merchants/topic/9240261?ref_topic=7257954,7259405,&sjid=796648681813264022-EU) program, which enables products from a merchant's store to be shown across Google for free.
  "activeRegionCodes": [ # Output only. The regions in which the account is actively participating in the program. Active regions are defined as those where all program requirements affecting the regions have been met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
    "A String",
  ],
  "documentationUri": "A String", # Output only. The URL of a Merchant Center help page describing the program.
  "name": "A String", # Identifier. The resource name of the program. Format: `accounts/{account}/programs/{program}`
  "state": "A String", # Output only. The participation state of the account in the program.
  "unmetRequirements": [ # Output only. The requirements that the account has not yet satisfied that are affecting participation in the program.
    { # Defines a requirement specified for participation in the program.
      "affectedRegionCodes": [ # Output only. The regions that are currently affected by this requirement not being met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
        "A String",
      ],
      "documentationUri": "A String", # Output only. The URL of a help page describing the requirement.
      "title": "A String", # Output only. Name of the requirement.
    },
  ],
}
get(name, x__xgafv=None)
Retrieves the specified program for the account.

Args:
  name: string, Required. The name of the program to retrieve. Format: `accounts/{account}/programs/{program}` (required)
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Defines participation in a given program for the specified account. Programs provide a mechanism for adding functionality to merchant accounts. A typical example of this is the [Free product listings](https://support.google.com/merchants/topic/9240261?ref_topic=7257954,7259405,&sjid=796648681813264022-EU) program, which enables products from a merchant's store to be shown across Google for free.
  "activeRegionCodes": [ # Output only. The regions in which the account is actively participating in the program. Active regions are defined as those where all program requirements affecting the regions have been met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
    "A String",
  ],
  "documentationUri": "A String", # Output only. The URL of a Merchant Center help page describing the program.
  "name": "A String", # Identifier. The resource name of the program. Format: `accounts/{account}/programs/{program}`
  "state": "A String", # Output only. The participation state of the account in the program.
  "unmetRequirements": [ # Output only. The requirements that the account has not yet satisfied that are affecting participation in the program.
    { # Defines a requirement specified for participation in the program.
      "affectedRegionCodes": [ # Output only. The regions that are currently affected by this requirement not being met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
        "A String",
      ],
      "documentationUri": "A String", # Output only. The URL of a help page describing the requirement.
      "title": "A String", # Output only. Name of the requirement.
    },
  ],
}
list(parent, pageSize=None, pageToken=None, x__xgafv=None)
Retrieves all programs for the account.

Args:
  parent: string, Required. The name of the account for which to retrieve all programs. Format: `accounts/{account}` (required)
  pageSize: integer, Optional. The maximum number of programs to return in a single response. If unspecified (or 0), a default size of 1000 is used. The maximum value is 1000; values above 1000 will be coerced to 1000.
  pageToken: string, Optional. A continuation token, received from a previous `ListPrograms` call. Provide this to retrieve the next page.
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Response message for the ListPrograms method.
  "nextPageToken": "A String", # A token that can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.
  "programs": [ # The programs for the given account.
    { # Defines participation in a given program for the specified account. Programs provide a mechanism for adding functionality to merchant accounts. A typical example of this is the [Free product listings](https://support.google.com/merchants/topic/9240261?ref_topic=7257954,7259405,&sjid=796648681813264022-EU) program, which enables products from a merchant's store to be shown across Google for free.
      "activeRegionCodes": [ # Output only. The regions in which the account is actively participating in the program. Active regions are defined as those where all program requirements affecting the regions have been met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
        "A String",
      ],
      "documentationUri": "A String", # Output only. The URL of a Merchant Center help page describing the program.
      "name": "A String", # Identifier. The resource name of the program. Format: `accounts/{account}/programs/{program}`
      "state": "A String", # Output only. The participation state of the account in the program.
      "unmetRequirements": [ # Output only. The requirements that the account has not yet satisfied that are affecting participation in the program.
        { # Defines a requirement specified for participation in the program.
          "affectedRegionCodes": [ # Output only. The regions that are currently affected by this requirement not being met. Region codes are defined by [CLDR](https://cldr.unicode.org/). This is either a country where the program applies specifically to that country or `001` when the program applies globally.
            "A String",
          ],
          "documentationUri": "A String", # Output only. The URL of a help page describing the requirement.
          "title": "A String", # Output only. Name of the requirement.
        },
      ],
    },
  ],
}
list_next()
Retrieves the next page of results.

        Args:
          previous_request: The request for the previous page. (required)
          previous_response: The response from the request for the previous page. (required)

        Returns:
          A request object that you can call 'execute()' on to request the next
          page. Returns None if there are no more items in the collection.