{"id":23057641,"url":"https://github.com/chompfoods/sdk-csharp","last_synced_at":"2026-05-06T22:05:15.023Z","repository":{"id":40893833,"uuid":"234637119","full_name":"chompfoods/sdk-csharp","owner":"chompfoods","description":"C# SDK for the Chomp Food \u0026 Recipe Database API. Use our API to get high-quality data on recipes and 875,000+ branded/grocery foods plus raw ingredients.","archived":false,"fork":false,"pushed_at":"2022-12-07T20:31:11.000Z","size":308,"stargazers_count":3,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-03T06:13:32.335Z","etag":null,"topics":["api","branded","chomp","csharp","csharp-sdk","data","database","dll","food","grocery","ingredients","nuget","nutrition","raw","recipes","recipes-api","restsharp","sdk","swagger"],"latest_commit_sha":null,"homepage":"https://chompthis.com/api","language":"C#","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/chompfoods.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":"2020-01-17T21:09:31.000Z","updated_at":"2024-02-06T10:13:00.000Z","dependencies_parsed_at":"2023-01-24T22:01:09.886Z","dependency_job_id":null,"html_url":"https://github.com/chompfoods/sdk-csharp","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/chompfoods/sdk-csharp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chompfoods%2Fsdk-csharp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chompfoods%2Fsdk-csharp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chompfoods%2Fsdk-csharp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chompfoods%2Fsdk-csharp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/chompfoods","download_url":"https://codeload.github.com/chompfoods/sdk-csharp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/chompfoods%2Fsdk-csharp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32713833,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-06T19:35:05.142Z","status":"ssl_error","status_checked_at":"2026-05-06T19:35:03.996Z","response_time":117,"last_error":"SSL_read: 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":["api","branded","chomp","csharp","csharp-sdk","data","database","dll","food","grocery","ingredients","nuget","nutrition","raw","recipes","recipes-api","restsharp","sdk","swagger"],"created_at":"2024-12-16T02:13:12.111Z","updated_at":"2026-05-06T22:05:14.996Z","avatar_url":"https://github.com/chompfoods.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# IO.Swagger - the C# library for the Chomp Food \u0026amp; Recipe Database API Documentation\n\n## Important An **[API key](https://chompthis.com/api/)** is required for access to this API. * Get a **Food Data API** key at **[https://chompthis.com/api](https://chompthis.com/api/)**. * Get a **Recipe Data API** key at **[https://chompthis.com/api/recipes](https://chompthis.com/api/recipes/)**.  ### Getting Started   * Subscribe to the **[Food Data API](https://chompthis.com/api/#pricing)** or the **[Recipe Data API](https://chompthis.com/api/recipes/#pricing)**.   * Scroll down and click the \\\"**Authorize**\\\" button.   * Enter your API key into the \\\"**value**\\\" input, click the \\\"**Authorize**\\\" button, then click the \\\"**Close**\\\" button.   * Scroll down to the section titled \\\"**default**\\\" and click on the API endpoint you wish to use.   * Click the \\\"**Try it out**\\\" button.   * Enter the information the endpoint requires.   * Click the \\\"**Execute**\\\" button.  ### Example    * Branded food response object: **[View example \u0026raquo;](https://raw.githubusercontent.com/chompfoods/examples/master/branded-food-response-object.json)**   * Ingredient response object: **[View example \u0026raquo;](https://raw.githubusercontent.com/chompfoods/examples/master/ingredient-response-object.json)**   * Recipe response object: **[View example \u0026raquo;](https://raw.githubusercontent.com/chompfoods/examples/master/example-recipe-response.json)**   * Error response object: **[View example \u0026raquo;](https://raw.githubusercontent.com/chompfoods/examples/master/error-response-object.json)**  ### How Do I Find My API Key?   * Your API key was sent to the email address you used to create your subscription.   * You will also find your API key in the **[Client Center](https://chompthis.com/api/manage.php)**.   * Read **[this article](https://desk.zoho.com/portal/chompthis/kb/articles/how-do-i-find-my-api-key)** for more information.  ### I'm a Premium subscriber. How do I access the API?   * All Premium subscribers must pass in a unique user ID for each user on their platform that is accessing data from the Chomp API. A user ID can be any string of letters and numbers that you assign to your user. Simply add \\\"user_id\\\" as a URL parameter when calling the API. *You must add a \\\"user_id\\\" URL parameter to every call you make to ANY endpoint.*     * **Example**        \u003e ```ENDPOINT.php?api_key=API_KEY\u0026code=CODE\u0026user_id=USER_ID```  ### Helpful Links   * **Help \u0026 Support**     * [Knowledge Base \u0026raquo;](https://desk.zoho.com/portal/chompthis/kb/chomp)     * [Support \u0026raquo;](https://chompthis.com/api/ticket-new.php)     * [Client Center \u0026raquo;](https://chompthis.com/api/manage.php)   * **Pricing**     * [Food Data API Subscription Options \u0026raquo;](https://chompthis.com/api/)     * [Recipe Data API Subscription Options \u0026raquo;](https://chompthis.com/api/recipes/)     * [Food Data API Cost Calculator \u0026raquo;](https://chompthis.com/api/cost-calculator.php)     * [Recipe Data API Cost Calculator \u0026raquo;](https://chompthis.com/api/recipes/cost-calculator.php)   * **Guidelines**     * [Terms \u0026 License \u0026raquo;](https://chompthis.com/api/terms.php)     * [Attribution \u0026raquo;](https://chompthis.com/api/docs/attribution.php) \n\nThis C# SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:\n\n- API version: 1.0.0-oas3\n- SDK version: 1.0.0\n- Build package: io.swagger.codegen.v3.generators.dotnet.CSharpClientCodegen\n\n\u003ca name=\"frameworks-supported\"\u003e\u003c/a\u003e\n## Frameworks supported\n- .NET 4.0 or later\n- Windows Phone 7.1 (Mango)\n\n\u003ca name=\"dependencies\"\u003e\u003c/a\u003e\n## Dependencies\n- [RestSharp](https://www.nuget.org/packages/RestSharp) - 105.1.0 or later\n- [Json.NET](https://www.nuget.org/packages/Newtonsoft.Json/) - 7.0.0 or later\n- [JsonSubTypes](https://www.nuget.org/packages/JsonSubTypes/) - 1.2.0 or later\n\nThe DLLs included in the package may not be the latest version. We recommend using [NuGet](https://docs.nuget.org/consume/installing-nuget) to obtain the latest version of the packages:\n```\nInstall-Package RestSharp\nInstall-Package Newtonsoft.Json\nInstall-Package JsonSubTypes\n```\n\nNOTE: RestSharp versions greater than 105.1.0 have a bug which causes file uploads to fail. See [RestSharp#742](https://github.com/restsharp/RestSharp/issues/742)\n\n\u003ca name=\"installation\"\u003e\u003c/a\u003e\n## Installation\nRun the following command to generate the DLL\n- [Mac/Linux] `/bin/sh build.sh`\n- [Windows] `build.bat`\n\nThen include the DLL (under the `bin` folder) in the C# project, and use the namespaces:\n```csharp\nusing IO.Swagger.Api;\nusing IO.Swagger.Client;\nusing IO.Swagger.Model;\n```\n\u003ca name=\"packaging\"\u003e\u003c/a\u003e\n## Packaging\n\nA `.nuspec` is included with the project. You can follow the Nuget quickstart to [create](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#create-the-package) and [publish](https://docs.microsoft.com/en-us/nuget/quickstart/create-and-publish-a-package#publish-the-package) packages.\n\nThis `.nuspec` uses placeholders from the `.csproj`, so build the `.csproj` directly:\n\n```\nnuget pack -Build -OutputDirectory out IO.Swagger.csproj\n```\n\nThen, publish to a [local feed](https://docs.microsoft.com/en-us/nuget/hosting-packages/local-feeds) or [other host](https://docs.microsoft.com/en-us/nuget/hosting-packages/overview) and consume the new package via Nuget as usual.\n\n\u003ca name=\"getting-started\"\u003e\u003c/a\u003e\n## Getting Started\n\n```csharp\nusing System;\nusing System.Diagnostics;\nusing IO.Swagger.Api;\nusing IO.Swagger.Client;\nusing IO.Swagger.Model;\n\nnamespace Example\n{\n    public class Example\n    {\n        public void main()\n        {\n            // Configure API key authorization: ApiKeyAuth\n            Configuration.Default.ApiKey.Add(\"api_key\", \"YOUR_API_KEY\");\n            // Uncomment below to setup prefix (e.g. Bearer) for API key, if needed\n            // Configuration.Default.ApiKeyPrefix.Add(\"api_key\", \"Bearer\");\n\n            var apiInstance = new DefaultApi();\n            var code = code_example;  // string | #### UPC/EAN barcode  **Example** \u003e ```\u0026code=0842234000988``` \n            var userId = userId_example;  // string | #### **Only required for Premium subscribers.** The unique identifier assigned to each user on your platform. This can be any string of letters or numbers and doesn't have to relate to your own database. [Learn more](https://desk.zoho.com/portal/chompthis/en/kb/articles/monthly-active-users)  **Example** \u003e ```\u0026user_id=fehef8w4ha```  (optional) \n\n            try\n            {\n                // Get a branded food item using a barcode\n                BrandedFoodObject result = apiInstance.FoodBrandedBarcodePhpGet(code, userId);\n                Debug.WriteLine(result);\n            }\n            catch (Exception e)\n            {\n                Debug.Print(\"Exception when calling DefaultApi.FoodBrandedBarcodePhpGet: \" + e.Message );\n            }\n        }\n    }\n}\n```\n\n\u003ca name=\"documentation-for-api-endpoints\"\u003e\u003c/a\u003e\n## Documentation for API Endpoints\n\nAll URIs are relative to *https://chompthis.com/api/v2*\n\nClass | Method | HTTP request | Description\n------------ | ------------- | ------------- | -------------\n*DefaultApi* | [**FoodBrandedBarcodePhpGet**](docs/DefaultApi.md#foodbrandedbarcodephpget) | **GET** /food/branded/barcode.php | Get a branded food item using a barcode\n*DefaultApi* | [**FoodBrandedNamePhpGet**](docs/DefaultApi.md#foodbrandednamephpget) | **GET** /food/branded/name.php | Get a branded food item by name\n*DefaultApi* | [**FoodBrandedSearchPhpGet**](docs/DefaultApi.md#foodbrandedsearchphpget) | **GET** /food/branded/search.php | Get data for branded food items using various search parameters\n*DefaultApi* | [**FoodIngredientSearchPhpGet**](docs/DefaultApi.md#foodingredientsearchphpget) | **GET** /food/ingredient/search.php | Get raw/generic food ingredient item(s)\n*DefaultApi* | [**RecipeIdPhpGet**](docs/DefaultApi.md#recipeidphpget) | **GET** /recipe/id.php | Get a recipe by ID\n*DefaultApi* | [**RecipeIngredientPhpGet**](docs/DefaultApi.md#recipeingredientphpget) | **GET** /recipe/ingredient.php | Get recipes using a list of ingredients\n*DefaultApi* | [**RecipeRandomPhpGet**](docs/DefaultApi.md#reciperandomphpget) | **GET** /recipe/random.php | Get random popular recipes\n*DefaultApi* | [**RecipeSearchPhpGet**](docs/DefaultApi.md#recipesearchphpget) | **GET** /recipe/search.php | Get recipes using a title and optional filters\n\n\u003ca name=\"documentation-for-models\"\u003e\u003c/a\u003e\n## Documentation for Models\n\n - [Model.BrandedFoodObject](docs/BrandedFoodObject.md)\n - [Model.BrandedFoodObjectCountryDetails](docs/BrandedFoodObjectCountryDetails.md)\n - [Model.BrandedFoodObjectDietFlags](docs/BrandedFoodObjectDietFlags.md)\n - [Model.BrandedFoodObjectDietLabels](docs/BrandedFoodObjectDietLabels.md)\n - [Model.BrandedFoodObjectDietLabelsGlutenFree](docs/BrandedFoodObjectDietLabelsGlutenFree.md)\n - [Model.BrandedFoodObjectDietLabelsVegan](docs/BrandedFoodObjectDietLabelsVegan.md)\n - [Model.BrandedFoodObjectDietLabelsVegetarian](docs/BrandedFoodObjectDietLabelsVegetarian.md)\n - [Model.BrandedFoodObjectItems](docs/BrandedFoodObjectItems.md)\n - [Model.BrandedFoodObjectNutrients](docs/BrandedFoodObjectNutrients.md)\n - [Model.BrandedFoodObjectPackage](docs/BrandedFoodObjectPackage.md)\n - [Model.BrandedFoodObjectPackagingPhotos](docs/BrandedFoodObjectPackagingPhotos.md)\n - [Model.BrandedFoodObjectPackagingPhotosFront](docs/BrandedFoodObjectPackagingPhotosFront.md)\n - [Model.BrandedFoodObjectPackagingPhotosIngredients](docs/BrandedFoodObjectPackagingPhotosIngredients.md)\n - [Model.BrandedFoodObjectPackagingPhotosNutrition](docs/BrandedFoodObjectPackagingPhotosNutrition.md)\n - [Model.BrandedFoodObjectServing](docs/BrandedFoodObjectServing.md)\n - [Model.IngredientObject](docs/IngredientObject.md)\n - [Model.IngredientObjectCalorieConversionFactor](docs/IngredientObjectCalorieConversionFactor.md)\n - [Model.IngredientObjectComponents](docs/IngredientObjectComponents.md)\n - [Model.IngredientObjectItems](docs/IngredientObjectItems.md)\n - [Model.IngredientObjectNutrients](docs/IngredientObjectNutrients.md)\n - [Model.IngredientObjectPortions](docs/IngredientObjectPortions.md)\n - [Model.RecipeObject](docs/RecipeObject.md)\n - [Model.RecipeObjectAttributes](docs/RecipeObjectAttributes.md)\n - [Model.RecipeObjectIngredients](docs/RecipeObjectIngredients.md)\n - [Model.RecipeObjectItems](docs/RecipeObjectItems.md)\n - [Model.RecipeObjectMeta](docs/RecipeObjectMeta.md)\n - [Model.RecipeObjectMetaImages](docs/RecipeObjectMetaImages.md)\n - [Model.RecipeObjectNutrients](docs/RecipeObjectNutrients.md)\n - [Model.RecipeObjectNutrientsCalories](docs/RecipeObjectNutrientsCalories.md)\n\n\u003ca name=\"documentation-for-authorization\"\u003e\u003c/a\u003e\n## Documentation for Authorization\n\n\u003ca name=\"ApiKeyAuth\"\u003e\u003c/a\u003e\n### ApiKeyAuth\n\n- **Type**: API key\n- **API key parameter name**: api_key\n- **Location**: URL query string\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchompfoods%2Fsdk-csharp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchompfoods%2Fsdk-csharp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchompfoods%2Fsdk-csharp/lists"}