-
Notifications
You must be signed in to change notification settings - Fork 28
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
Backend Service Api #170
Backend Service Api #170
Conversation
…ractusx_tutorial-resources into backend-service-api-issue-128
|
GitGuardian id | Secret | Commit | Filename | |
---|---|---|---|---|
- | Generic High Entropy Secret | a9dfd70 | mxd/backend-service/postman/mxd-backend-services.postman_collection.json | View secret |
- | Generic High Entropy Secret | 555d62b | mxd/backend-service/postman/backend-services.postman_collection.json | View secret |
🛠 Guidelines to remediate hardcoded secrets
- Understand the implications of revoking this secret by investigating where it is used in your code.
- Replace and store your secrets safely. Learn here the best practices.
- Revoke and rotate these secrets.
- If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.
To avoid such incidents in the future consider
- following these best practices for managing and storing secrets including API keys and other credentials
- install secret detection on pre-commit to catch secret before it leaves your machine and ease remediation.
🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.
Our GitHub checks need improvements? Share your feedbacks!
Description
Please describe your PR:
Created a http backend service to validate the transfer.
Link for issue : #128
Here's a step-by-step Explanation of created a REST API application to complete and validate a successful asset transfer:
Create a Content Storage API:
POST API /api/v1/contents:
{{backend-service-url}}/api/v1/content/
Endpoint to store assets.
Accepts asset data in the request body.
Persists the asset data and returns a URL or ID in the response.
GET API /api/v1/contents/{id}:
{{backend-service-url}}/api/v1/content/1
Endpoint to fetch content by ID.
Takes the content ID as a path parameter.
Returns the stored content associated with the given ID.
Create a Transfer API:
POST API /api/v1/transfers:
{{backend-service-url}}/api/v1/transfer/
Endpoint to accept transfer data from the connector.
Expects a JSON payload similar to:
{
"id": "",
"endpoint": "http://alice-tractusx-connector-dataplane:8081/api/public",
"authKey": "Authorization",
"authCode": "",
"properties": {}
}
Persists the transfer data with the transfer ID.
GET API /api/v1/transfers/{id}:
{{backend-service-url}}/api/v1/transfer/52ba4b2f-ae3a-46ae-96f2-6781aa819386/
Endpoint to retrieve transfer data by ID.
Takes the transfer ID as a path parameter.
Returns the JSON data pushed by the connector for the specified transfer.
GET API /api/v1/transfers/{id}/contents:
{{backend-service-url}}/api/v1/transfer/52ba4b2f-ae3a-46ae-96f2-6781aa819386/contents/
Endpoint to retrieve the actual assets content.
Uses the stored endpoint URL from the transfer data to fetch content.
Returns the content fetched from the specified endpoint.
GET API /api/v1/content/random
{{backend-service-url}}/api/v1/content/random
Return the Sample Random Generated JSON
Does it add a new feature? yes
Is it enhancing documentation : yes
It has the postman collections inside postman folder inside backend-service folder.
Pre-review checks
Please ensure to do as many of the following checks as possible, before asking for committer review: