Full name: projects.locations.endpoints.computeTokens
Return a list of tokens based on the input text.
Endpoint
posthttps://aiplatform.googleapis.com/v1/{endpoint}:computeTokens
Path parameters
endpointstring
Required. The name of the Endpoint requested to get lists of tokens and token ids.
Request body
The request body contains data with the following structure:
Optional. The instances that are the input to token computing API call. Schema is identical to the prediction schema of the text model, even for the non-text models, like chat models, or Codey models.
modelstring
Optional. The name of the publisher model requested to serve the prediction. Format: projects/{project}/locations/{location}/publishers/*/models/*
Optional. Input content.
Response body
If successful, the response body contains an instance of ComputeTokensResponse.