Assign a Meal Plan Template to a User

Use the setMealPlanToTemplate mutation to assign a meal plan template created to a user.

The meal plan template assigned to a user does not affect the goals and the restrictions configured for that specific user.

It is required to use only the Authorization: Token <api-token> to execute this query.

Required Arguments

Argument Name

Type

Description

profileID

ID

Unique user profile ID to which the template will be assigned.

templateId

ID

Unique template ID. Get this information by executing the mealPlanTemplates query

Available Fields

The following field will be part of the response.

Field name

Type

Description

success

Boolean

True if the meal plan template has been created. Otherwise, it displays False

message

String

Description of the result

Example

mutation {
  setMealPlanToTemplate(
    templateId: "TWVhbFBsYW5UZW1wbGF0ZTo3NzA0MmNkOS1kNjJjLTRhNjYtOWM2ZS00YTkyYmZiMDUzZjA="
    profileId: "UHJvZmlsZTo3MzliNmExOC1lMjJjLTRiNTktYWZhZC00NTE1NTYxZGM4NDA="
  ) {
    success
    message
  }
}

Last updated