# Proof API

Provides access to the proof that is part of a Hyperproof organization.

Version: 1.0

## Servers

Hyperproof US
```
https://api.hyperproof.app/v1/proof
```

Hyperproof EU
```
https://api.hyperproof.eu/v1/proof
```

Hyperproof Gov
```
https://api.hyperproofgov.app/v1/proof
```

## Security

### oauth2

Type: oauth2

## Download OpenAPI description

[Proof API](https://developer.hyperproof.app/_bundle/hyperproof-api/proof/proof.openapi.yaml)

## Other

### Get Proof Metadata Collection

 - [GET /](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/get-proof-metadata-collection.md): GET /

#### Description

Retrieves metadata for a specified organization, control, label, or task, providing key contextual and configuration details.

### Add Proof

 - [POST /](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/add-proof.md): POST /

#### Description

Adds a new proof item to an organization, storing evidence details, file attachments, and metadata for compliance tracking.

Uploading Testable CSV proof

When sending CSV files, you need to explicitly declare the type as text/csv. This tells Hyperproof to treat the uploaded blob as tabular data. This allows the CSV proof to be usable in automated tests.

bash
curl --request POST \
  --url https://api.hyperproof.app/v1/proof \
  --header "Authorization: Bearer $ACCESS_TOKEN" \
  --form proof=@"./policies/AcceptableUse.csv:type=text/csv" \
  --form hp-proof-owned-by="$USER_ID"
  --form contentType="text/csv"

### Get Proof Metadata

 - [GET /{proofId}](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/get-proof-metadata.md): GET {proofId}

#### Description

Retrieves metadata for a specific proof item in an organization by its ID, including details such as source, status, and associated objects.

### Update Proof

 - [PATCH /{proofId}](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/update-proof.md): PATCH /{proofId}

#### Description

Updates an existing proof file identified by its ID, allowing modification to whether it is private. Also allows adding the schema file for proof uploaded in CSV format to make that file compatible with the automated testing feature.

Updating Testable CSV proof

After uploading a CSV file intended for automated testing, a PATCH request should be made to create the schema to be tested.
The body of the request will define the CSV fields and types for the automated testing feature. Available types include text , number , boolean , and date.

bash
curl --request PATCH 'https://api.hyperproof.app/v1/proof/:proofid' \
--header 'Content-Type: application/json' \
--header 'Authorization: ••••••' \
--data '{
    "isPrivate": false,
    "schema": {
        "class": "CsvFileSchema",
        "fields": [{
            "name": "Name",
            "type": "text"
        }, {
            "name": "Email",
            "type": "text"
        }]
    }
}'

### Add Proof Version

 - [POST /{proofId}/versions](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/add-proof-version.md): POST /{proofId}/versions

#### Description

Creates a new version of an existing proof item, capturing updated evidence details, files, or metadata.

### Gets the contents of a proof.

 - [GET /{proofId}/contents](https://developer.hyperproof.app/hyperproof-api/proof/proof.openapi/other/get-proof-contents.md): GET /{proofId}/contents

#### Description

Retrieves the content of a proof item as a downloadable file, providing access to the original evidence data.

