Method: organizations.environments.analytics.admin.getSchemav2

Gets a list of metrics and dimensions that can be used to create analytics queries and reports. Each schema element contains the name of the field, its associated type, and a flag indicating whether it is a standard or custom field.

HTTP request

GET https://apigee.googleapis.com/v1/{name=organizations/*/environments/*/analytics/admin/schemav2}

The URL uses gRPC Transcoding syntax.

Path parameters

Parameters
name

string

Required. Path to the schema. Use the following structure in your request: organizations/{org}/environments/{env}/analytics/admin/schemav2.

Authorization requires the following IAM permission on the specified resource name:

  • apigee.environments.get

Query parameters

Parameters
type

string

Required. Name of the dataset for which you want to retrieve the schema. For example: fact or agg_cus1

disableCache

boolean

Flag that specifies whether the schema is be read from the database or cache. Set to true to read the schema from the database. Defaults to cache.

Request body

The request body must be empty.

Response body

Response for Schema call

If successful, the response body contains data with the following structure:

JSON representation
{
  "dimensions": [
    {
      object (SchemaElement)
    }
  ],
  "metrics": [
    {
      object (SchemaElement)
    }
  ],
  "meta": [
    string
  ]
}
Fields
dimensions[]

object (SchemaElement)

List of schema fields grouped as dimensions.

metrics[]

object (SchemaElement)

List of schema fields grouped as dimensions that can be used with an aggregate function such as sum, avg, min, and max.

meta[]

string

Additional metadata associated with schema. This is a legacy field and usually consists of an empty array of strings.

Authorization scopes

Requires the following OAuth scope:

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

SchemaElement

Message type for the schema element

JSON representation
{
  "name": string,
  "properties": {
    object (SchemaProperty)
  }
}
Fields
name

string

Name of the field.

properties

object (SchemaProperty)

Properties for the schema field. For example: { "createTime": "2016-02-26T10:23:09.592Z", "custom": "false", "type": "string" }

SchemaProperty

Properties for the schema field.

JSON representation
{
  "createTime": string,
  "custom": string,
  "type": string
}
Fields
createTime

string

Time the field was created in RFC3339 string form. For example: 2016-02-26T10:23:09.592Z.

custom

string

Flag that specifies whether the field is standard in the dataset or a custom field created by the customer. true indicates that it is a custom field.

type

string

Data type of the field.