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

api/v1/ for Case Contacts (iOS App) #3942

Open
21 tasks
FireLemons opened this issue Sep 15, 2022 · 38 comments
Open
21 tasks

api/v1/ for Case Contacts (iOS App) #3942

FireLemons opened this issue Sep 15, 2022 · 38 comments
Labels

Comments

@FireLemons
Copy link
Collaborator

FireLemons commented Sep 15, 2022

What type(s) of user does this feature affect?

  • volunteers

Description
A volunteer needs to be able to use the app to save a case contact.

Approach

Authentication

HTTP Route Description Issue(s) Completed
POST /api/v1/users/sign_in Login #4976, #6216
POST /api/v1/users/sign_in/validate Validation
POST /api/v1/users/refresh_token Refresh Access Token
DELETE /api/v1/users/sign_out Log-Out

Case Contact

HTTP Route Description Issue{s) Completed
GET /api/v1/case_contacts List Case Contacts (casa_cases)
GET /api/v1/case_contacts/:id Get Specific Case Contact
POST /api/v1/case_contacts Create new Case Contact
PATCH /api/v1/case_contacts/:id Update Specific Case Contact

For Additional Expenses (they are nested under Case Contacts)

HTTP Route Issue(s) Completed
POST /api/v1/case_contacts/:case_contact_id/additional_expenses
PATCH /api/v1/case_contacts/:case_contact_id/additional_expenses/:id
DELETE /api/v1/case_contacts/:case_contact_id/additional_expenses/:id

Requirements for /api/v1/

  1. Secure Authentication (token based) /api/v1/users/sign_in

    Foundation: iOS app can authenticate on sign_in endpoint Initial API Structure + Auth Route #4976, and below

    Token Refreshing: iOS app generates new access tokens when refresh token is still valid /api/v1/users/refresh_token

    Token Revoking: iOS app can Sign-Out users on sign_out endpoint /api/v1/users/sign_out

  2. Casa Case Endpoint for Signed-In Users /api/v1/casa_cases

    Milestone 1

    • Add authenticate user before_action to controller and validate user is signed-in
    • Signed-In user case contact data is accessible through POST request (only shallow fields meaning fields that don't reference a different table)
    • Make sure user can only see case contacts they have permission to see

    Milestone 2a

    • Can display errors

    Milestone 2b

    • Can accept new case contact and save it
    • Can create case contact drafts

    Milestone 2c (expand case contact data)

    • Add case contact creator to json
    • Add data from casa_case_contact_types to show which contact types are available to be selected for the case contact
    • Add data from case_contact_contact_types to show contact types have been selected on the case contact
    • Add data from contact_topic_answers to show sections of notes for the case contact
    • Add contact topics to show available contact topics to choose from

    Milestone 3a

    • Can update case contact and save it
    • Can update case contact drafts and save it

    Milestone 3b

    • Can delete drafts

We have jBuilder installed. It can help you if your json response is complicated. You can also use it to convert a rails object into json easily like this

Questions? Join Slack!

We highly recommend that you join us in slack https://rubyforgood.herokuapp.com/ #casa channel to ask questions quickly and hear about office hours (currently Tuesday 6-8pm Pacific), stakeholder news, and upcoming new issues.

@FireLemons FireLemons added Help Wanted This is a special label that enables github to showcase issues that want help codethechange for codethechange developers and removed Help Wanted This is a special label that enables github to showcase issues that want help labels Sep 15, 2022
@FireLemons
Copy link
Collaborator Author

When this is almost done we'll probably need to talk to sean about a r4g ios publishing account. https://developer.apple.com/support/membership-fee-waiver/

@github-actions github-actions bot added Hacktoberfest Do good, get swag. Help Wanted This is a special label that enables github to showcase issues that want help Multiple PRs? labels Oct 14, 2022
@dpaola2
Copy link
Collaborator

dpaola2 commented Mar 14, 2023

Is this still a priority?

@github-actions github-actions bot removed the Help Wanted This is a special label that enables github to showcase issues that want help label Mar 14, 2023
@FireLemons
Copy link
Collaborator Author

@dpaola2 A dev team is working on this. Don't worry about it

@dpaola2
Copy link
Collaborator

dpaola2 commented Mar 15, 2023

OK. Should I close? (Which dev team?)

@FireLemons
Copy link
Collaborator Author

No don't close it. It's codethechange

@FireLemons FireLemons removed the Hacktoberfest Do good, get swag. label Mar 15, 2023
@FireLemons FireLemons reopened this Mar 29, 2023
@FireLemons FireLemons moved this from Todo to In Progress in CASA Volunteer Portal Mar 30, 2023
@github-actions
Copy link

This issue has been inactive for 245 hours (10.21 days) and will be unassigned after 115 more hours (4.79 days). If you have questions, please

If you are still working on this, comment here to tell the bot to give you more time

@xihai01
Copy link
Collaborator

xihai01 commented May 2, 2023

This issue has been inactive for 245 hours (10.21 days) and will be unassigned after 115 more hours (4.79 days). If you have questions, please

If you are still working on this, comment here to tell the bot to give you more time

this project is still being worked on. Don't close yet!

@FireLemons
Copy link
Collaborator Author

Maybe if I slap the epic tag on it the bot will ignore it

@github-actions
Copy link

This issue has been inactive for 531 hours (22.13 days) and is past the limit of 360 hours (15.00 days) so is being unassigned.You’ve just been unassigned from this ticket due to inactivity – but feel free to pick it back up (or a new one!) in the future! Thank you again for your contribution to this project.

Copy link

github-actions bot commented Nov 3, 2023

This issue has been inactive for 843 hours (35.13 days) and is past the limit of 360 hours (15.00 days) so is being unassigned.You’ve just been unassigned from this ticket due to inactivity – but feel free to pick it back up (or a new one!) in the future! Thank you again for your contribution to this project.

@xihai01 xihai01 self-assigned this Nov 20, 2023
Copy link

This issue has been inactive for 1275 hours (53.13 days) and is past the limit of 360 hours (15.00 days) so is being unassigned.You’ve just been unassigned from this ticket due to inactivity – but feel free to pick it back up (or a new one!) in the future! Thank you again for your contribution to this project.

Copy link

This issue has been open without changes for a long time! What's up?

Copy link

This issue has been inactive for 11355 hours (473.13 days) and is past the limit of 360 hours (15.00 days) so is being unassigned.You’ve just been unassigned from this ticket due to inactivity – but feel free to pick it back up (or a new one!) in the future! Thank you again for your contribution to this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In Progress
Status: No Prio
Development

No branches or pull requests

5 participants