{
 "kind": "discovery#restDescription",
 "etag": "\"ye6orv2F-1npMW3u9suM3a7C5Bo/aRfd7FZnMyWmSYyC0t8ruQh7iCI\"",
 "discoveryVersion": "v1",
 "id": "cloudtrace:v1",
 "name": "cloudtrace",
 "version": "v1",
 "revision": "20150825",
 "title": "Google Cloud Trace API",
 "description": "The Google Cloud Trace API provides services for reading and writing runtime trace data for Cloud applications.",
 "ownerDomain": "google.com",
 "ownerName": "Google",
 "icons": {
  "x16": "http://www.google.com/images/icons/product/search-16.gif",
  "x32": "http://www.google.com/images/icons/product/search-32.gif"
 },
 "documentationLink": "https://cloud.google.com/tools/cloud-trace",
 "protocol": "rest",
 "baseUrl": "https://cloudtrace.googleapis.com/",
 "basePath": "/",
 "rootUrl": "https://cloudtrace.googleapis.com/",
 "servicePath": "",
 "batchPath": "batch",
 "parameters": {
  "access_token": {
   "type": "string",
   "description": "OAuth access token.",
   "location": "query"
  },
  "alt": {
   "type": "string",
   "description": "Data format for response.",
   "default": "json",
   "enumDescriptions": [
    "Responses with Content-Type of application/json",
    "Media download with context-dependent Content-Type",
    "Responses with Content-Type of application/x-protobuf"
   ],
   "location": "query"
  },
  "bearer_token": {
   "type": "string",
   "description": "OAuth bearer token.",
   "location": "query"
  },
  "callback": {
   "type": "string",
   "description": "JSONP",
   "location": "query"
  },
  "fields": {
   "type": "string",
   "description": "Selector specifying which fields to include in a partial response.",
   "location": "query"
  },
  "key": {
   "type": "string",
   "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
   "location": "query"
  },
  "oauth_token": {
   "type": "string",
   "description": "OAuth 2.0 token for the current user.",
   "location": "query"
  },
  "pp": {
   "type": "boolean",
   "description": "Pretty-print response.",
   "default": "true",
   "location": "query"
  },
  "prettyPrint": {
   "type": "boolean",
   "description": "Returns response with indentations and line breaks.",
   "default": "true",
   "location": "query"
  },
  "quotaUser": {
   "type": "string",
   "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.",
   "location": "query"
  },
  "upload_protocol": {
   "type": "string",
   "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").",
   "location": "query"
  },
  "uploadType": {
   "type": "string",
   "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").",
   "location": "query"
  },
  "$.xgafv": {
   "type": "string",
   "description": "V1 error format.",
   "enumDescriptions": [
    "v1 error format",
    "v2 error format"
   ],
   "location": "query"
  }
 },
 "auth": {
  "oauth2": {
   "scopes": {
    "https://www.googleapis.com/auth/cloud-platform": {
     "description": "View and manage your data across Google Cloud Platform services"
    }
   }
  }
 },
 "schemas": {
  "ListTracesResponse": {
   "id": "ListTracesResponse",
   "type": "object",
   "description": "The response message for the ListTraces method.",
   "properties": {
    "traces": {
     "type": "array",
     "description": "The list of trace records returned.",
     "items": {
      "$ref": "Trace"
     }
    },
    "nextPageToken": {
     "type": "string",
     "description": "If defined, indicates that there are more topics that match the request, and this value should be passed to the next ListTopicsRequest to continue."
    }
   }
  },
  "Trace": {
   "id": "Trace",
   "type": "object",
   "description": "A Trace is a collection of spans describing the execution timings of a single operation.",
   "properties": {
    "projectId": {
     "type": "string",
     "description": "The Project ID of the Google Cloud project."
    },
    "traceId": {
     "type": "string",
     "description": "A 128-bit numeric value, formatted as a 32-byte hex string, that represents a trace. Each trace should have an identifier that is globally unique."
    },
    "spans": {
     "type": "array",
     "description": "The collection of span records within this trace. Spans that appear in calls to PatchTraces may be incomplete or partial.",
     "items": {
      "$ref": "TraceSpan"
     }
    }
   }
  },
  "TraceSpan": {
   "id": "TraceSpan",
   "type": "object",
   "description": "A span is the data recorded with a single span.",
   "properties": {
    "spanId": {
     "type": "string",
     "description": "Identifier of the span within the trace. Each span should have an identifier that is unique per trace.",
     "format": "uint64"
    },
    "kind": {
     "type": "string",
     "description": "SpanKind distinguishes spans generated in a particular context. For example, two spans with the same name, one with the kind RPC_CLIENT, and the other with RPC_SERVER can indicate the queueing latency associated with the span.",
     "enum": [
      "SPAN_KIND_UNSPECIFIED",
      "RPC_SERVER",
      "RPC_CLIENT"
     ]
    },
    "name": {
     "type": "string",
     "description": "The name of the trace. This is sanitized and displayed on the UI. This may be a method name or some other per-callsite name. For the same binary and the same call point, it is a good practice to choose a consistent name in order to correlate cross-trace spans."
    },
    "startTime": {
     "type": "string",
     "description": "The start time of the span in nanoseconds from the UNIX epoch."
    },
    "endTime": {
     "type": "string",
     "description": "The end time of the span in nanoseconds from the UNIX epoch."
    },
    "parentSpanId": {
     "type": "string",
     "description": "Identifies the parent of the current span. May be missing. Serialized bytes representation of SpanId.",
     "format": "uint64"
    },
    "labels": {
     "type": "object",
     "description": "Annotations via labels.",
     "additionalProperties": {
      "type": "string"
     }
    }
   }
  },
  "Traces": {
   "id": "Traces",
   "type": "object",
   "description": "A list of traces for the PatchTraces method.",
   "properties": {
    "traces": {
     "type": "array",
     "description": "A list of traces.",
     "items": {
      "$ref": "Trace"
     }
    }
   }
  },
  "Empty": {
   "id": "Empty",
   "type": "object",
   "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`."
  }
 },
 "resources": {
  "projects": {
   "methods": {
    "patchTraces": {
     "id": "cloudtrace.projects.patchTraces",
     "path": "v1/projects/{projectId}/traces",
     "httpMethod": "PATCH",
     "description": "Updates the existing traces specified by PatchTracesRequest and inserts the new traces. Any existing trace or span fields included in an update are overwritten by the update, and any additional fields in an update are merged with the existing trace data.",
     "parameters": {
      "projectId": {
       "type": "string",
       "description": "The project id of the trace to patch.",
       "required": true,
       "location": "path"
      }
     },
     "parameterOrder": [
      "projectId"
     ],
     "request": {
      "$ref": "Traces"
     },
     "response": {
      "$ref": "Empty"
     },
     "scopes": [
      "https://www.googleapis.com/auth/cloud-platform"
     ]
    }
   },
   "resources": {
    "traces": {
     "methods": {
      "list": {
       "id": "cloudtrace.projects.traces.list",
       "path": "v1/projects/{projectId}/traces",
       "httpMethod": "GET",
       "description": "List traces matching the filter expression.",
       "parameters": {
        "projectId": {
         "type": "string",
         "description": "The stringified-version of the project id.",
         "required": true,
         "location": "path"
        },
        "view": {
         "type": "string",
         "description": "ViewType specifies the projection of the result.",
         "enum": [
          "VIEW_TYPE_UNSPECIFIED",
          "MINIMAL",
          "ROOTSPAN",
          "COMPLETE"
         ],
         "location": "query"
        },
        "pageSize": {
         "type": "integer",
         "description": "Maximum number of topics to return. If not specified or \u003c= 0, the implementation will select a reasonable value. The implemenation may always return fewer than the requested page_size.",
         "format": "int32",
         "location": "query"
        },
        "pageToken": {
         "type": "string",
         "description": "The token identifying the page of results to return from the ListTraces method. If present, this value is should be taken from the next_page_token field of a previous ListTracesResponse.",
         "location": "query"
        },
        "startTime": {
         "type": "string",
         "description": "End of the time interval (inclusive).",
         "location": "query"
        },
        "endTime": {
         "type": "string",
         "description": "Start of the time interval (exclusive).",
         "location": "query"
        },
        "filter": {
         "type": "string",
         "description": "An optional filter for the request.",
         "location": "query"
        },
        "orderBy": {
         "type": "string",
         "description": "The trace field used to establish the order of traces returned by the ListTraces method. Possible options are: trace_id name (name field of root span) duration (different between end_time and start_time fields of root span) start (start_time field of root span) Descending order can be specified by appending \"desc\" to the sort field: name desc Only one sort field is permitted, though this may change in the future.",
         "location": "query"
        }
       },
       "parameterOrder": [
        "projectId"
       ],
       "response": {
        "$ref": "ListTracesResponse"
       },
       "scopes": [
        "https://www.googleapis.com/auth/cloud-platform"
       ]
      },
      "get": {
       "id": "cloudtrace.projects.traces.get",
       "path": "v1/projects/{projectId}/traces/{traceId}",
       "httpMethod": "GET",
       "description": "Gets one trace by id.",
       "parameters": {
        "projectId": {
         "type": "string",
         "description": "The project id of the trace to return.",
         "required": true,
         "location": "path"
        },
        "traceId": {
         "type": "string",
         "description": "The trace id of the trace to return.",
         "required": true,
         "location": "path"
        }
       },
       "parameterOrder": [
        "projectId",
        "traceId"
       ],
       "response": {
        "$ref": "Trace"
       },
       "scopes": [
        "https://www.googleapis.com/auth/cloud-platform"
       ]
      }
     }
    }
   }
  },
  "v1": {
   "methods": {
    "getDiscovery": {
     "id": "cloudtrace.getDiscovery",
     "path": "v1/discovery",
     "httpMethod": "GET",
     "description": "Returns a discovery document in the specified `format`. The typeurl in the returned google.protobuf.Any value depends on the requested format.",
     "parameters": {
      "format": {
       "type": "string",
       "description": "The format requested for discovery.",
       "location": "query"
      },
      "labels": {
       "type": "string",
       "description": "A list of labels (like visibility) influencing the scope of the requested doc.",
       "repeated": true,
       "location": "query"
      },
      "version": {
       "type": "string",
       "description": "The API version of the requested discovery doc.",
       "location": "query"
      },
      "args": {
       "type": "string",
       "description": "Any additional arguments.",
       "repeated": true,
       "location": "query"
      }
     }
    }
   }
  }
 }
}
