Browse docs / Submit a complete code-reference report
Submit a complete code-reference report
POST/api/v1/code-references
Merchant CI uses a dedicated code-references:write Key to atomically submit every current feature, including explicit empty results. Configuration, key set and workflow order must match; missing or failed scans never imply zero references. Retry the same saved report. No source text is uploaded, Feature content changed or archival triggered. Let the CLI generate the current timestamp, commit and scan ID.
API v1Updated
Make the request
Merchant CI uses a dedicated code-references:write Key to atomically submit every current feature, including explicit empty results. Configuration, key set and workflow order must match; missing or failed scans never imply zero references. Retry the same saved report. No source text is uploaded, Feature content changed or archival triggered. Let the CLI generate the current timestamp, commit and scan ID.
Credential
Server API key only. Call from your trusted backend.
Permission
code-references:write
Set the base URL and App ID from SDK setup. These examples use placeholders and do not execute requests. Never put a server key in browser code.
The workflow value for this operation. Its accepted type and constraints are listed above and below.
maxLength: 200
configurationRevisionintegerRequired
The configurationRevision value for this operation. Its accepted type and constraints are listed above and below.
max: 9007199254740991
keySetHashstringRequired
The keySetHash value for this operation. Its accepted type and constraints are listed above and below.
pattern: ^[a-f0-9]{64}$
commitstringRequired
The commit value for this operation. Its accepted type and constraints are listed above and below.
pattern: ^(?:[a-f0-9]{40}|[a-f0-9]{64})$
scanIduuidRequired
The scanId value for this operation. Its accepted type and constraints are listed above and below.
runNumberintegerRequired
The runNumber value for this operation. Its accepted type and constraints are listed above and below.
min: 1 · max: 9007199254740991
runAttemptintegerRequired
The runAttempt value for this operation. Its accepted type and constraints are listed above and below.
min: 1 · max: 10000
scannerVersion"1"Required
The scannerVersion value for this operation. Its accepted type and constraints are listed above and below.
scannedAtdate-timeRequired
The scannedAt value for this operation. Its accepted type and constraints are listed above and below.
coverageobjectRequired
The coverage value for this operation. Its accepted type and constraints are listed above and below.
Show child fields
completetrueRequired
The complete value for this operation. Its accepted type and constraints are listed above and below.
filesintegerRequired
The files value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 10000
sourceBytesintegerRequired
The sourceBytes value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 100000000
unresolvedCallsintegerRequired
The unresolvedCalls value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 1000000
unsupportedFilesintegerRequired
The unsupportedFiles value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 10000
featuresarrayRequired
The features value for this operation. Its accepted type and constraints are listed above and below.
maxItems: 2000
Show child fields
keystringRequired
The key value for this operation. Its accepted type and constraints are listed above and below.
pattern: ^[a-zA-Z0-9_.:|-]{1,256}$
refsarrayRequired
The refs value for this operation. Its accepted type and constraints are listed above and below.
maxItems: 2000
Show child fields
filePathstringRequired
The filePath value for this operation. Its accepted type and constraints are listed above and below.
minLength: 1 · maxLength: 512
startingLineNumberintegerRequired
The startingLineNumber value for this operation. Its accepted type and constraints are listed above and below.
min: 1 · max: 10000000
Response fields
Successful responses include requestId and scope. Use the actual business status or accepted field to determine the result. Optional fields are omitted when unavailable.
HTTP 200 · application/json
requestIduuidRequired
Server-generated HTTP request UUID. Include it when reporting a failed request.
scopeobjectRequired
The App and environment of this response. Headers only verify scope; they cannot switch key scope.
Show child fields
projectIdstringRequired
App ID bound to the credential.
minLength: 1
environmentenumRequired
Separate data scope: sandbox or live.
Show allowed values
"sandbox""live"
receiptobjectRequired
The receipt value for this operation. Its accepted type and constraints are listed above and below.
Show child fields
scanIduuidRequired
The scanId value for this operation. Its accepted type and constraints are listed above and below.
commitstringRequired
The commit value for this operation. Its accepted type and constraints are listed above and below.
receivedAtstringRequired
The receivedAt value for this operation. Its accepted type and constraints are listed above and below.
referencesintegerRequired
The references value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 9007199254740991
removedReferencesintegerRequired
The removedReferences value for this operation. Its accepted type and constraints are listed above and below.
min: 0 · max: 9007199254740991
Handle errors
Common failures
Code
Recovery
UNAUTHENTICATED
Verify the key or refresh the expired customer token once.
FORBIDDEN
Check current key permissions and customer access.
INVALID_REQUEST
Check field types, UUIDs, decimal strings and mutually exclusive fields.
SCOPE_MISMATCH
Use the App and environment bound to the credential.
Common failures
UNAUTHENTICATED
Recovery
Verify the key or refresh the expired customer token once.
FORBIDDEN
Recovery
Check current key permissions and customer access.
INVALID_REQUEST
Recovery
Check field types, UUIDs, decimal strings and mutually exclusive fields.
SCOPE_MISMATCH
Recovery
Use the App and environment bound to the credential.