Skip to main content

subscriptions

Creates, updates, deletes, gets or lists a subscriptions resource.

Overview

Namesubscriptions
TypeResource
Idgoogle.apigee.subscriptions

Fields

NameDatatypeDescription
namestringOutput only. Name of the API product subscription.
apiproductstringName of the API product for which the developer is purchasing a subscription.
createdAtstringOutput only. Time when the API product subscription was created in milliseconds since epoch.
endTimestringTime when the API product subscription ends in milliseconds since epoch.
lastModifiedAtstringOutput only. Time when the API product subscription was last modified in milliseconds since epoch.
startTimestringTime when the API product subscription starts in milliseconds since epoch.

Methods

NameAccessible byRequired ParamsDescription
organizations_developers_subscriptions_getSELECTdevelopersId, organizationsId, subscriptionsIdGets details for an API product subscription.
organizations_developers_subscriptions_listSELECTdevelopersId, organizationsIdLists all API product subscriptions for a developer.
organizations_developers_subscriptions_createINSERTdevelopersId, organizationsIdCreates a subscription to an API product.
organizations_developers_subscriptions_expireEXECdevelopersId, organizationsId, subscriptionsIdExpires an API product subscription immediately.

SELECT examples

Lists all API product subscriptions for a developer.

SELECT
name,
apiproduct,
createdAt,
endTime,
lastModifiedAt,
startTime
FROM google.apigee.subscriptions
WHERE developersId = '{{ developersId }}'
AND organizationsId = '{{ organizationsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new subscriptions resource.

/*+ create */
INSERT INTO google.apigee.subscriptions (
developersId,
organizationsId,
endTime,
startTime,
apiproduct
)
SELECT
'{{ developersId }}',
'{{ organizationsId }}',
'{{ endTime }}',
'{{ startTime }}',
'{{ apiproduct }}'
;