{"id":22002929,"url":"https://github.com/rssnyder/taco-bell-python","last_synced_at":"2025-05-05T15:45:07.730Z","repository":{"id":55116558,"uuid":"327728392","full_name":"rssnyder/taco-bell-python","owner":"rssnyder","description":"A python sdk for Taco Bell.","archived":false,"fork":false,"pushed_at":"2021-01-08T23:31:52.000Z","size":22,"stargazers_count":4,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-30T22:06:09.318Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rssnyder.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null}},"created_at":"2021-01-07T21:26:14.000Z","updated_at":"2024-10-12T00:43:30.000Z","dependencies_parsed_at":"2022-08-14T12:30:52.486Z","dependency_job_id":null,"html_url":"https://github.com/rssnyder/taco-bell-python","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rssnyder%2Ftaco-bell-python","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rssnyder%2Ftaco-bell-python/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rssnyder%2Ftaco-bell-python/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rssnyder%2Ftaco-bell-python/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rssnyder","download_url":"https://codeload.github.com/rssnyder/taco-bell-python/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252525594,"owners_count":21762330,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":[],"created_at":"2024-11-29T23:42:06.318Z","updated_at":"2025-05-05T15:45:07.701Z","avatar_url":"https://github.com/rssnyder.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Taco Bell Python\n\nA python sdk for Taco Bell.\n\n## Goal\n\nTo be able to order my favorite taco bell items (rip potatoes) via code.\n\n## What Works\n\n1. Logging into Taco Bell account with username/password\n\n2. Adding a single, uncustomized item to your cart\n\n3. Adding a customized item to your cart, either adding extras or modifying what comes by default\n\n4. Getting your cart total cost\n\n5. Find the nearest stores and set store for pickup\n\n## Usage\n\nSign into your Taco Bell account with your username (email) and password:\n```\nfrom tacobell import TacoBell\ntbell = TacoBell('rileysndr@gmail.com', '\u003csuper secure password\u003e')\n```\n\nAdd an item to your cart:\n```\ntbell.add_to_cart('Cheesy Bean and Rice Burrito')\n```\n\nAdd a customized item to your cart:\n```\ntbell.add_to_cart_customized(\n    'Cheesy Bean and Rice Burrito',\n    sauces=[\n        'Red Sauce',\n        'Avocado Ranch'\n    ],\n    addons=[\n        '3 Cheese Blend'\n    ]\n)\n```\n\n```\ntbell.add_to_cart_customized(\n    'Cheesy Bean and Rice Burrito',\n    modify=[\n        ('Creamy Jalapeño Sauce', 'EXTRA')\n    ]\n)\n```\n\nGet your cart total:\n```\ntbell.cart_total()\n```\n\nFind your desired pickup location:\n```\nfor store in tbell.find_store('\u003clatitude\u003e', '\u003clongitude\u003e'):\n    print(store)\n```\n\nSet your pickup location:\n```\ntbell.set_pickup('\u003cstore id\u003e')\n```\n\n## Current problems/issues\n\nI am accomplishing this by exporling the network calls made on the Taco Bell site. I will publish the API endpoints I have found and how to use them.\n\nIt seems like logging in and doing actions is hit or miss. I am unsure if this is some sort of anti-robot protections taco bell has or they are just blocking my IP every once and a while.\n\nThere is no great way to list items, so for now I am building a relationship of item names -\u003e product codes. Hopefull this can be replaced by a search function later.\n\n\n## Known API Endpoints\n\n### Root URL: `https://www.tacobell.com`\n\n### Login: POST `/j_spring_security_check`\nData:\n```\n{\n    \"j_username\": \u003cusername\u003e,\n    \"j_password\": \u003cpassword\u003e,\n    \"CSRFToken\": \u003cCSRF Token\u003e\n}\n```\n\n### Cart Total: GET `/cart/miniCart/SUBTOTAL`\nAlways returns 200 status code\n\n### Add uncustomized item to cart: POST `/cart/add`\nParams:\n```\n{\n    \"productCodePost\": \u003cproduct code\u003e,\n    \"CSRFToken\": \u003cCSRF Token\u003e\n}\n```\n\n### Get options for item customization: GET `/p/\u003cproduct code\u003e/customizationOverlay?store=\u003cstore id (optional)\u003e`\nExample return data in `tests/customizations.json`\n\n### Add customized item to cart: POST `/cart/add-composite`\nData:\n```\n{\n    \"baseProduct\": \u003cproduct code\u003e,\n    \"code\": \u003cproduct code\u003e,\n    \"qty\": \u003cquantity\u003e,\n    \"includeProduct\": [\n        {\n            \"code\": \u003cmodifier code\u003e,\n            \"group\": \"included\",\n            \"qty\": 1\n        }\n    ],\n    \"modifierProduct\": [\n        {\n            \"code\": \u003cmodifier code\u003e,\n            \"group\": \u003cmodifier type\u003e,\n            \"qty\": 1\n        }\n    ]\n}\n```\n\n### Find Stores: GET `/store-finder/findStores`\nParams:\n```\n{\n    \"latitude\": \u003clatitude\u003e,\n    \"longitude\": \u003clongitude\u003e\n}\n```\n\n### Set Pickup Store: POST `/pickup-location/pickupLocation`\nParams:\n```\n{\n    \"storeName\": \u003cstore id\u003e,\n    \"CSRFToken\": \u003cCSRF Token\u003e\n}\n```\n\nFor these, you can change the items that come on the product normall with the `includeProduct` list. You can then add extra items with the `modifierProduct` list.\n\nGet modification options: `p/\u003cproduct_code\u003e/customizationOverlay?store=\u003cstore_id\u003e`\nThe return data here is a huge JSON with all your options, the meat of the code is taking your modification input and finding the correct modifier code for what you want.\n\n\n## Contributing\n\nContributions are obviously welcome. Exporing the backend Taco Bell API is most of the work. Until we can get a good source for product codes I will be putting them in the code by hand.\n\nThings on the ToDo list:\n\n1. Query for list of products and codes\n\n2. Select/Find store to send order to\n\n3. Select payment method\n\n4. Checkout/Submit order\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frssnyder%2Ftaco-bell-python","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frssnyder%2Ftaco-bell-python","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frssnyder%2Ftaco-bell-python/lists"}