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

feat: Email subscription for certain keywords or item type #33

Open
NwinNwin opened this issue May 23, 2024 · 0 comments
Open

feat: Email subscription for certain keywords or item type #33

NwinNwin opened this issue May 23, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@NwinNwin
Copy link
Member

NwinNwin commented May 23, 2024

Proposed Solution:

To do:

POST /items:

  • Incoming data:

    • name,
    • description,
    • type
  • Process Data:

    • Set of keywords = {name + description + type}
  • Search Data:

    • Search through to return all array of emails the keywords that match keyword in set
    • Return [[Emails], [emails]]
  • Returning Data:

    • Combine arrays → {Emails} - set of arrays
  • Send emails:

    • Use AWS_SES sendEmail()

POST /searches (Adding keywords)

  • Incoming data:

    • Keywords
    • Email
  • Store in DB:

    • In Searches table:
      • Look up keyword, add email to array if keyword exist:
      • If email already in keyword, ignore
      • If keyword not in table, add keyword + add email to new array

DELETE /searches (removing keywords):

  • Incoming data:

    • Keywords
    • Email
  • Remove from DB:

    • In Searches table:
      • Look up keyword, if it exists, look for the corresponding email and remove it from the array
      • If keyword not in table ⇒ do nothing

GET /searches/:email

  • Incoming data:

    • email
  • Search in DB:

    • In Searches table:
      • For each keyword, for each array in keyword, if email in array:
      • Return Keyword
    • Store all the returned keywords in an array
    • Return array of keywords
@NwinNwin NwinNwin changed the title Feature: Email subscription for certain keywords or item type feat: Email subscription for certain keywords or item type Jan 13, 2025
@NwinNwin NwinNwin added the enhancement New feature or request label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

2 participants