POST
/
api
/
parea
/
v1
/
testcases
p = Parea(api_key="PAREA_API_KEY")  # replace with your API key

data = [
    {"problem": "1+2", "target": 3, "tags": ["easy"]},
    {"problem": "Solve the differential equation dy/dx = 3y.", "target": "y = c * e^(3x)", "tags": ["hard"]}
]

# this will add the new test cases to the existing "Math problems" dataset.
# New test cases must have the same columns as the existing dataset.
p.add_test_cases(data, name="Math problems")
[
  123
]
p = Parea(api_key="PAREA_API_KEY")  # replace with your API key

data = [
    {"problem": "1+2", "target": 3, "tags": ["easy"]},
    {"problem": "Solve the differential equation dy/dx = 3y.", "target": "y = c * e^(3x)", "tags": ["hard"]}
]

# this will add the new test cases to the existing "Math problems" dataset.
# New test cases must have the same columns as the existing dataset.
p.add_test_cases(data, name="Math problems")

Authorizations

x-user-id
string
header
required

Body

application/json
test_cases
object[]
required

List of items which should be added to dataset.

id
integer | null

ID for the dataset/test case collection. Either ID or name is required to identify the dataset.

name
string | null

Name for the dataset/test case collection. Either ID or name is required to identify the dataset.

Response

200
application/json
Successful Response

The response is of type integer[].