CortexPlus Nutrition API

The Nutrition API from CortexPlus — 2 operation(s) for nutrition.

GitHub OpenAPI

Operations 2

GET /v1/nutrition/history Get nutrient intake history #
GET /v1/nutrition/targets Get recommended daily intake ranges #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/cortexplus-io:cortexplus-io-nutrition-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

cortexplus-io-nutrition-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Cortexplus Io Nutrition API
  version: 1.0.0
  description: 'Operations tagged Nutrition across 2 of this provider''s published API definitions: cortexplus-io-openapi.json, cortexplus-io-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://api.cortexplus.io
security:
- bearerAuth: []
tags:
- name: Nutrition
paths:
  /v1/nutrition/history:
    get:
      operationId: getNutritionHistory
      summary: Get nutrient intake history
      description: Nutrient intake from logged meals, aggregated by day, week or month. Weekly and monthly values are daily averages over days with meals. Health-tagged memories hidden from the credential are excluded.
      x-openai-isConsequential: false
      parameters:
      - name: from
        in: query
        required: true
        description: First local date (inclusive).
        schema:
          type: string
          format: date
      - name: to
        in: query
        required: true
        description: Last local date (inclusive). Up to 366 days for `day`, 1830 for `week`/`month`.
        schema:
          type: string
          format: date
      - name: granularity
        in: query
        description: Bucket size; weeks start on Monday.
        schema:
          type: string
          enum:
          - day
          - week
          - month
          default: day
      - name: timezone
        in: query
        description: IANA time zone; defaults to the account setting.
        schema:
          type: string
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                type: object
                required:
                - from
                - to
                - granularity
                - timezone
                - nutrients
                - buckets
                - summary
                properties:
                  from:
                    type: string
                    format: date
                  to:
                    type: string
                    format: date
                  granularity:
                    type: string
                    enum:
                    - day
                    - week
                    - month
                  timezone:
                    type: string
                  nutrients:
                    type: array
                    items:
                      type: object
                      required:
                      - key
                      - unit
                      properties:
                        key:
                          type: string
                        unit:
                          type: string
                  buckets:
                    type: array
                    items:
                      type: object
                      required:
                      - start
                      - end
                      - days
                      - meals
                      - average
                      - total
                      properties:
                        start:
                          type: string
                          format: date
                        end:
                          type: string
                          format: date
                        days:
                          type: integer
                          description: Days with at least one meal.
                        meals:
                          type: integer
                        average:
                          type: object
                          description: Daily average over days with meals.
                          additionalProperties:
                            type: number
                        total:
                          type: object
                          description: Values keyed by `<nutrient>:<unit>`, e.g. `enerc:kcal`, `procnt:g`, `vitc:mg`.
                          additionalProperties:
                            type: number
                  summary:
                    type: object
                    required:
                    - days
                    - meals
                    - average
                    - total
                    properties:
                      days:
                        type: integer
                        description: Days with at least one meal.
                      meals:
                        type: integer
                      average:
                        type: object
                        description: Daily average over days with meals.
                        additionalProperties:
                          type: number
                      total:
                        type: object
                        description: Values keyed by `<nutrient>:<unit>`, e.g. `enerc:kcal`, `procnt:g`, `vitc:mg`.
                        additionalProperties:
                          type: number
        default:
          description: Request failed.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  field:
                    type: string
                required:
                - error
      tags:
      - Nutrition
    servers:
    - url: https://api.cortexplus.io
  /v1/nutrition/targets:
    get:
      operationId: getNutritionTargets
      summary: Get recommended daily intake ranges
      description: 'Only returned to API keys/agents when the user enabled `settings.healthAgentAccess`; otherwise the response is `{ "error": "health data is not shared with agents" }`. Daily ranges per nutrient from the profile (birth date, sex, activity level), the latest weight/height and the active calorie goal; generic adult references when the profile is incomplete.'
      x-openai-isConsequential: false
      parameters:
      - name: timezone
        in: query
        description: IANA time zone; defaults to the account setting.
        schema:
          type: string
      responses:
        '200':
          description: Successful response.
          content:
            application/json:
              schema:
                type: object
                required:
                - profile
                - basis
                - energyKcal
                - targets
                properties:
                  profile:
                    type: object
                    description: Inputs used (birthDate, age, sex, activityLevel, weightKg, heightCm, calorieGoalKcal), `missing` fields and `supportedAge`.
                    additionalProperties: true
                  basis:
                    type: string
                    enum:
                    - personal
                    - generic
                  energyKcal:
                    type: object
                    required:
                    - value
                    - source
                    properties:
                      value:
                        type: number
                      source:
                        type: string
                        enum:
                        - goal
                        - eer
                        - dv
                      eer:
                        type:
                        - number
                        - 'null'
                  targets:
                    type: array
                    items:
                      type: object
                      required:
                      - key
                      - unit
                      - min
                      - max
                      - target
                      - source
                      properties:
                        key:
                          type: string
                        unit:
                          type: string
                        min:
                          type:
                          - number
                          - 'null'
                        max:
                          type:
                          - number
                          - 'null'
                        target:
                          type:
                          - number
                          - 'null'
                        source:
                          type: string
        default:
          description: Request failed.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                  field:
                    type: string
                required:
                - error
      tags:
      - Nutrition
    servers:
    - url: https://api.cortexplus.io
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
x-refined-from:
- cortexplus-io-openapi.json
- cortexplus-io-openapi.yml