Gitpod gitpod.v1.InsightsService API
InsightsService provides AI code attribution analytics for projects. The CLI reports per-commit co-author data from git history, and the dashboard reads aggregated stats.
InsightsService provides AI code attribution analytics for projects. The CLI reports per-commit co-author data from git history, and the dashboard reads aggregated stats.
openapi: 3.0.0
info:
title: gitpod.v1 gitpod.v1.AccountService gitpod.v1.InsightsService API
version: v1.0.0
description: "InsightsService provides AI code attribution analytics for projects.\n The CLI reports per-commit co-author data from git history, and the\n dashboard reads aggregated stats."
servers:
- url: https://api.gitpod.io
description: Gitpod API
tags:
- description: "InsightsService provides AI code attribution analytics for projects.\n The CLI reports per-commit co-author data from git history, and the\n dashboard reads aggregated stats."
name: gitpod.v1.InsightsService
x-displayName: gitpod.v1.InsightsService
paths:
/gitpod.v1.InsightsService/DisableProjectInsights:
servers: []
post:
description: "Disables co-author insights for a project. Idempotent.\n Removes the associated workflow (if any) and sets enabled to false."
operationId: gitpod.v1.InsightsService.DisableProjectInsights
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.DisableProjectInsightsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.DisableProjectInsightsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: DisableProjectInsights
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/EnableProjectInsights:
servers: []
post:
description: Enables co-author insights for a project. Idempotent.
operationId: gitpod.v1.InsightsService.EnableProjectInsights
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.EnableProjectInsightsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.EnableProjectInsightsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: EnableProjectInsights
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/GetAgentTraceStats:
servers: []
post:
deprecated: true
description: "Deprecated: Use UsageService.GetAgentTraceSummary and\n UsageService.GetAgentTraceTimeSeries instead."
operationId: gitpod.v1.InsightsService.GetAgentTraceStats
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetAgentTraceStatsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetAgentTraceStatsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: GetAgentTraceStats
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/GetCoAuthorStats:
servers: []
post:
deprecated: true
description: "Deprecated: Use UsageService.GetCoAuthorSummary and\n UsageService.GetCoAuthorTimeSeries instead.\n This will later be removed."
operationId: gitpod.v1.InsightsService.GetCoAuthorStats
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetCoAuthorStatsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetCoAuthorStatsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: GetCoAuthorStats
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/GetInsightsSummary:
servers: []
post:
description: Returns how many projects have insights enabled vs total projects in the org.
operationId: gitpod.v1.InsightsService.GetInsightsSummary
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetInsightsSummaryRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetInsightsSummaryResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: GetInsightsSummary
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/GetPrStatsSummary:
servers: []
post:
deprecated: true
description: "Deprecated: Use UsageService.GetPrSummary and\n UsageService.GetPrTimeSeries instead."
operationId: gitpod.v1.InsightsService.GetPrStatsSummary
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetPrStatsSummaryRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetPrStatsSummaryResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: GetPrStatsSummary
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/GetProjectInsightsStatus:
servers: []
post:
description: Returns whether co-author insights is enabled for a project.
operationId: gitpod.v1.InsightsService.GetProjectInsightsStatus
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetProjectInsightsStatusRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.GetProjectInsightsStatusResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: GetProjectInsightsStatus
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/ReportAgentTrace:
servers: []
post:
description: "Reports an agent trace session for a project environment.\n Stores the raw trace alongside denormalized line-change totals."
operationId: gitpod.v1.InsightsService.ReportAgentTrace
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportAgentTraceRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportAgentTraceResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: ReportAgentTrace
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/ReportCoAuthorStats:
servers: []
post:
description: "Reports co-author analysis results from a project's git history.\n Accepts a batch of per-commit stats. Writes are idempotent: re-reporting\n the same commit (project_id + commit_hash) overwrites the previous row."
operationId: gitpod.v1.InsightsService.ReportCoAuthorStats
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportCoAuthorStatsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportCoAuthorStatsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: ReportCoAuthorStats
tags:
- gitpod.v1.InsightsService
/gitpod.v1.InsightsService/ReportPrStats:
servers: []
post:
description: "Reports PR speed metrics collected from SCM APIs.\n Accepts a batch of per-PR stats. Writes are idempotent: re-reporting\n the same PR (project_id + pr_number) overwrites the previous row."
operationId: gitpod.v1.InsightsService.ReportPrStats
parameters: []
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportPrStatsRequest'
required: true
responses:
'200':
content:
application/json:
schema:
$ref: '#/components/schemas/gitpod.v1.ReportPrStatsResponse'
description: Success
default:
content:
application/json:
schema:
$ref: '#/components/schemas/connect.error'
description: Error
security:
- bearerAuth: []
summary: ReportPrStats
tags:
- gitpod.v1.InsightsService
components:
schemas:
gitpod.v1.AgentTraceTimeBucket:
additionalProperties: false
description: AgentTraceTimeBucket contains stats for a single time period.
properties:
byModel:
description: Per-model breakdown for this bucket.
items:
$ref: '#/components/schemas/gitpod.v1.AgentTraceModelBreakdown'
title: by_model
type: array
startTime:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Start of this time bucket.
title: start_time
totalLinesAdded:
description: Total lines added in this bucket.
title: total_lines_added
type: string
totalLinesRemoved:
description: Total lines removed in this bucket.
title: total_lines_removed
type: string
totalSessions:
description: Number of agent trace sessions in this bucket.
title: total_sessions
type: string
title: AgentTraceTimeBucket
type: object
gitpod.v1.ReportCoAuthorStatsResponse:
additionalProperties: false
properties:
insertedCount:
description: Number of rows inserted (new commits).
title: inserted_count
type: string
updatedCount:
description: Number of rows updated (re-reported commits).
title: updated_count
type: string
title: ReportCoAuthorStatsResponse
type: object
gitpod.v1.ReportAgentTraceRequest:
additionalProperties: false
description: "ReportAgentTraceRequest pushes an agent trace session containing one or more\n trace lines (typically JSONL) for storage."
properties:
agentExecutionId:
description: Agent execution that produced the trace.
format: uuid
title: agent_execution_id
type: string
environmentId:
description: Environment that produced the trace.
format: uuid
title: environment_id
type: string
linesAdded:
description: Total lines added across all edits in the trace session.
title: lines_added
type: string
linesRemoved:
description: Total lines removed across all edits in the trace session.
title: lines_removed
type: string
model:
$ref: '#/components/schemas/gitpod.v1.SupportedModel'
description: The LLM model used during this agent session.
title: model
projectId:
description: Project the trace belongs to.
format: uuid
title: project_id
type: string
traces:
description: "Individual trace lines (typically one JSON object per line).\n May be empty when only line-count aggregates are reported.\n Each line is capped at 5 MiB."
items:
maxLength: 5242880
minLength: 1
type: string
title: traces
type: array
title: ReportAgentTraceRequest
type: object
gitpod.v1.CommitCoAuthorStat:
additionalProperties: false
description: CommitCoAuthorStat represents co-author data for a single commit.
properties:
authorHash:
description: "One-way hash of the author email. Enables distinct author counts\n without storing PII."
maxLength: 128
minLength: 1
title: author_hash
type: string
commitDate:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Author date of the commit.
title: commit_date
commitHash:
description: SHA of the commit. Used with project_id as the idempotency key.
maxLength: 64
minLength: 1
title: commit_hash
type: string
linesAdded:
description: Lines added in this commit.
title: lines_added
type: string
linesRemoved:
description: Lines removed in this commit.
title: lines_removed
type: string
rawCoauthor:
description: "Raw co-author email address from the Co-authored-by trailer.\n Empty when there is no co-author trailer. Stored verbatim so the\n backend can reclassify historical data when new AI tools are added."
maxLength: 320
title: raw_coauthor
type: string
tool:
$ref: '#/components/schemas/gitpod.v1.CoAuthorTool'
description: "Which tool co-authored this commit, NO_COAUTHOR for solo commits,\n or HUMAN_COAUTHOR for human pair-programming.\n UNSPECIFIED is rejected — callers must always set a concrete value."
not:
enum:
- 0
title: tool
required:
- commitDate
title: CommitCoAuthorStat
type: object
gitpod.v1.CoAuthorTimeBucket:
additionalProperties: false
description: CoAuthorTimeBucket contains stats for a single time period.
properties:
aiRatio:
description: Ratio of AI-assisted lines added to total lines added (0.0–1.0).
format: double
title: ai_ratio
type: number
byTool:
description: Per-tool breakdown for this bucket.
items:
$ref: '#/components/schemas/gitpod.v1.ToolBreakdown'
title: by_tool
type: array
distinctAuthors:
description: Number of distinct authors (by author_hash) in this bucket.
title: distinct_authors
type: string
startTime:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Start of this time bucket.
title: start_time
totalCommits:
description: Total number of commits in this bucket (across all tools).
title: total_commits
type: string
totalLinesAdded:
description: Total lines added in this bucket (across all tools).
title: total_lines_added
type: string
totalLinesRemoved:
description: Total lines removed in this bucket (across all tools).
title: total_lines_removed
type: string
title: CoAuthorTimeBucket
type: object
gitpod.v1.ReportAgentTraceResponse:
additionalProperties: false
title: ReportAgentTraceResponse
type: object
gitpod.v1.ReportCoAuthorStatsRequest:
additionalProperties: false
description: ReportCoAuthorStatsRequest is sent by the CLI to push analysis results.
properties:
projectId:
description: Project that was analyzed.
minLength: 1
title: project_id
type: string
stats:
description: Per-commit co-author stats to upsert.
items:
$ref: '#/components/schemas/gitpod.v1.CommitCoAuthorStat'
maxItems: 10000
minItems: 1
title: stats
type: array
title: ReportCoAuthorStatsRequest
type: object
gitpod.v1.GetAgentTraceStatsResponse:
additionalProperties: false
properties:
summary:
$ref: '#/components/schemas/gitpod.v1.AgentTraceSummary'
description: Summary totals for the requested date range.
title: summary
timeSeries:
description: Time series of agent trace stats, bucketed by the requested resolution.
items:
$ref: '#/components/schemas/gitpod.v1.AgentTraceTimeBucket'
title: time_series
type: array
title: GetAgentTraceStatsResponse
type: object
gitpod.v1.GetProjectInsightsStatusResponse:
additionalProperties: false
properties:
enabled:
description: Whether co-author insights is enabled for the project.
title: enabled
type: boolean
lastRanAt:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: "When the insights workflow last completed successfully.\n Nil when enabled is true but no data has been collected yet (pending state)."
title: last_ran_at
title: GetProjectInsightsStatusResponse
type: object
gitpod.v1.PullRequestStat:
additionalProperties: false
description: PullRequestStat represents speed metrics for a single merged pull request.
properties:
authorLogin:
description: Raw SCM username of the PR author (e.g. GitHub user.login, GitLab author.username).
maxLength: 256
minLength: 1
title: author_login
type: string
createdAt:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: When the PR was opened.
title: created_at
firstApprovalAt:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Timestamp of the earliest approving review. Unset when the PR had no approvals.
title: first_approval_at
firstCommitAt:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Author date of the earliest commit on the PR branch.
title: first_commit_at
mergedAt:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: When the PR was merged.
title: merged_at
prNumber:
description: "PR/MR number from the SCM provider. Together with project_id forms the\n idempotency key for upserts."
exclusiveMinimum: true
format: int32
minimum: 0
title: pr_number
type: integer
scmProvider:
$ref: '#/components/schemas/gitpod.v1.ScmProvider'
description: SCM platform the PR was fetched from.
not:
enum:
- 0
title: scm_provider
targetBranch:
description: Branch the PR was merged into (e.g. "main").
maxLength: 256
minLength: 1
title: target_branch
type: string
required:
- createdAt
- mergedAt
- firstCommitAt
title: PullRequestStat
type: object
connect.error:
additionalProperties: true
description: 'Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation'
properties:
code:
description: The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code].
enum:
- canceled
- unknown
- invalid_argument
- deadline_exceeded
- not_found
- already_exists
- permission_denied
- resource_exhausted
- failed_precondition
- aborted
- out_of_range
- unimplemented
- internal
- unavailable
- data_loss
- unauthenticated
example:
- not_found
type: string
message:
description: A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client.
type: string
title: Connect Error
type: object
gitpod.v1.AgentTraceSummary:
additionalProperties: false
description: AgentTraceSummary contains aggregate totals for a date range.
properties:
byModel:
description: Per-model breakdown of session stats.
items:
$ref: '#/components/schemas/gitpod.v1.AgentTraceModelBreakdown'
title: by_model
type: array
totalLinesAdded:
description: Total lines added across all sessions.
title: total_lines_added
type: string
totalLinesAddedTrend:
description: Fractional change in total_lines_added compared to the previous period.
format: double
title: total_lines_added_trend
type: number
totalLinesRemoved:
description: Total lines removed across all sessions.
title: total_lines_removed
type: string
totalLinesRemovedTrend:
description: Fractional change in total_lines_removed compared to the previous period.
format: double
title: total_lines_removed_trend
type: number
totalSessions:
description: Total number of agent trace sessions in the date range.
title: total_sessions
type: string
totalSessionsTrend:
description: "Fractional change in total_sessions compared to the previous period of\n equal length. Computed as (current - previous) / previous. Zero when there\n is no previous data."
format: double
title: total_sessions_trend
type: number
title: AgentTraceSummary
type: object
gitpod.v1.GetPrStatsSummaryResponse:
additionalProperties: false
properties:
deploymentFrequency:
description: 'Deployment frequency: PRs merged to the default branch per week.'
format: double
title: deployment_frequency
type: number
deploymentFrequencyTrend:
description: "Fractional change in deployment_frequency vs previous period.\n Computed as (current - previous) / previous."
format: double
title: deployment_frequency_trend
type: number
leadTimeSeconds:
description: Median lead time for changes in seconds (first commit → merge).
format: double
title: lead_time_seconds
type: number
leadTimeTrend:
description: "Fractional change in lead_time_seconds vs previous period.\n Computed as (current - previous) / previous."
format: double
title: lead_time_trend
type: number
prsMergedCount:
description: Total number of PRs merged in the date range.
title: prs_merged_count
type: string
prsMergedTrend:
description: "Fractional change in prs_merged_count vs previous period.\n Computed as (current - previous) / previous."
format: double
title: prs_merged_trend
type: number
sparkline:
description: "Sparkline data for the card's trend line (typically ~4 weekly points).\n Values represent PRs merged per bucket."
items:
$ref: '#/components/schemas/gitpod.v1.TimeSeriesPoint'
title: sparkline
type: array
timeToFirstApprovalSeconds:
description: "Median time to first approval in seconds (PR opened → first approving review).\n Zero when no PRs in the range had approvals."
format: double
title: time_to_first_approval_seconds
type: number
timeToFirstApprovalTrend:
description: "Fractional change in time_to_first_approval_seconds vs previous period.\n Computed as (current - previous) / previous."
format: double
title: time_to_first_approval_trend
type: number
title: GetPrStatsSummaryResponse
type: object
gitpod.v1.GetCoAuthorStatsResponse:
additionalProperties: false
properties:
summary:
$ref: '#/components/schemas/gitpod.v1.CoAuthorSummary'
description: Summary totals for the requested date range.
title: summary
timeSeries:
description: Time series of contribution stats, bucketed by the requested resolution.
items:
$ref: '#/components/schemas/gitpod.v1.CoAuthorTimeBucket'
title: time_series
type: array
title: GetCoAuthorStatsResponse
type: object
gitpod.v1.ScmProvider:
description: ScmProvider identifies the SCM platform a pull request was fetched from.
enum:
- SCM_PROVIDER_UNSPECIFIED
- SCM_PROVIDER_GITHUB
- SCM_PROVIDER_GITLAB
- SCM_PROVIDER_BITBUCKET
title: ScmProvider
type: string
gitpod.v1.TimeSeriesPoint:
additionalProperties: false
properties:
time:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Timestamp for this data point.
title: time
value:
description: The numerical value for this data point.
format: int32
title: value
type: integer
title: TimeSeriesPoint
type: object
gitpod.v1.ReportPrStatsResponse:
additionalProperties: false
properties:
insertedCount:
description: Number of rows inserted (new PRs).
title: inserted_count
type: string
updatedCount:
description: Number of rows updated (re-reported PRs).
title: updated_count
type: string
title: ReportPrStatsResponse
type: object
gitpod.v1.GetPrStatsSummaryRequest:
additionalProperties: false
description: GetPrStatsSummaryRequest is used by the dashboard to read aggregated PR speed metrics.
properties:
dateRange:
$ref: '#/components/schemas/gitpod.v1.DateRange'
description: Date range to query within. PRs are filtered by merged_at.
title: date_range
projectId:
description: Project to query stats for.
format: uuid
title: project_id
type: string
required:
- dateRange
title: GetPrStatsSummaryRequest
type: object
gitpod.v1.EnableProjectInsightsResponse:
additionalProperties: false
title: EnableProjectInsightsResponse
type: object
gitpod.v1.GetProjectInsightsStatusRequest:
additionalProperties: false
description: GetProjectInsightsStatusRequest checks whether insights is enabled for a project.
properties:
projectId:
description: Project to check.
format: uuid
title: project_id
type: string
title: GetProjectInsightsStatusRequest
type: object
gitpod.v1.DateRange:
additionalProperties: false
description: DateRange specifies a time period for queries.
properties:
endTime:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: End time of the date range (exclusive).
title: end_time
startTime:
$ref: '#/components/schemas/google.protobuf.Timestamp'
description: Start time of the date range (inclusive).
title: start_time
required:
- startTime
- endTime
title: DateRange
type: object
gitpod.v1.ReportPrStatsRequest:
additionalProperties: false
description: ReportPrStatsRequest is sent by the CLI to push PR speed metrics.
properties:
projectId:
description: Project that was analyzed.
format: uuid
title: project_id
type: string
stats:
description: Per-PR stats to upsert.
items:
$ref: '#/components/schemas/gitpod.v1.PullRequestStat'
maxItems: 10000
minItems: 1
title: stats
type: array
title: ReportPrStatsRequest
type: object
gitpod.v1.DisableProjectInsightsRequest:
additionalProperties: false
description: DisableProjectInsightsRequest disables co-author insights for a project.
properties:
projectId:
description: Project to disable insights for.
format: uuid
title: project_id
type: string
title: DisableProjectInsightsRequest
type: object
google.protobuf.Timestamp:
description: "A Timestamp represents a point in time independent of any time zone or local\n calendar, encoded as a count of seconds and fractions of seconds at\n nanosecond resolution. The count is relative to an epoch at UTC midnight on\n January 1, 1970, in the proleptic Gregorian calendar which extends the\n Gregorian calendar backwards to year one.\n\n All minutes are 60 seconds long. Leap seconds are \"smeared\" so that no leap\n second table is needed for interpretation, using a [24-hour linear\n smear](https://developers.google.com/time/smear).\n\n The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By\n restricting to that range, we ensure that we can convert to and from [RFC\n 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings.\n\n # Examples\n\n Example 1: Compute Timestamp from POSIX `time()`.\n\n Timestamp timestamp;\n timestamp.set_seconds(time(NULL));\n timestamp.set_nanos(0);\n\n Example 2: Compute Timestamp from POSIX `gettimeofday()`.\n\n struct timeval tv;\n gettimeofday(&tv, NULL);\n\n Timestamp timestamp;\n timestamp.set_seconds(tv.tv_sec);\n timestamp.set_nanos(tv.tv_usec * 1000);\n\n Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`.\n\n FILETIME ft;\n GetSystemTimeAsFileTime(&ft);\n UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime;\n\n // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z\n // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z.\n Timestamp timestamp;\n timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL));\n timestamp.set_nanos((INT32) ((ticks % 10000000) * 100));\n\n Example 4: Compute Timestamp from Java `System.currentTimeMillis()`.\n\n long millis = System.currentTimeMillis();\n\n Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000)\n .setNanos((int) ((millis % 1000) * 1000000)).build();\n\n Example 5: Compute Timestamp from Java `Instant.now()`.\n\n Instant now = Instant.now();\n\n Timestamp timestamp =\n Timestamp.newBuilder().setSeconds(now.getEpochSecond())\n .setNanos(now.getNano()).build();\n\n Example 6: Compute Timestamp from current time in Python.\n\n timestamp = Timestamp()\n timestamp.GetCurrentTime()\n\n # JSON Mappin
# --- truncated at 32 KB (43 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/gitpod/refs/heads/main/openapi/gitpod-gitpod-v1-insightsservice-api-openapi.yml