StateVoicesNational / Spoke_Hackathon_Fork

mass-contact text/SMS distribution tool
Other
3 stars 2 forks source link

Shortcode Conversations #2

Open Arique1104 opened 1 year ago

Arique1104 commented 1 year ago

Resource created by Karim and Megan assignees to this ticket.

Miro Board Resource

Karim Megan

mabrownnyu commented 1 year ago

What we're going to implement on this issue is the back end API call to check for the short code and get it + a front end check short code button

It will then put the shortcode in the phone numbers table

After that, we will need to implement some switching

Arique1104 commented 1 year ago

Hey @mabrownnyu and @KarimAl-Rashdan, it sounds like there are two tickets here, and I just want to document that correctly.

for MVP, we need an API call from Spoke that goes to Twilio to check if they have access to shortcode.

The second phase is to allow a Spoke Administrator to make the above API call.

The separate ticket is to allow for switching between a short-code and a phone number. If that sounds good, I can create another issue and put it in our backlog.

Arique1104 commented 1 year ago

Here's the ticket for switching. https://github.com/StateVoicesNational/Spoke/issues/5

Arique1104 commented 1 year ago

Recovery Moment UI Moment

From Spoke for Administrators:

Arique1104 commented 1 year ago
mabrownnyu commented 1 year ago

got a function going in the twilio index file called getShortCode -- need to test it to make sure it's actually processing the number correctly

also need to take a look at what the payload looks like if the account has no shortcode

mabrownnyu commented 1 year ago

also github won't let me open another branch? @Arique1104

Arique1104 commented 1 year ago

Tomorrow:

Arique1104 commented 1 year ago

What's new

Priorities for tomorrow:

mabrownnyu commented 1 year ago

I think I've figured out the route of things:

containers/AdminPhoneNumberInventory.js mutations/buyPhoneNumbers.js extensions/job-runners/legacy.js (this is loaded from extensions/job-runners/index.js) workers/job-processes.js workers/jobs.js extensions/service-vendors/fakeservice/index.js (which e should switch to Twilio to get this to actually work, but it looks like this is an environment variable thing)

Arique1104 commented 1 year ago

Today:

KarimAl-Rashdan commented 1 year ago

We needed to add the getShortCodes function to the api/schema.js file

mabrownnyu commented 1 year ago

breadcrumbs

currently things are mostly connected but there is an error happening in processServiceManagers in mutations/getShortCodes.js that is not returning the correct Twilio object

KarimAl-Rashdan commented 1 year ago

Recap of what we learned:

KarimAl-Rashdan commented 1 year ago

Update: I have updated the layout and styling of the Buy phone numbers button and Check short codes button. The shortcodes branch has been updated to reflect these changes.

Pain points: I need to update the getShortCode function in src/extensions/service-vendors/twilio/index.js at line 779 to have a conditional where if shortcodes are nonexistent I can render a message to let the user know on the frontend. I am receiving a lot of errors in my browser console when I click the check short codes button; my guess is I probably don't have the right permissions. @mabrownnyu Can we sit down and figure out this getShortCode function?

Arique1104 commented 1 year ago
Arique1104 commented 1 year ago

After much deliberation this engineering team has decided that the Toll-Free and the Short-code are similar but seperate issue tickets. Updating this one to reflect short-code, which is complete - pending QA. There will be a linked issue for the creation of Toll-Free.