The Nutritional Info From Text API is a natural language processing (NLP) based tool that allows users to extract food information from the text and receive nutritional information such as calories, serving size, sodium, and more. It can be used in food tracking apps, recipe analysis, and other food-related applications.
[{"name": "orange juice", "calories": "Only available for premium subscribers.", "serving_size_g": "Only available for premium subscribers.", "fat_total_g": 0.3, "fat_saturated_g": 0.0, "protein_g": "Only available for premium subscribers.", "sodium_mg": 4, "potassium_mg": 116, "cholesterol_mg": 0, "carbohydrates_total_g": 28.0, "fiber_g": 0.7, "sugar_g": 20.6}]
curl --location --request GET 'https://zylalabs.com/api/934/nutritional+info+from+text+api/752/get+nutrition?query=2 slices of white bread and 3 eggs' --header 'Authorization: Bearer YOUR_API_KEY'
After signing up, every developer is assigned a personal API access key, a unique combination of letters and digits provided to access to our API endpoint. To authenticate with the Nutritional Info from Text API simply include your bearer token in the Authorization header.
| Header | Description |
|---|---|
Authorization
|
Required
Should be Bearer access_key. See "Your API Access Key" above when you are subscribed.
|
No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.
(Save 2 months with annual billing 🎉)
The Nutrition From Text API is a powerful natural language processing (NLP) tool that allows users to extract food information from any text and receive nutritional information such as calories, serving size, sodium, protein, and more. The API uses advanced NLP algorithms to analyze text and identify food items, providing accurate and up-to-date nutritional information.
This API can be integrated into a variety of applications, such as food-tracking apps, recipe analysis, food-related chatbots, and more. For example, in food tracking apps, users can input the foods they've eaten in text format and the API will extract the food name and deliver the nutritional information. In recipe analysis, it can extract food ingredients from recipe text and provide nutritional information for each ingredient.
The API is easy to use and returns data in a JSON format, making it simple to parse and display the information in a user-friendly format. It also supports multiple languages, so you can use it for different regions and cultures.
In summary, the Nutrition From Text API is a valuable tool for anyone in the food industry. It uses natural language processing (NLP) to extract food information from the text and provide accurate and up-to-date nutritional information such as calories, serving size, sodium, and more. It can be integrated into a variety of applications, such as food-tracking apps, recipe analysis, and food-related chatbots. It is easy to use and supports multiple languages.
Pass a meal in text format, the API will recognize the food and the servings and it will deliver calories, serving size, sodium, protein, and more.
Food Tracking Apps: Users can input the foods they've eaten in text format and the API will extract the food name and deliver the nutritional information.
Recipe Analysis: Extract food ingredients from the recipe text and provide nutritional information for each ingredient.
Food-related Chatbots: Chatbots can use the API to extract food information from users' text input and provide nutritional information.
Meal Planning Applications: Extract food information from the user's input and provide nutritional information to assist in meal planning.
Fitness and Health Applications: Extract food information from user's input and provide nutritional information to assist in tracking calorie and nutrient intake.
Food Research and Analysis: Extract food information from food-related articles, reports, and literature to provide nutritional information for food research and analysis.
Besides API call limitations per month, there are no other limitations.
The Get Nutrition endpoint returns detailed nutritional information for food items extracted from the input text. This includes data such as calories, serving size, total fat, saturated fat, protein, sodium, potassium, cholesterol, carbohydrates, fiber, and sugar.
Key fields in the response data include "name" (food item), "calories," "serving_size_g," "fat_total_g," "fat_saturated_g," "protein_g," "sodium_mg," "potassium_mg," "cholesterol_mg," "carbohydrates_total_g," "fiber_g," and "sugar_g."
The response data is organized in a JSON format, where each food item is represented as an object within an array. Each object contains key-value pairs for nutritional attributes, making it easy to parse and utilize in applications.
The Get Nutrition endpoint provides comprehensive nutritional information, including calories, serving sizes, and macronutrient breakdowns (fats, proteins, carbohydrates) for various food items identified in the input text.
Users can customize their data requests by providing specific text inputs that describe the food items they want to analyze. The API will process this text and return relevant nutritional information based on the recognized food items.
The data is sourced from reputable nutritional databases and food composition tables, ensuring that the nutritional information provided is accurate and up-to-date for a wide range of food items.
Typical use cases include food tracking applications where users log meals, recipe analysis for nutritional content, meal planning tools, and fitness applications that track calorie and nutrient intake based on user input.
Users can utilize the returned data by integrating it into their applications to display nutritional information, analyze dietary habits, or assist in meal planning. The structured JSON format allows for easy parsing and presentation in user interfaces.
To obtain your API key, first sign in to your account and navigate to the API you want to use. From the API's Pricing section, choose a plan and complete the subscription process. Once subscribed, return to the API page and you will see your API Access Key displayed at the top of the documentation page. You can use this key to authenticate your requests.
You can’t switch APIs during the free trial. If you subscribe to a different API, your trial will end and the new subscription will start as a paid plan.
The free trial lasts for 7 days and allows you to make up to 50 API requests.
No, the free trial is available only once, so we recommend using it on the API that interests you the most. Most of our APIs offer a free trial, but some may not include this option.
Yes. If the API offers a free trial, you will see a "Free 7-Day Trial" option in its Pricing section. The trial lasts for 7 days and allows up to 50 API requests, enabling you to evaluate the API before subscribing to a paid plan.
Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.
You can monitor your API usage through the response headers included with every request:
x-zyla-api-calls-monthly-used: Shows the total number of API requests you have used during the current billing period.
x-zyla-api-calls-monthly-remaining: Shows the number of API requests you have remaining for the current billing period.
Yes, you can cancel your subscription at any time. Simply go to the Pricing section of the API you're subscribed to and click the "Unsubscribe" button.
Please note that upgrades, downgrades, and cancellations take effect immediately. Once your subscription is canceled, access to the service will end immediately, regardless of any remaining API calls in your quota.
Please have a look at our Refund Policy: https://zylalabs.com/terms#refund