API Platform Base Path: https://api.enterprise.apigee.com/v1/o/{org_name}

API Resource Path: /apiproducts/{apiproduct_name}

This method updates an existing APi Product

Verb: PUT

Auth: Basic Auth

Content Types:

application/json
text/xml

Developer Guide Topic

Call PUT on an existing API Product to update the API Product. You are must include the entire profile of the existing API product, include the elements to be updated, in the update request payload.

Sample Request:
curl -H "Content-Type:application/json" -X PUT -d \
   '{"apiResources": [ "/weather" ],      
     "approvalType": "auto", 
     "attributes":
      [{"name": "description", "value": "Introductory API Product"},
       {"name": "developer.quota.interval","value": "1"},
       {"name": "developer.quota.limit","value": "1000"},
       {"name": "developer.quota.timeunit","value": "month"},
       {"name": "servicePlan", "value": "Introductory"}],
     "description": "New Description",
     "displayName": "Free API Product",
     "name": "weather_free",
     "scopes": []}' \
-u myname:mypass https://api.enterprise.apigee.com/v1/o/{org_name}/apiproducts/{apiproduct_name}
Request Payload Elements:
Name Description Default Required?
approvalType Manual or Auto. If Manual, consumer key is generated and returned in 'pending' state. If manual consumer key generated and returned in 'Approved' state. N/A No
attributes Arbitrary name/value pairs, most commonly used to store variables that define Rate Limit (Quota or Spike Arrest) settings for an API Product (otherwise known as a Service Plan) N/A No
displayName The display name of the API Product, used in Apps that display the API Product to Developers N/A No
apiResources A comma separated list of API resources to be bundled in the API Product. N/A No
Sample Response:
{
  "apiResources" : [ "/**" ],
  "approvalType" : "auto",
  "attributes" : [ {
    "name" : "description",
    "value" : "Introductory API Product"
  }, {
    "name" : "developer.quota.interval",
    "value" : "1"
  }, {
    "name" : "developer.quota.limit",
    "value" : "1000"
  }, {
    "name" : "developer.quota.timeunit",
    "value" : "month"
  }, {
    "name" : "servicePlan",
    "value" : "Introductory"
  } ],
  "createdAt" : 1349794919450,
  "createdBy" : "admin@apigee.com",
  "description" : "New Description",
  "displayName" : "Free API Product",
  "lastModifiedAt" : 1354734065117,
  "lastModifiedBy" : "admin@apigee.com",
  "name" : "weather_free",
  "scopes" : [ ]
}
Response Payload Elements:
Name Description
apiResources A list of URIs (including wildcards) that represent the bundle of APIs permitted to consumers of this API Product
approvalType Determines the state of the consumer key generated for requesters of this API Product. For Auto, key are generated in "Approved' state. For Manual, keys are approved in 'Pending' state.
attributes Any app-specific arbitrary attributes that may be used to define visibility of the API Product or runtime policy enforcement (such as setting for a rate-limiting policy.
createdAt Unix time
createdBy Apigee user account name of the individual who submitted the POST request that created this entity
lastModifiedAt Unix time when the API product was last modified
lastModifiedBy Apigee user account name of the individual who last modified this entity
name Name of the API Product
scopes Oauth scopes required in the access token used to consume any of the API resources (URIs) bundled in this API Product
Errors
{
  "code" : "keymanagement.service.apiproduct_doesnot_exist",
  "message" : "ApiProduct with name sandbox1 does not exist",
  "contexts" : [ ]
}
Last updated: about 1 month ago