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

Implement POST /contract route (artists only) #11

Closed
gcarvellas opened this issue Feb 7, 2023 · 1 comment · Fixed by #23
Closed

Implement POST /contract route (artists only) #11

gcarvellas opened this issue Feb 7, 2023 · 1 comment · Fixed by #23
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@gcarvellas
Copy link
Contributor

gcarvellas commented Feb 7, 2023

Depends on #2 (currently in a pull request)
Part of #4

About this issue:

We are creating a POST route called /contract, where this route will accept a request body, parse the body, validate the body, and send it to the docusign contract generator.

CODE STUB:

In the branch 11-implement-createcontract-route-for-artists linked with this issue, there is a file /backend/create_contract.py. Write your code there.

How to Call Docusign Contract Generator:

In backend/docusign/test_contract.py, the function Docusign.create_contract returns a contract id if created successfully. Otherwise, returns an exception

Request Fields:

  • contractType: String (For this issue, the only accepted value should be "artist")
  • month: String
  • helperBadgeQt: Integer (Number of helper badges needed)
  • additionalChairsQt: Integer (Number of additional chairs needed)
  • artistNumber: Integer (artist's phone number)
  • helper1Number: Integer (helper's phone number)
  • shortenedYear: Integer (shortened format of the year. Ex: if the year is 2022, this value will be 22.)
  • day: Integer (day of the month)
  • signerName: String (Name of the signer)
  • signerEmail: String (Email of the signer)
  • approverName: String (Name of the approver)
  • approverEmail: String (Email of the approver)

Response Field:

Status Code 200

{
     contractId: {ENTER CONTRACT ID HERE}
}

Status Code 500

{
     error: {ENTER EXCEPTION MESSAGE OR CUSTOM ERROR MESSAGE}
}

Status Code 400

{
     error: {ENTER EXCEPTION MESSAGE OR CUSTOM ERROR MESSAGE}
}
@gcarvellas gcarvellas added enhancement New feature or request good first issue Good for newcomers labels Feb 7, 2023
@gcarvellas gcarvellas changed the title Implement /createContract route for artists Implement POST /contract route (artists only) Feb 9, 2023
@Dedicated-RAM Dedicated-RAM self-assigned this Mar 8, 2023
@gcarvellas
Copy link
Contributor Author

What's left in this issue:

  1. Verify that all inputs are passed in properly
  2. Verify that our inputs are aligned with the docusign envelope inputs
  3. Test actually making a post route and verifying that it works with docusign.

@gcarvellas gcarvellas self-assigned this Jul 18, 2023
@gcarvellas gcarvellas linked a pull request Jul 19, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants