Skip to main content
Yosemite CrewDeveloper Docs

Parent Companion API

On this page

Manages the links between parents (pet owners) and companions (the pets, also shown as animal, pet, or patient depending on the clinic's preference): listing links, updating a co-parent's permissions, promoting a co-parent to primary, and removing a co-parent. All routes are called by the mobile app and authenticated with the pet parent's SuperTokens session (requireMobileAuth). See the Parent API for parent records.

Endpoints

GET /parent/:parentId

  • Auth: requireMobileAuth
  • Params: parentId
  • Controller: ParentCompanionController.getLinksForParent
  • Response: 400: keys message, 200: JSON, 500: keys message

GET /companion/:companionId

  • Auth: requireMobileAuth
  • Params: companionId
  • Controller: ParentCompanionController.getLinksForCompanion
  • Response: 400: keys message, 200: JSON, 500: keys message

PATCH /:companionId/:targetParentId/permissions

  • Auth: requireMobileAuth
  • Params: companionId, targetParentId
  • Controller: ParentCompanionController.updatePermissions
  • Response: 401: keys message, 400: keys message, 200: keys message, 500: keys message

POST /:companionId/:targetParentId/promote

  • Auth: requireMobileAuth
  • Params: companionId, targetParentId
  • Controller: ParentCompanionController.promoteToPrimary
  • Response: 401: keys message, 400: keys message, 200: keys message, 500: keys message

DELETE /:companionId/:coParentId

  • Auth: requireMobileAuth
  • Params: companionId, coParentId
  • Controller: ParentCompanionController.removeCoParent
  • Response: 401: keys message, 400: keys message, 204: keys message, 500: keys message