{"id":22312227,"url":"https://github.com/ajejoseph22/probable-system","last_synced_at":"2026-04-08T23:34:41.164Z","repository":{"id":51973337,"uuid":"352784136","full_name":"ajejoseph22/probable-system","owner":"ajejoseph22","description":"MP FullStack Engineer assessment","archived":false,"fork":false,"pushed_at":"2021-04-23T22:10:22.000Z","size":280,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-23T08:53:17.051Z","etag":null,"topics":["nodejs","reactjs","sql","typescript"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ajejoseph22.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-03-29T21:03:20.000Z","updated_at":"2022-08-13T00:41:13.000Z","dependencies_parsed_at":"2022-09-15T03:43:12.352Z","dependency_job_id":null,"html_url":"https://github.com/ajejoseph22/probable-system","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ajejoseph22/probable-system","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajejoseph22%2Fprobable-system","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajejoseph22%2Fprobable-system/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajejoseph22%2Fprobable-system/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajejoseph22%2Fprobable-system/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ajejoseph22","download_url":"https://codeload.github.com/ajejoseph22/probable-system/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ajejoseph22%2Fprobable-system/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31579056,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T14:31:17.711Z","status":"ssl_error","status_checked_at":"2026-04-08T14:31:17.202Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nodejs","reactjs","sql","typescript"],"created_at":"2024-12-03T21:35:48.238Z","updated_at":"2026-04-08T23:34:41.127Z","avatar_url":"https://github.com/ajejoseph22.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cp\u003e\n    \u003cimg src=\"assets/logo_black.svg\" width=\"250\" /\u003e\n  \u003c/p\u003e\n  \u003cp\u003e\n    The new standard for fiat to crypto\n  \u003c/p\u003e\n\u003c/div\u003e\n\n# Takehome Test (Full-Stack)\n\n## Overview\n\nThis is a takehome test for candidates applying for a full-stack developer\nposition at MoonPay. It contains four sections: \"Frontend\", \"Backend\", \"Databases\" and \"Follow-up\" which\ntogether include a series of tests involving HTML, CSS, JavaScript, Node.js and SQL.\n\nFeel free to solve these questions however you see fit, using whatever coding\nstyle or third-party libraries you think are appropriate.\n\nTo start the test, simply clone this repo and make your edits locally.\n\n## Frontend\n\nFor the frontend portion of the test, use the `/frontend` folder. There are 7 features we'd like to add:\n\n1. Fetch and display the list of currencies available on MoonPay (see endpoint below).\n2. Add CSS to create a responsive layout that will display one column on mobile\n   devices, two columns on tablet devices, and three columns on desktops.\n3. Add a toggle to control if currencies not supported in the US should be displayed.\n4. Add a toggle to control if currencies not available in test mode should be displayed.\n5. Add a button to sort the list of currencies by alphabetical order using the name of the currencies.\n6. Add a button to sort the list of currencies by alphabetical order using the symbol/code of the currencies.\n7. Add a button to apply a random shuffle to the list of currencies when it is clicked.\n\nFeel free to structure the code however you prefer and use third-party libraries at your discretion.\n\n### API Information\n\n- **MoonPay API `GET /v3/currencies` endpoint:** https://api.moonpay.io/v3/currencies\n\n## Backend\n\nFor the backend portion of the test, use the `/backend` folder. We'd like to write some code that achieves the following:\n\n1. Create a JSON API (REST or GraphQL) using Node.js which will return which cryptocurrency exchange we should use to buy a given amount of Bitcoin to minimise the amount of USD or USDT we'll spend on this trade.\n\nExample API call (for 1 BTC):\n\n```\ncurl http://localhost:4000/exchange-routing?amount=1\n```\n\nExample API response (if Coinbase price of \\$10,000 / BTC is the cheapest):\n\n```\n{\n  \"btcAmount\": 1,\n  \"usdAmount\": 10000,\n  \"exchange\": \"coinbase\"\n}\n```\n\n2. You'll need to compare Binance and Coinbase Prime order books and compute the best execution price for the given amount of Bitcoin we want to buy. (You can assume that 1 USDT = 1 USD at all time.)\n3. [Bonus] Add a third exchange to compare with Binance and Coinbase Prime.\n\nFeel free to structure the code however you prefer and use third-party libraries at your discretion.\n\n### API Information \u0026 Documentation\n\n- **Crypto Trading 101: How to Read an Exchange Order Book:** https://www.coindesk.com/crypto-trading-101-how-to-read-an-exchange-order-book\n- **Binance API Documentation:** https://github.com/binance-exchange/binance-official-api-docs/blob/master/rest-api.md\n- **Coinbase Prime API Documentation:** https://docs.prime.coinbase.com/\n\n_Note that both APIs above are public and don't require any authentication._\n\n## Databases\n\nFor the databases portion of the test, use the `/databases` folder.\n\nLet's say you have two SQL tables: `users` and `transactions`.\n\nThe `users` dataset has 1M+ rows; here are the first three:\n| id | email | country |\n|--------|------------------|---------|\n| user_1 | user1@moonpay.io | FRA |\n| user_2 | user2@moonpay.io | GBR |\n| user_3 | user3@moonpay.io | USA |\n\nThe `transactions` dataset has 1M+ rows; here are the first three:\n| id | quote_currency | usd_amount | user_id |\n|---------------|----------------|------------|---------|\n| transaction_1 | btc | 100 | user_3 |\n| transaction_2 | btc | 2000 | user_2 |\n| transaction_3 | eth | 50 | user_1 |\n\n1. Create a SQL query that shows the TOP 3 customers who spent the most.\n2. Write an SQL query to find out how many users spent more than $1,000 but less than $2,000.\n3. Print every country where the average lifetime spending per user is lower than \\$500.\n\n## Follow-up\n\nAnswer the questions in the [FOLLOW-UP.md](./FOLLOW-UP.md) file.\n\n## Submitting Your Code\n\nOnce you've completed the test, please compress your files (via zip or tar) and\nreturn them as a link or email attachment in reply to your test invite. We'd like the\ncode in your submission to remain private, so please avoid committing or pushing\nthe code publicly.\n\nOnce we receive it, a member of our team will review and we'll get back to you\nas soon as possible.\n\nThanks!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fajejoseph22%2Fprobable-system","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fajejoseph22%2Fprobable-system","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fajejoseph22%2Fprobable-system/lists"}