Skip to main content
POST
Report dependency licenses from uploaded files

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-GitHits-Client-Name
string

Optional client attribution: trimmed printable ASCII, at most 80 bytes. Invalid optional values are dropped.

X-GitHits-Client-Version
string

Optional client-version attribution: trimmed printable ASCII, at most 80 bytes. Invalid optional values are dropped.

X-GitHits-Agent
string

Optional agent attribution: trimmed printable ASCII, at most 160 bytes. Invalid optional values are dropped.

X-GitHits-Session-ID
string

Optional caller-defined session ID: one to 64 ASCII letters, digits, underscores or hyphens, preserved exactly. Supply the header at most once. Invalid supplied IDs return 400 INVALID_SESSION_ID; no session is created.

Required string length: 1 - 64
Pattern: ^[A-Za-z0-9_-]{1,64}$

Body

multipart/form-data

Send a multipart upload. The complete request, including multipart headers and boundaries, must fit within 8,000,000 bytes.

files[]
file[]
required

Repeat the literal field name files[] once per file, with raw UTF-8 file contents rather than base64. Set each part's filename to the file's path relative to a common repository root, for example app/package.json and app/package-lock.json. Preserve directory structure so manifests can be associated with their lockfiles.

Send 1–256 files, each at most 5,242,880 bytes. Each filename must be at most 1,024 UTF-8 bytes and must be relative, with no empty, dot (.) or parent (..) path segments, backslashes or control characters. Every file must be a supported, readable manifest or lockfile; one unusable file rejects the entire upload.

Required array length: 1 - 256 elements

Response

JSON license report, at most 16,777,216 bytes. Read inventory coverage and component evidence together; a successful response may be partial and does not provide a pass/fail decision.

JSON license inventory with separate license choices, publisher statements and source-file observations, plus input attribution and coverage. It provides evidence for your own evaluation rather than an allow/deny result. Additional fields can appear.

components
object[]
required

All reported occurrences in their original order, with the selected primary project/source entry first when one exists. Keep repeated names, versions and package URLs separate; use bom_ref and input-path properties for attribution.

inventory
object
required

Input provenance, inventory coverage and reported dependency relationships. Read these facts alongside the component list; successful analysis can still be partial.

schema_version
enum<integer>
required

Version of this JSON report structure, currently 1.

Available options:
1