---
title: "List Liked Contractors"
method: GET
path: "/liked-contractors"
tags: ["LikedContractors"]
---

# List Liked Contractors

`GET /liked-contractors`

## Request

- Base URL: `https://api.purplegrain.com/api/v1`
- URL: `https://api.purplegrain.com/api/v1/liked-contractors`
- Auth: HTTP bearer

The caller's liked contractors (most recent first). Pass owner_id/owner_type
to read an organization's list (requires edit rights on the organization).
Pass contractor_id/contractor_type to answer "is this contractor liked?".

## Query parameters

- `owner_id` string
- `owner_type` 'User' | 'Organization'
- `contractor_id` string
- `contractor_type` 'User' | 'Organization'
- `page` integer
- `per_page` integer
- `include` string

## Response `200`

Liked contractors for the requested owner. When the `include` query parameter is used, the response may contain an `included` array (JSON:API) or inlined related resources (application/json).

- LikedContractorsIndexResponseAttributes: List liked contractors response for Accept application/json (attributes adapter).
  - `data` LikedContractorModelAttributes[]
    - `id` string
    - `type` string
    - `created_at` string, date-time
    - `updated_at` string, date-time
    - `owner` object: Present when include=owner
    - `contractor` object: Present when include=contractor
  - `meta` PaginationMeta
    - `current_page` number
    - `next_page` number, nullable
    - `prev_page` number, nullable

## Other responses

- `401`: Unauthorized
- `403`: Forbidden

---

[API](https://skmtc.dev/purplegrain/apis/purple-grain-api.md) · [All operations](https://skmtc.dev/purplegrain/apis/purple-grain-api/llms.txt) · [OpenAPI document](https://skmtc.dev/purplegrain/apis/purple-grain-api/revisions/29c5c990d66e?raw)
