Results
Send a report file
Send one JUnit XML or pytest-html 4 report file to a Peeps project, filed under a release, with the file’s bytes as the request body.
PUT
/
api
/
v1
/
projects
/
{project}
/
results
/
{fileName}
curl --fail-with-body -sS -T junit.xml \
-H "Authorization: Bearer $PEEPS_API_KEY" \
"https://app.peepsai.com/api/v1/projects/WEB/results/junit.xml?release=2.0"
{
"uploadId": "8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"project": "WEB",
"release": "2.0",
"file": { "name": "junit.xml", "status": "received" },
"state": "applying",
"statusUrl": "https://app.peepsai.com/api/v1/results/uploads/8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"reportUrl": "https://app.peepsai.com/acme/releases/WEB/2.0"
}
{
"error": {
"code": "release_required",
"message": "This project has no current release. Send ?release=<label> with the file."
}
}
Sends one JUnit XML or pytest-html 4 report. The request body is the file’s bytes. Peeps checks what the file holds, not its name: a file that is neither report is refused with
The whole body must arrive within 120 seconds.
If a release or file name holds a secret value from the project, Peeps masks it in the response.
422, and Peeps stores none of it. A file that passes this check can still be rejected while Peeps processes it: check the upload’s rejectedFiles with Get an upload.
For a walkthrough with curl and Python, retries and limits, see Send results from your harness.
string
required
The project’s acronym, in any case, such as
WEB, or its ID. The project must be a web project whose tests don’t live in a GitHub repository, and the key must be allowed to send to it.string
required
The file’s name, as Peeps shows it: 1 to 255 characters, with no
/, \ or control characters, ending in .xml or .html in any case. URL-encode it.string
The release to file the results under: 1 to 80 letters, digits, spaces and
. _ + - ( ), starting with a letter or digit. URL-encode it: 2.0+build is ?release=2.0%2Bbuild. Leave it out to use the project’s current release.integer
required
The file’s size in bytes, from 1 byte to 50 MiB.
curl -T and Python requests with an open file send it for you.string
Your own name for this request, 1 to 200 printable ASCII characters. Without it, Peeps recognizes a resend for 24 hours by its project, file name, bytes and
release. Reusing it within 24 hours with different request details returns 409 idempotency_mismatch. See Sending again is safe.Response
202 when Peeps stored the file. 200 when Peeps already had this request, or already holds the same file in this project.
string
The upload this file belongs to. Each file you send is its own upload.
string
The project’s acronym.
string
The release this upload is filed under: the one you sent, or the project’s current release. If
file.status is already_in_peeps, the earlier results stay where they were first filed; release and reportUrl don’t point at that earlier filing.object
string
The upload’s state. See Get an upload.
string
The URL to check this upload with.
string
The release page in Peeps. When the release name can’t be put in a link, this is the project’s test cases page instead.
Errors
Sending a file can return any error in the errors table.curl --fail-with-body -sS -T junit.xml \
-H "Authorization: Bearer $PEEPS_API_KEY" \
"https://app.peepsai.com/api/v1/projects/WEB/results/junit.xml?release=2.0"
{
"uploadId": "8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"project": "WEB",
"release": "2.0",
"file": { "name": "junit.xml", "status": "received" },
"state": "applying",
"statusUrl": "https://app.peepsai.com/api/v1/results/uploads/8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"reportUrl": "https://app.peepsai.com/acme/releases/WEB/2.0"
}
{
"error": {
"code": "release_required",
"message": "This project has no current release. Send ?release=<label> with the file."
}
}
⌘I
curl --fail-with-body -sS -T junit.xml \
-H "Authorization: Bearer $PEEPS_API_KEY" \
"https://app.peepsai.com/api/v1/projects/WEB/results/junit.xml?release=2.0"
{
"uploadId": "8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"project": "WEB",
"release": "2.0",
"file": { "name": "junit.xml", "status": "received" },
"state": "applying",
"statusUrl": "https://app.peepsai.com/api/v1/results/uploads/8f0c6a52-3d1e-4f7b-9a4e-2b6f1c0d9e7a",
"reportUrl": "https://app.peepsai.com/acme/releases/WEB/2.0"
}
{
"error": {
"code": "release_required",
"message": "This project has no current release. Send ?release=<label> with the file."
}
}