Skip to content

Metrics

Artifacts exposes analytics that let you inspect repo activity, errors, and operation duration across your account.

Artifacts metrics are available through Cloudflare's GraphQL Analytics API. You can use them to answer questions like which repos are busiest, where errors cluster, and how long operations take.

Metrics

Artifacts currently exports the artifactsEventsAdaptiveGroups GraphQL dataset.

MetricGraphQL fieldDescription
OperationscountTotal number of Artifacts events that match the query filter. This includes successful actions and errors.
Total durationsum.durationMsTotal time spent handling matching Artifacts operations, in milliseconds.
Average durationavg.durationMsAverage time per matching operation, in milliseconds.
Duration p25quantiles.durationMsP2525th percentile operation duration, in milliseconds.
Duration p50quantiles.durationMsP50Median operation duration, in milliseconds.
Duration p75quantiles.durationMsP7575th percentile operation duration, in milliseconds.
Duration p90quantiles.durationMsP9090th percentile operation duration, in milliseconds.
Duration p95quantiles.durationMsP9595th percentile operation duration, in milliseconds.
Duration p99quantiles.durationMsP9999th percentile operation duration, in milliseconds.
Duration p999quantiles.durationMsP99999.9th percentile operation duration, in milliseconds.

Metrics can be queried for the past 31 days. Queries require an accountTag filter with your Cloudflare account ID.

Dimensions

Use these dimensions to filter or group results:

DimensionDescription
repositoryFully qualified repo path in the form namespace/name.
repositoryNamespaceNamespace that contains the repo.
repositoryNameRepo name inside the namespace.
eventKindTop-level event category. Use action for successful operations and error for failures.
eventTypeSpecific operation or error type.
errorMessageError message for failed operations.
dateCalendar date of the event.
datetimeExact event timestamp.
datetimeMinuteEvent time truncated to the minute.
datetimeFiveMinutesEvent time truncated to five-minute windows.
datetimeFifteenMinutesEvent time truncated to fifteen-minute windows.
datetimeHourEvent time truncated to the hour.
datetimeSixHoursEvent time truncated to six-hour windows.

Event types

Artifacts currently emits these values in eventType:

Event typeKindDescription
createactionA repo was created.
forkactionA repo was forked.
pushactionA client pushed data to a repo.
pullactionA client fetched or cloned data from a repo.
deleteactionA repo was deleted.
storageLimitReachederrorAn operation hit a storage limit condition.
serverErrorerrorThe service failed while handling the request.
clientErrorerrorThe client sent an invalid or unsupported request.
rateLimitederrorThe request was rejected by a rate limiter.

Example GraphQL queries

You can query Artifacts analytics with the GraphQL Analytics API. All examples on this page use the artifactsEventsAdaptiveGroups dataset.

Operations by repo within a namespace

Use this query to find the busiest repos in one namespace over a time range. It also returns average operation duration so you can compare activity and latency together.

query ArtifactsOperationsByRepo(
$accountTag: String!
$datetimeStart: Time
$datetimeEnd: Time
$repositoryNamespace: String!
) {
viewer {
accounts(filter: { accountTag: $accountTag }) {
artifactsEventsAdaptiveGroups(
limit: 100
filter: {
datetime_geq: $datetimeStart
datetime_leq: $datetimeEnd
repositoryNamespace: $repositoryNamespace
eventKind: "action"
}
orderBy: [count_DESC]
) {
count
avg {
durationMs
}
dimensions {
repositoryName
}
}
}
}
}

Errors by repo, descending

Use this query to rank repos by error volume. It helps you spot which repos fail most often and which error types are driving those failures.

query ArtifactsErrorsByRepo(
$accountTag: String!
$datetimeStart: Time
$datetimeEnd: Time
) {
viewer {
accounts(filter: { accountTag: $accountTag }) {
artifactsEventsAdaptiveGroups(
limit: 100
filter: {
datetime_geq: $datetimeStart
datetime_leq: $datetimeEnd
eventKind: "error"
}
orderBy: [count_DESC]
) {
count
dimensions {
repository
eventType
}
}
}
}
}

Repos by pushes, descending

Use this query to see which repos receive the most pushes in a time window. It is useful for identifying active write-heavy repos across an account.

query ArtifactsPushesByRepo(
$accountTag: String!
$datetimeStart: Time
$datetimeEnd: Time
) {
viewer {
accounts(filter: { accountTag: $accountTag }) {
artifactsEventsAdaptiveGroups(
limit: 100
filter: {
datetime_geq: $datetimeStart
datetime_leq: $datetimeEnd
eventKind: "action"
eventType: "push"
}
orderBy: [count_DESC]
) {
count
dimensions {
repository
}
}
}
}
}