Retrieve project

curl https://percy.io/api/v1/projects \
  -X GET \
  -H "Authorization: Token ${PERCY_TOKEN}" \
  -d project_slug=project
{
  "data": {
    "type": "projects",
    "id": "2",
    "attributes": {
      "name": "project",
      "slug": "project",
      "full-slug": "josh/project",
      "is-enabled": true,
      "diff-base": "automatic",
      "auto-approve-branch-filter": "master",
      "default-base-branch": "master",
      "updated-at": "2021-06-15T19:20:08.000Z",
      "publicly-readable": false,
      "is-demo": false,
      "is-auto-browser-upgrade": true,
      "diff-sensitivity": 2,
      "wait-for-base-build": false
    }
  },
  "included": [
    {
      "type": "browser-targets",
      "id": "5",
      "attributes": {
        "version-target": "87.0.4280.88.renderer1",
        "deprecation-period-start": null,
        "deprecation-period-end": null
      }
    },
    {
      "type": "browser-targets",
      "id": "7",
      "attributes": {
        "version-target": "73.0",
        "deprecation-period-start": null,
        "deprecation-period-end": null
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    }
  ]
}

Retrieve finished builds for a project

curl https://percy.io/api/v1/builds \
  -X GET \
  -H "Authorization: Token ${PERCY_TOKEN}" \
  -d project_id=2 \
  -d filter[state]=finished
{
  "data": [
    {
      "type": "builds",
      "id": "8",
      "attributes": {
        "branch": "master",
        "build-number": 8,
        "partial": false,
        "web-url": "https://percy.io/organization/project/builds/8",
        "commit-html-url": null,
        "branch-html-url": null,
        "pull-request-html-url": null,
        "state": "finished",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "is-pull-request": false,
        "pull-request-number": null,
        "pull-request-title": null,
        "user-agent": "Percy/v1 @percy/script/1.1.0 percy-agent/0.27.0 percy-js/3.8.0 (puppeteer/3.3.0; node/v14.15.0)",
        "total-snapshots": 1,
        "total-snapshots-requesting-changes": 0,
        "total-snapshots-unreviewed": 0,
        "total-comparisons": 2,
        "total-comparisons-finished": 2,
        "total-comparisons-diff": 2,
        "total-open-comments": 0,
        "failure-reason": null,
        "failure-details": null,
        "parallel-nonce": null,
        "parallel-total-shards": null,
        "finished-at": "2021-06-15T19:20:08.000Z",
        "approved-at": "2021-06-15T19:20:08.000Z",
        "created-at": "2021-06-15T19:19:33.000Z",
        "updated-at": "2021-06-15T19:20:08.000Z"
      },
      "links": {
        "self": "/api/v1/builds/8"
      },
      "relationships": {
        "project": {
          "data": {
            "type": "projects",
            "id": "2"
          }
        },
        "commit": {
          "data": {
            "type": "commits",
            "id": "1"
          }
        },
        "base-build": {
          "data": {
            "type": "builds",
            "id": "7"
          }
        },
        "browsers": {
          "data": [
            {
              "type": "browsers",
              "id": "5"
            },
            {
              "type": "browsers",
              "id": "7"
            }
          ]
        }
      },
      "meta": {
        "finalize-link": "/api/v1/builds/8/finalize",
        "approve-link": "/api/v1/builds/8/approve"
      }
    },
    {
      "type": "builds",
      "id": "7",
      "attributes": {
        "branch": "master",
        "build-number": 7,
        "partial": false,
        "web-url": "https://percy.io/organization/project/builds/7",
        "commit-html-url": null,
        "branch-html-url": null,
        "pull-request-html-url": null,
        "state": "finished",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "is-pull-request": false,
        "pull-request-number": null,
        "pull-request-title": null,
        "user-agent": "Percy/v1 @percy/script/1.1.0 percy-agent/0.27.0 percy-js/3.8.0 (puppeteer/3.3.0; node/v14.15.0)",
        "total-snapshots": 1,
        "total-snapshots-requesting-changes": 0,
        "total-snapshots-unreviewed": 0,
        "total-comparisons": 1,
        "total-comparisons-finished": 1,
        "total-comparisons-diff": 1,
        "total-open-comments": 0,
        "failure-reason": null,
        "failure-details": null,
        "parallel-nonce": null,
        "parallel-total-shards": null,
        "finished-at": "2021-06-15T19:19:02.000Z",
        "approved-at": "2021-06-15T19:19:02.000Z",
        "created-at": "2021-06-15T19:16:29.000Z",
        "updated-at": "2021-06-15T19:19:02.000Z"
      },
      "links": {
        "self": "/api/v1/builds/7"
      },
      "relationships": {
        "project": {
          "data": {
            "type": "projects",
            "id": "2"
          }
        },
        "commit": {
          "data": {
            "type": "commits",
            "id": "1"
          }
        },
        "base-build": {
          "data": null
        },
        "browsers": {
          "data": [
            {
              "type": "browsers",
              "id": "7"
            }
          ]
        }
      },
      "meta": {
        "finalize-link": "/api/v1/builds/7/finalize",
        "approve-link": "/api/v1/builds/7/approve"
      }
    }
  ],
  "included": [
    {
      "type": "projects",
      "id": "2",
      "attributes": {
        "name": "project",
        "slug": "project",
        "full-slug": "organization/project",
        "is-enabled": true,
        "diff-base": "automatic",
        "auto-approve-branch-filter": "master",
        "default-base-branch": "master",
        "updated-at": "2021-06-15T19:20:08.000Z",
        "publicly-readable": false,
        "is-demo": false,
        "is-auto-browser-upgrade": true,
        "diff-sensitivity": 2,
        "wait-for-base-build": false
      },
      "relationships": {
        "organization": {
          "data": {
            "type": "organizations",
            "id": "2"
          }
        },
        "repo": {
          "data": null
        },
        "builds": {
          "links": {
            "related": "/api/v1/builds?project_id=2"
          }
        },
        "browser-targets": {
          "data": [
            {
              "type": "browser-targets",
              "id": "5"
            },
            {
              "type": "browser-targets",
              "id": "7"
            }
          ]
        },
        "project-browser-targets": {
          "data": [
            {
              "type": "project-browser-targets",
              "id": "7"
            },
            {
              "type": "project-browser-targets",
              "id": "4"
            }
          ]
        }
      }
    },
    {
      "type": "commits",
      "id": "1",
      "attributes": {
        "sha": "3efcdf05e6be6469d9c0919aecc094b36949645b",
        "message": "Bump glob-parent from 5.1.1 to 5.1.2 (#14)",
        "author-name": "dependabot[bot]"
      }
    },
    {
      "type": "browsers",
      "id": "5",
      "attributes": {
        "version": "87.0.4280.88.renderer1"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "2"
          }
        }
      }
    },
    {
      "type": "browsers",
      "id": "7",
      "attributes": {
        "version": "73.0"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "1"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    },
    {
      "type": "builds",
      "id": "7",
      "attributes": {
        "branch": "master",
        "build-number": 7,
        "partial": false,
        "web-url": "https://percy.io/organization/project/builds/7",
        "commit-html-url": null,
        "branch-html-url": null,
        "pull-request-html-url": null,
        "state": "finished",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "is-pull-request": false,
        "pull-request-number": null,
        "pull-request-title": null,
        "user-agent": "Percy/v1 @percy/script/1.1.0 percy-agent/0.27.0 percy-js/3.8.0 (puppeteer/3.3.0; node/v14.15.0)",
        "total-snapshots": 1,
        "total-snapshots-requesting-changes": 0,
        "total-snapshots-unreviewed": 0,
        "total-comparisons": 1,
        "total-comparisons-finished": 1,
        "total-comparisons-diff": 1,
        "total-open-comments": 0,
        "failure-reason": null,
        "failure-details": null,
        "parallel-nonce": null,
        "parallel-total-shards": null,
        "finished-at": "2021-06-15T19:19:02.000Z",
        "approved-at": "2021-06-15T19:19:02.000Z",
        "created-at": "2021-06-15T19:16:29.000Z",
        "updated-at": "2021-06-15T19:19:02.000Z"
      },
      "relationships": {
        "project": {
          "links": {
            "self": "/api/v1/builds/7/relationships/project",
            "related": "/api/v1/builds/7/project"
          },
          "data": {
            "type": "projects",
            "id": "2"
          }
        },
        "commit": {
          "data": {
            "type": "commits",
            "id": "1"
          }
        },
        "repo": {
          "data": null
        },
        "base-build": {
          "data": null
        },
        "browsers": {
          "data": [
            {
              "type": "browsers",
              "id": "7"
            }
          ]
        }
      },
      "meta": {
        "finalize-link": "/api/v1/builds/7/finalize",
        "approve-link": "/api/v1/builds/7/approve"
      }
    }
  ]
}

Retrieve snapshots for a build

curl https://percy.io/api/v1/snapshots \
  -X GET \
  -H "Authorization: Token ${PERCY_TOKEN}" \
  -d build_id=8
{
  "data": [
    {
      "type": "snapshots",
      "id": "11",
      "attributes": {
        "name": "TodoMVC with a new todo",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "fingerprint": "5b332a62590a5a0774c675862e151814f8ae2fa5",
        "total-open-comments": 0,
        "is-reintroduced": false,
        "enable-javascript": false
      },
      "links": {
        "self": "/api/v1/snapshots/11"
      },
      "relationships": {
        "build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "screenshots": {},
        "comparisons": {
          "data": [
            {
              "type": "comparisons",
              "id": "65"
            },
            {
              "type": "comparisons",
              "id": "66"
            }
          ]
        }
      }
    }
  ],
  "included": [
    {
      "type": "comparisons",
      "id": "65",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": null
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "6"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": null
        },
        "diff-image": {
          "data": null
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "5"
          }
        }
      }
    },
    {
      "type": "comparisons",
      "id": "66",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": 0.0208968
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "7"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "5"
          }
        },
        "diff-image": {
          "data": {
            "type": "images",
            "id": "15"
          }
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "7"
          }
        }
      }
    },
    {
      "type": "screenshots",
      "id": "6",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "11"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "12"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "11",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/242cc344db06f818476b7356e1f4000600acb3001e43342fe1c8acbd4400c964",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "12",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/9dd46ffba84f711aa305d7d05bd78c2691eddb4eaa02f4338cb21d8cab462bb0",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "browsers",
      "id": "5",
      "attributes": {
        "version": "87.0.4280.88.renderer1"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "2"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "screenshots",
      "id": "7",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "13"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "14"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "13",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/65e9adce369e381e12372fbd9618da8a8f47cc50bb5b6dd77878728336411954",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "14",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/79f6909f46760e34ed67c7bad95e33bc91d6d72737c068d2c86b65a025ccfd03",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "screenshots",
      "id": "5",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "9"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "10"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "9",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/6c3e01f879423f1e3eb7ea14e61573305db3504503b15e9e11db8280812cdad0",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "10",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/20721fae0d3594950d329e59c1df1b74b3d7ebb481d552aef4e43eec154f2993",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "images",
      "id": "15",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/12d85e0791dcbc00a78d696c12dc4d29d3e19196cd6cd2cb842fdd46cd533a76",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "browsers",
      "id": "7",
      "attributes": {
        "version": "73.0"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "1"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    }
  ]
}

Visual Git - Sync

`curl -sL -XPOST
  --data '{"project_id": 4xxx25, "target_branch_filter": "feature-branch"}'
  -H 'Content-Type: application/json'
  -H "Authorization: Token token=$PROJECT_TOKEN"
  https://percy.io/api/v1/branchline/sync`
{
  "data": [
    {
      "type": "snapshots",
      "id": "11",
      "attributes": {
        "name": "TodoMVC with a new todo",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "fingerprint": "5b332a62590a5a0774c675862e151814f8ae2fa5",
        "total-open-comments": 0,
        "is-reintroduced": false,
        "enable-javascript": false
      },
      "links": {
        "self": "/api/v1/snapshots/11"
      },
      "relationships": {
        "build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "screenshots": {},
        "comparisons": {
          "data": [
            {
              "type": "comparisons",
              "id": "65"
            },
            {
              "type": "comparisons",
              "id": "66"
            }
          ]
        }
      }
    }
  ],
  "included": [
    {
      "type": "comparisons",
      "id": "65",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": null
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "6"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": null
        },
        "diff-image": {
          "data": null
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "5"
          }
        }
      }
    },
    {
      "type": "comparisons",
      "id": "66",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": 0.0208968
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "7"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "5"
          }
        },
        "diff-image": {
          "data": {
            "type": "images",
            "id": "15"
          }
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "7"
          }
        }
      }
    },
    {
      "type": "screenshots",
      "id": "6",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "11"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "12"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "11",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/242cc344db06f818476b7356e1f4000600acb3001e43342fe1c8acbd4400c964",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "12",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/9dd46ffba84f711aa305d7d05bd78c2691eddb4eaa02f4338cb21d8cab462bb0",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "browsers",
      "id": "5",
      "attributes": {
        "version": "87.0.4280.88.renderer1"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "2"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "screenshots",
      "id": "7",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "13"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "14"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "13",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/65e9adce369e381e12372fbd9618da8a8f47cc50bb5b6dd77878728336411954",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "14",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/79f6909f46760e34ed67c7bad95e33bc91d6d72737c068d2c86b65a025ccfd03",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "screenshots",
      "id": "5",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "9"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "10"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "9",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/6c3e01f879423f1e3eb7ea14e61573305db3504503b15e9e11db8280812cdad0",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "10",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/20721fae0d3594950d329e59c1df1b74b3d7ebb481d552aef4e43eec154f2993",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "images",
      "id": "15",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/12d85e0791dcbc00a78d696c12dc4d29d3e19196cd6cd2cb842fdd46cd533a76",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "browsers",
      "id": "7",
      "attributes": {
        "version": "73.0"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "1"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    }
  ]
}
`curl -sL -XPOST
  --data '{"project_id": 4xxx25, "target_branch_filter": "feature-branch"}'
  -H 'Content-Type: application/json'
  -H "Authorization: Token token=$PROJECT_TOKEN"
  https://percy.io/api/v1/branchline/sync`
{
  "data": [
    {
      "type": "snapshots",
      "id": "11",
      "attributes": {
        "name": "TodoMVC with a new todo",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "fingerprint": "5b332a62590a5a0774c675862e151814f8ae2fa5",
        "total-open-comments": 0,
        "is-reintroduced": false,
        "enable-javascript": false
      },
      "links": {
        "self": "/api/v1/snapshots/11"
      },
      "relationships": {
        "build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "screenshots": {},
        "comparisons": {
          "data": [
            {
              "type": "comparisons",
              "id": "65"
            },
            {
              "type": "comparisons",
              "id": "66"
            }
          ]
        }
      }
    }
  ],
  "included": [
    {
      "type": "comparisons",
      "id": "65",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": null
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "6"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": null
        },
        "diff-image": {
          "data": null
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "5"
          }
        }
      }
    },
    {
      "type": "comparisons",
      "id": "66",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": 0.0208968
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "7"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "5"
          }
        },
        "diff-image": {
          "data": {
            "type": "images",
            "id": "15"
          }
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "7"
          }
        }
      }
    },
    {
      "type": "screenshots",
      "id": "6",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "11"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "12"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "11",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/242cc344db06f818476b7356e1f4000600acb3001e43342fe1c8acbd4400c964",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "12",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/9dd46ffba84f711aa305d7d05bd78c2691eddb4eaa02f4338cb21d8cab462bb0",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "browsers",
      "id": "5",
      "attributes": {
        "version": "87.0.4280.88.renderer1"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "2"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "screenshots",
      "id": "7",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "13"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "14"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "13",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/65e9adce369e381e12372fbd9618da8a8f47cc50bb5b6dd77878728336411954",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "14",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/79f6909f46760e34ed67c7bad95e33bc91d6d72737c068d2c86b65a025ccfd03",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "screenshots",
      "id": "5",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "9"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "10"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "9",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/6c3e01f879423f1e3eb7ea14e61573305db3504503b15e9e11db8280812cdad0",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "10",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/20721fae0d3594950d329e59c1df1b74b3d7ebb481d552aef4e43eec154f2993",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "images",
      "id": "15",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/12d85e0791dcbc00a78d696c12dc4d29d3e19196cd6cd2cb842fdd46cd533a76",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "browsers",
      "id": "7",
      "attributes": {
        "version": "73.0"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "1"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    }
  ]
}

Visual Git - Merge

`curl -sL -XPOST
  --data '{"project_id": 4xxx25, "target_branch_filter": "feature-branch"}'
  -H 'Content-Type: application/json'
  -H "Authorization: Token token=$PROJECT_TOKEN"
  https://percy.io/api/v1/branchline/sync`
{
  "data": [
    {
      "type": "snapshots",
      "id": "11",
      "attributes": {
        "name": "TodoMVC with a new todo",
        "review-state": "approved",
        "review-state-reason": "auto_approved_branch",
        "fingerprint": "5b332a62590a5a0774c675862e151814f8ae2fa5",
        "total-open-comments": 0,
        "is-reintroduced": false,
        "enable-javascript": false
      },
      "links": {
        "self": "/api/v1/snapshots/11"
      },
      "relationships": {
        "build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "screenshots": {},
        "comparisons": {
          "data": [
            {
              "type": "comparisons",
              "id": "65"
            },
            {
              "type": "comparisons",
              "id": "66"
            }
          ]
        }
      }
    }
  ],
  "included": [
    {
      "type": "comparisons",
      "id": "65",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": null
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "6"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": null
        },
        "diff-image": {
          "data": null
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "5"
          }
        }
      }
    },
    {
      "type": "comparisons",
      "id": "66",
      "attributes": {
        "state": "finished",
        "width": 1200,
        "diff-ratio": 0.0208968
      },
      "relationships": {
        "head-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/11"
          }
        },
        "base-snapshot": {
          "links": {
            "related": "/api/v1/snapshots/10"
          }
        },
        "head-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "7"
          }
        },
        "head-build": {
          "data": {
            "type": "builds",
            "id": "8"
          }
        },
        "base-screenshot": {
          "data": {
            "type": "screenshots",
            "id": "5"
          }
        },
        "diff-image": {
          "data": {
            "type": "images",
            "id": "15"
          }
        },
        "browser": {
          "data": {
            "type": "browsers",
            "id": "7"
          }
        }
      }
    },
    {
      "type": "screenshots",
      "id": "6",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "11"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "12"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "11",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/242cc344db06f818476b7356e1f4000600acb3001e43342fe1c8acbd4400c964",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "12",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/9dd46ffba84f711aa305d7d05bd78c2691eddb4eaa02f4338cb21d8cab462bb0",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "browsers",
      "id": "5",
      "attributes": {
        "version": "87.0.4280.88.renderer1"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "2"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "2",
      "attributes": {
        "name": "Chrome",
        "slug": "chrome"
      }
    },
    {
      "type": "screenshots",
      "id": "7",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "13"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "14"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "13",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/65e9adce369e381e12372fbd9618da8a8f47cc50bb5b6dd77878728336411954",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "14",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/79f6909f46760e34ed67c7bad95e33bc91d6d72737c068d2c86b65a025ccfd03",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "screenshots",
      "id": "5",
      "relationships": {
        "image": {
          "data": {
            "type": "images",
            "id": "9"
          }
        },
        "lossy-image": {
          "data": {
            "type": "images",
            "id": "10"
          }
        }
      }
    },
    {
      "type": "images",
      "id": "9",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/6c3e01f879423f1e3eb7ea14e61573305db3504503b15e9e11db8280812cdad0",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "images",
      "id": "10",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/20721fae0d3594950d329e59c1df1b74b3d7ebb481d552aef4e43eec154f2993",
        "width": 900,
        "height": 768
      }
    },
    {
      "type": "images",
      "id": "15",
      "attributes": {
        "url": "https://storage.googleapis.com/percy-dev-images/12d85e0791dcbc00a78d696c12dc4d29d3e19196cd6cd2cb842fdd46cd533a76",
        "width": 1200,
        "height": 1024
      }
    },
    {
      "type": "browsers",
      "id": "7",
      "attributes": {
        "version": "73.0"
      },
      "relationships": {
        "operating-system": {},
        "browser-family": {
          "data": {
            "type": "browser-families",
            "id": "1"
          }
        }
      }
    },
    {
      "type": "browser-families",
      "id": "1",
      "attributes": {
        "name": "Firefox",
        "slug": "firefox"
      }
    }
  ]
}