Create Report Option

posthttps://app.fossa.com/api/report-options

Create a new saved report option for the authenticated user's organization. Requires permission to save report options (ReportOptionAny or TeamReportOptionAny).

Request body (required) · application/json

namestringrequired

Name of the report option (1-80 characters). Must be unique within the organization.

optionsobjectrequired

Configuration options for customizing report generation

sectionsobjectrequired

Controls which sections are included in the report

projectDeclaredLicensesbooleanrequired

Include project declared licenses section

firstPartyLicensesbooleanrequired

Include first party licenses section

licenseListbooleanrequired

Include license list section

directDependenciesbooleanrequired

Include direct dependencies section

deepDependenciesbooleanrequired

Include deep dependencies section

snippetDependenciesbooleanrequired

Include snippet dependencies section

copyrightListbooleanrequired

Include copyright list section

togglesobjectrequired

Feature toggles for report generation

useHashAndVersionDatabooleanrequired

Include hash and version data in the report

excludeFieldsobjectrequired

Fields to exclude from the report

packageLabelsinteger[]required

List of package label IDs to exclude from the report

dependencyDataobjectrequired

Controls which dependency data fields are included

projectsbooleanrequired

For release group reports, show which projects the dependency is present in

authorsbooleanrequired

The authors of the dependency

descriptionbooleanrequired

The description of the dependency

homepagebooleanrequired

The homepage of the dependency

packageManagerbooleanrequired

The package manager of the dependency

downloadUrlbooleanrequired

The download URL of the dependency

concludedLicensesbooleanrequired

The concluded licenses of the dependency

declaredLicensesbooleanrequired

The declared licenses of the dependency

discoveredLicensesbooleanrequired

The discovered licenses of the dependency

copyrightsbooleanrequired

The copyrights of the dependency

licenseUrlbooleanrequired

The license URL of the dependency

licenseFileMatchesbooleanrequired

The list of files that the license was discovered in

issueResolutionNotesbooleanrequired

Issue resolution notes

packageLabelsbooleanrequired

Package labels

dependencyPathsbooleanrequired

The origin paths of the dependency (what files the dependency was defined/found in)

filePathsbooleanrequired

The paths_to of the dependency (the chain of dependencies that brought it into the project)

noticeFilesbooleanrequired

Notice files

fullLicenseTextbooleanrequired

Full license text

Responses

201Report option created successfully
idintegerrequired

Unique identifier for the report option

namestringrequired

Name of the saved report option

organizationIdintegerrequired

ID of the organization that owns this report option

optionsobjectrequired

Configuration options for customizing report generation

sectionsobjectrequired

Controls which sections are included in the report

projectDeclaredLicensesbooleanrequired

Include project declared licenses section

firstPartyLicensesbooleanrequired

Include first party licenses section

licenseListbooleanrequired

Include license list section

directDependenciesbooleanrequired

Include direct dependencies section

deepDependenciesbooleanrequired

Include deep dependencies section

snippetDependenciesbooleanrequired

Include snippet dependencies section

copyrightListbooleanrequired

Include copyright list section

togglesobjectrequired

Feature toggles for report generation

useHashAndVersionDatabooleanrequired

Include hash and version data in the report

excludeFieldsobjectrequired

Fields to exclude from the report

packageLabelsinteger[]required

List of package label IDs to exclude from the report

dependencyDataobjectrequired

Controls which dependency data fields are included

projectsbooleanrequired

For release group reports, show which projects the dependency is present in

authorsbooleanrequired

The authors of the dependency

descriptionbooleanrequired

The description of the dependency

homepagebooleanrequired

The homepage of the dependency

packageManagerbooleanrequired

The package manager of the dependency

downloadUrlbooleanrequired

The download URL of the dependency

concludedLicensesbooleanrequired

The concluded licenses of the dependency

declaredLicensesbooleanrequired

The declared licenses of the dependency

discoveredLicensesbooleanrequired

The discovered licenses of the dependency

copyrightsbooleanrequired

The copyrights of the dependency

licenseUrlbooleanrequired

The license URL of the dependency

licenseFileMatchesbooleanrequired

The list of files that the license was discovered in

issueResolutionNotesbooleanrequired

Issue resolution notes

packageLabelsbooleanrequired

Package labels

dependencyPathsbooleanrequired

The origin paths of the dependency (what files the dependency was defined/found in)

filePathsbooleanrequired

The paths_to of the dependency (the chain of dependencies that brought it into the project)

noticeFilesbooleanrequired

Notice files

fullLicenseTextbooleanrequired

Full license text

createdAtstring <date-time>required

Timestamp when the report option was created

updatedAtstring <date-time>required

Timestamp when the report option was last updated

400Bad Request - Invalid input or duplicate name
uuidstring

Unique identifier associated with the error

codeinteger

fossa specific error code

messagestring

message associated with this error

namestring

name of the error

httpStatusCodeinteger

http status code number

401Unauthorized
uuidstring

Unique identifier associated with the error

codeinteger

fossa specific error code

messagestring

message associated with this error

namestring

name of the error

httpStatusCodeinteger

http status code number

403Forbidden - User lacks permission to save report options
uuidstring

Unique identifier associated with the error

codeinteger

fossa specific error code

messagestring

message associated with this error

namestring

name of the error

httpStatusCodeinteger

http status code number

500Server Error
uuidstring

Unique identifier associated with the error

codeinteger

fossa specific error code

messagestring

message associated with this error

namestring

name of the error

httpStatusCodeinteger

http status code number

Try this endpoint

Build a request and run it against app.fossa.com.

Bearer

Stored in this browser for 24 hours. Try It uses a docs proxy for CORS and does not store tokens server-side.

POST https://app.fossa.com/api/report-options
curl --request POST \  --url 'https://app.fossa.com/api/report-options' \  --header 'accept: application/json' \  --header 'authorization: Bearer YOUR_API_TOKEN' \  --header 'content-type: application/json' \  --data '{  "name": "Standard Report",  "options": {    "sections": {      "projectDeclaredLicenses": true,      "firstPartyLicenses": true,      "licenseList": true,      "directDependencies": true,      "deepDependencies": false,      "snippetDependencies": false,      "copyrightList": true    },    "toggles": {      "useHashAndVersionData": false    },    "excludeFields": {      "packageLabels": []    },    "dependencyData": {      "projects": true,      "authors": false,      "description": true,      "homepage": false,      "packageManager": true,      "downloadUrl": false,      "concludedLicenses": true,      "declaredLicenses": true,      "discoveredLicenses": true,      "copyrights": true,      "licenseUrl": false,      "licenseFileMatches": false,      "issueResolutionNotes": false,      "packageLabels": false,      "dependencyPaths": false,      "filePaths": false,      "noticeFiles": false,      "fullLicenseText": false    }  }}'

Real request. Mutating methods can change data.

Click Try It to run a request and see the response here.
Enter a Bearer token before running this request.
application/json