{"id":36645806,"url":"https://github.com/gregtuc/shopify-scraper","last_synced_at":"2026-01-12T10:00:15.970Z","repository":{"id":269852236,"uuid":"908654458","full_name":"gregtuc/shopify-scraper","owner":"gregtuc","description":null,"archived":false,"fork":false,"pushed_at":"2024-12-26T16:26:18.000Z","size":15,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-12-26T17:18:10.389Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","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/gregtuc.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":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-26T15:58:54.000Z","updated_at":"2024-12-26T16:34:07.000Z","dependencies_parsed_at":"2024-12-26T17:18:16.127Z","dependency_job_id":"3800fcbc-d92c-4e33-bfd0-c6c67222c016","html_url":"https://github.com/gregtuc/shopify-scraper","commit_stats":null,"previous_names":["gregtuc/shopify-scraper"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gregtuc/shopify-scraper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gregtuc%2Fshopify-scraper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gregtuc%2Fshopify-scraper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gregtuc%2Fshopify-scraper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gregtuc%2Fshopify-scraper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gregtuc","download_url":"https://codeload.github.com/gregtuc/shopify-scraper/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gregtuc%2Fshopify-scraper/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28337866,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T06:09:07.588Z","status":"ssl_error","status_checked_at":"2026-01-12T06:05:18.301Z","response_time":98,"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":[],"created_at":"2026-01-12T10:00:15.066Z","updated_at":"2026-01-12T10:00:15.919Z","avatar_url":"https://github.com/gregtuc.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# shopify-scraper\n\nA powerful Go library for scraping Shopify stores by leveraging their client-side APIs. This library provides a clean, efficient way to fetch product data, collections, and more from any Shopify store without requiring API keys or authentication.\n\n## Features\n\n- 🚀 **Zero Authentication Required**: Works with any Shopify store's public endpoints\n- 📦 **Comprehensive Data**: Full product details, variants, images, collections, and more\n- 🔄 **Automatic Pagination**: Handles stores with any number of products\n- 🔍 **Search Support**: Use the store's native search functionality\n- 📑 **Collection Support**: Browse and fetch products by collection\n- 🛡️ **Rate Limiting**: Built-in delays to be respectful to servers\n- 🎯 **Type Safety**: Full Go types for all Shopify data structures\n- 🔧 **Configurable**: Customize timeouts, page sizes, and user agents\n\n## Installation\n\n```bash\ngo get github.com/gtucker/shopify-scraper\n```\n\n## Quick Start\n\n```go\npackage main\n\nimport (\n    \"fmt\"\n    \"github.com/gtucker/shopify-scraper\"\n)\n\nfunc main() {\n    // Create a new client\n    client := shopify.NewClient()\n    \n    // Get products from a Shopify store\n    products, err := client.GetProducts(\"allbirds.com\")\n    if err != nil {\n        panic(err)\n    }\n    \n    // Print product details\n    for _, product := range products {\n        fmt.Printf(\"Product: %s\\n\", product.Title)\n        if len(product.Variants) \u003e 0 {\n            fmt.Printf(\"Price: %s\\n\", product.Variants[0].Price)\n        }\n    }\n}\n```\n\n## Advanced Usage\n\n### Client Configuration\n\n```go\nclient := shopify.NewClient(\n    shopify.WithTimeout(10 * time.Second),\n    shopify.WithPageSize(50),\n    shopify.WithUserAgent(\"Custom User Agent\"),\n)\n```\n\n### Fetching Collections\n\n```go\ncollections, err := client.GetCollections(\"allbirds.com\")\nif err != nil {\n    panic(err)\n}\n\nfor _, collection := range collections {\n    fmt.Printf(\"Collection: %s\\n\", collection.Title)\n    \n    // Get products in this collection\n    products, err := client.GetCollectionProducts(\"allbirds.com\", collection.Handle)\n    if err != nil {\n        panic(err)\n    }\n    fmt.Printf(\"Found %d products in collection\\n\", len(products))\n}\n```\n\n### Searching Products\n\n```go\nproducts, err := client.SearchProducts(\"allbirds.com\", \"wool runners\")\nif err != nil {\n    panic(err)\n}\nfmt.Printf(\"Found %d matching products\\n\", len(products))\n```\n\n### Getting Single Product\n\n```go\nproduct, err := client.GetProduct(\"allbirds.com\", \"mens-wool-runners\")\nif err != nil {\n    panic(err)\n}\nfmt.Printf(\"Product: %s\\n\", product.Title)\n```\n\n## Available Methods\n\n- `GetProducts(domain string) ([]Product, error)`\n- `GetProduct(domain, handle string) (*Product, error)`\n- `GetCollections(domain string) ([]Collection, error)`\n- `GetCollectionProducts(domain, collectionHandle string) ([]Product, error)`\n- `SearchProducts(domain, query string) ([]Product, error)`\n\n## Data Models\n\n### Product\n```go\ntype Product struct {\n    ID          int64\n    Title       string\n    Handle      string\n    Description string\n    Vendor      string\n    ProductType string\n    Tags        []string\n    Variants    []Variant\n    Images      []Image\n    Options     []Option\n    // ... and more\n}\n```\n\n### Variant\n```go\ntype Variant struct {\n    ID                int64\n    Title            string\n    Price            string\n    SKU              string\n    CompareAtPrice   string\n    InventoryQuantity int\n    // ... and more\n}\n```\n\nSee [models.go](models.go) for complete type definitions.\n\n## Best Practices\n\n1. **Rate Limiting**: The library includes a built-in 100ms delay between requests. Adjust the page size for your needs.\n2. **Error Handling**: Always check error returns. The library provides detailed error messages.\n3. **Domain Format**: Domains can be provided with or without protocol/www (e.g., \"store.com\" or \"https://www.store.com\").\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n## License\n\nMIT License - See LICENSE file for details\n\n## Acknowledgments\n\nThis library is designed to be respectful to Shopify stores by:\n- Using the same endpoints as their web frontend\n- Including reasonable delays between requests\n- Properly identifying itself with user agents\n- Not attempting to bypass any rate limiting","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgregtuc%2Fshopify-scraper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgregtuc%2Fshopify-scraper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgregtuc%2Fshopify-scraper/lists"}