Skip to content

Validate API configuration requests against the database schema - #71

Merged
9ajia merged 8 commits into
developmentfrom
tokenrequest
Aug 14, 2026
Merged

Validate API configuration requests against the database schema#71
9ajia merged 8 commits into
developmentfrom
tokenrequest

Conversation

@9ajia

@9ajia 9ajia commented Aug 10, 2026

Copy link
Copy Markdown

What changed

  • Added required-field validation for API names, API Gateway IDs and endpoint names.
  • Added the database-backed 16-character limit for API Gateway IDs.
  • Return 404 Not Found when the parent API does not exist.
  • Added tests for missing, blank and over-length values.
  • Confirmed invalid requests are not saved.

Why

Missing values could reach the data-access code and result in a 500 Internal Server Error. The API now rejects invalid requests with an appropriate client response.

The validation follows the existing PostgreSQL schema without introducing unsupported limits for fields stored as text.

Testing

  • 95 automated tests passing.
  • Verified the schema against the running local PostgreSQL database.

@9ajia
9ajia requested review from a team as code owners August 10, 2026 13:27
Comment thread TokenAdministrationApi.Tests/V1/Controllers/TokenAdministrationControllerTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
Comment thread TokenAdministrationApi.Tests/V1/E2ETests/PostApiConfigurationIntegrationTests.cs Outdated
@9ajia
9ajia requested a review from a team August 13, 2026 15:46
@9ajia 9ajia self-assigned this Aug 13, 2026
@9ajia
9ajia merged commit 53cf239 into development Aug 14, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants