Skip to content

Soontosh/WixFraudTracker

Repository files navigation

Wix Store Fraud Detector

This updated project aims to detect fraudulent activity taking place in the Wix Store. This was made over the course of 1 week by Santosh after a hard pivot from the original project.

Quickstart

  1. Clone this repository onto your computer $ git clone https://github.com/Soontosh/Wix-Tracker.git
  2. Install the necessary packages $ pip install -r requirements.txt
  3. Run the server locally $ python manage.py runserver

Additional Information

This section contains additional information regarding our project.

Tech Stack

We use Django for backend, Railway for deployment, and Railway w/ PostgreSQL for our database. For the Discord bot, which is currently on a seperate repo, we use Discord.py.

Note: Only Santosh currently has access to the Railway db.

Database Information and ERD

Our database is hosted on Railway w/ PostgreSQL. It is currently very simple and subject to change

Tables

Invoice

Contains information regarding all invoices, even those which never went overdue.

  • invoice_number (IntegerField): The invoice tracking number and unique identifier given by Wix(unconfirmed)
  • subscription_id (CharField): Unique subscription ID generated by Wix; Can be used in tandem with Wix API to extract data regarding subscription
  • contact_id (CharField): Contact ID of customer, allows us to get their contact information
  • cycle (IntegerField): The subscription cycle number this invoice corresponds to
  • title (TextField): The title of the invoice
  • issue_date (DateField): Date at which the invoice was issued
  • due_date (DateField): Due date of the invoice
  • total (Float Field): Total cost of the invoice
  • currency (Char Field): Currency in which the invoice is priced
  • preview_link (Text Field): Nullable link to preview the invoice

Email

Contains information regarding all emails sent to customers about overdue invoices.

  • email_id (Auto Field): Automatically generated ID for row, unrelated to Wix
  • invoice (Foreign Key): Foreign Key corresponding to invoice table, sets self to "deleted" on foreign row deletion
  • contact_id (Char Field): Contact ID of customer, allows us to get their contact information
  • recipient_email (Char Field): Email of the recipient
  • email_contents (Text Field): Contents of the email
  • send_date (Date & Time Field): Date and time at which email was sent

ERD

A simple ERD can be found internally. If you do not have access to this, please contact Santosh

How to make changes

To edit the database, edit models.py, then run the following commands.

  1. $ python manage.py makemigrations
  2. $ python manage.py migrate

The changes will immediately be reflected on Railway. You will need to reach out to [email protected] to see if your changes have been reflected on the production database.

About

Made over the course of 1 week for internship

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published