DependencyTrack / DependencyTrack/dependency-track

OpenAPI schema missing for `/api/v1/finding/project/{uuid}` response

Open
#2,590 2 comments 0 reactions 0 assignees View on GitHub
api docs api-inconsistency defect good first issue p2 size/S
Dominant language
Java
Stars
4.2k
Forks
811
Avg merge
8h 39m
Merged PRs (30d)
237

Description

### Current Behavior

The returned Component model varies for different REST API endpoints. The `/v1/findings/project/` endpoint returns:
```
[
{
"component": {
"project": , ...
},
...
},
...
]
```
Whereas the components returned by the `/v1/component/project/{uuid}` endpoint contain full project descriptions:
```
[
{
...
"project": {
"name": ...,
"version": ...,
"classifier": ...,
"uuid": "",
...
},
```

### Steps to Reproduce

Query on the `/finding/project` Endpoint:
```
curl -X 'GET' \
'https://dependencytrack.tld/api/v1/finding/project/' \
-H 'accept: application/json'
```

Query on the `/component/project` Endpoint:
```
curl -X 'GET' \
'https://dependencytrack.tld/api/v1/component/project/' \
-H 'accept: application/json'
```

### Expected Behavior

The finding endpoint should return a populated project object.

### Dependency-Track Version

4.7.1

### Dependency-Track Distribution

Container Image

### Database Server

PostgreSQL

### Database Server Version

_No response_

### Browser

N/A

### Checklist

- [X] I have read and understand the [contributing guidelines](https://github.com/DependencyTrack/dependency-track/blob/master/CONTRIBUTING.md#filing-issues)
- [X] I have checked the [existing issues](https://github.com/DependencyTrack/dependency-track/issues) for whether this defect was already reported

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.