feat: Add validation token endpoint #487
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This pull request makes the following changes:
We are adding a validation token endpoint to support our upcoming validation service.
Task/Issue reference
Closes: #486
Test plan
We have included a temporary commit (be58e61) to show a client request for a token. This temporary commit will be removed before merging this pull request.
Details
We have added
SERVER_VALIDATION_TOKEN_SECRET
andSERVER_VALIDATION_TOKEN_EXPIRATION
solver server options.SERVER_VALIDATION_TOKEN_SECRET
is required and does not have a default value.SERVER_VALIDATION_TOKEN_EXPIRATION
defaults to a one week, but can be configured to another value in seconds.The options can be configured through environment variables or CLI options:
Note that the
SERVER_VALIDATION_TOKEN_SECRET
is overridden by the key we have generated for local development:lilypad/stack
Line 204 in be58e61
Comment this line to test.
Related issues or PRs
Epic: https://www.notion.so/lilypadnetwork/MVP-Validation-176155da99b5801ebeffc417f6b270c7