Skip to content

Conversation

@sitole
Copy link
Member

@sitole sitole commented Jan 5, 2026

We want to add separated template that accepts only template alias (not
id) and transparently shows difference between 404 (you are owner and
template does not exists) and 403 (you are not owner but template
exists).


Note

Adds a dedicated endpoint to resolve templates by alias and wires it through the server interface and router.

  • New GET /templates/aliases/{alias} route with GetTemplatesAliasesAlias handler and middleware in api.gen.go
  • Router registration for /templates/aliases/:alias
  • Makefile generate now also produces internal/api/client.gen.go

Written by Cursor Bugbot for commit 8fc7c16. This will update automatically on new commits. Configure here.

sitole added 2 commits January 5, 2026 17:57
We want to add separated template that accepts only template alias (not
id) and transparently shows difference between 404 (you are owner and
template does not exists) and 403 (you are not owner but template
exists).

This way we can use this endpoint in services to check if alias is
available. We cannot do that with existing endpoints as they are
returning 404 for both forbidden and not found cases.
sitole added 3 commits January 5, 2026 18:05
Use test containers so we can run API service and test everything end to
end with Postgres database running in container. This way we can run
debugger and test all cases locally.
@sitole

This comment was marked as outdated.

sitole added 2 commits January 6, 2026 11:08
Moved onetime used functions for tema and template creation to database
test utils package. This way they can be re-used.
Replace local copy of test helper utils with database package utils
implementation.
@sitole sitole marked this pull request as ready for review January 6, 2026 10:19
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 75c1e41ced

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@sitole sitole enabled auto-merge (squash) January 7, 2026 15:02
@sitole sitole merged commit 67f5193 into main Jan 7, 2026
28 checks passed
@sitole sitole deleted the chore/check-template-exists branch January 7, 2026 15:06
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.

3 participants