Method: projects.locations.collectApiData

Collect API data from a source and push it to Hub's collect layer.

HTTP request

POST https://apihub.googleapis.com/v1/{location=projects/*/locations/*}:collectApiData

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
location

string

Required. The regional location of the API hub instance and its resources. Format: projects/{project}/locations/{location}

Request body

The request body contains data with the following structure:

JSON representation
 { 
 "collectionType" 
 : 
 enum (  CollectionType 
 
) 
 , 
 "pluginInstance" 
 : 
 string 
 , 
 "actionId" 
 : 
 string 
 , 
 "apiData" 
 : 
 { 
 object (  ApiData 
 
) 
 } 
 } 
Fields
collectionType

enum ( CollectionType )

Required. The type of collection. Applies to all entries in apiData .

pluginInstance

string

Required. The plugin instance collecting the API data. Format: projects/{project}/locations/{location}/plugins/{plugin}/instances/{instance} .

actionId

string

Required. The action ID to be used for collecting the API data. This should map to one of the action IDs specified in action configs in the plugin.

apiData

object ( ApiData )

Required. The API data to be collected.

Response body

If successful, the response body contains an instance of Operation .

Authorization scopes

Requires the following OAuth scope:

  • https://www.googleapis.com/auth/cloud-platform

CollectionType

The type of the collect request.

Enums
COLLECTION_TYPE_UNSPECIFIED The default value. This value is used if the collection type is omitted.
COLLECTION_TYPE_UPSERT The collection type is upsert. This should be used when an API is created or updated at the source.
COLLECTION_TYPE_DELETE The collection type is delete. This should be used when an API is deleted at the source.

ApiData

The API data to be collected.

JSON representation
 { 
 // Union field Data 
can be only one of the following: 
 "apiMetadataList" 
 : 
 { 
 object (  ApiMetadataList 
 
) 
 } 
 // End of list of possible types for union field Data 
. 
 } 
Fields
Union field Data . The data to be collected. Data can be only one of the following:

ApiMetadataList

The message to hold repeated API metadata.

JSON representation
 { 
 "apiMetadata" 
 : 
 [ 
 { 
 object (  APIMetadata 
 
) 
 } 
 ] 
 } 
Fields
Create a Mobile Website
View Site in Mobile | Classic
Share by: