Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split the embed_request json schema #119

Closed
1 task
akolson opened this issue Jan 25, 2024 · 0 comments · Fixed by #120
Closed
1 task

Split the embed_request json schema #119

akolson opened this issue Jan 25, 2024 · 0 comments · Fixed by #120
Assignees

Comments

@akolson
Copy link
Member

akolson commented Jan 25, 2024

Overview

Based on #117, an embed schema was designed to validate inputs received by our /embed api. However the splitting of the embed api to /embed-topics and /embed-content requires a split in the embed schema too.

Description and outcomes

The current schema has both topics and resources fields. The goal is to split it into two as detailed below;

  • Create a new schema named schema-embed_topics_request.json in the spec folder
    • It should validate the topics field only
    • Add validation to prevent empty topics list inputs
  • Create a new schema named schema-embed_content_request.json in the spec folder. Alternatively you could rename the current schema
    • It should validate the resources field only
    • Add validation to prevent empty resources list inputs
  • The metadata field should remain in both files for logging purposes
  • Run make build to regenerate the relevant schema files
  • Update/add relevant validators in l/e_utils/validators
  • Check that the files have been generated

Resources

Accessibility Requirements

NA

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 a pull request may close this issue.

1 participant