box / box/box-openapi

Error at 'Query files/folders by metadata'

Open
#552 0 comments 0 reactions 0 assignees View on GitHub
documentation
Dominant language
No language data
Stars
101
Forks
89
Avg merge
30m
Merged PRs (30d)
3

Description

### Description of the issue

In the documentation for "Query files/folders by metadata", the POST method endpoint and the request example use different URLs.

This discrepancy may confuse developers. The POST method's URL is correct, I think.

### Current content

The request example currently shows:

```
curl -i -X POST "https://api.box.com/2.0/files/12345" \
-H "authorization: Bearer " \
-H "content-type: application/json" \
-d '{
"from": "enterprise_123456.contractTemplate",
"query": "amount >= :value",
"query_params": {
"value": 100
},
"fields": [
"name",
"amount"
]
}'
```

### Expected content

The request example should use the correct endpoint:

```
curl -i -X POST "https://api.box.com/2.0/metadata_queries/execute_read" \
-H "authorization: Bearer " \
-H "content-type: application/json" \
-d '{
"from": "enterprise_123456.contractTemplate",
"query": "amount >= :value",
"query_params": {
"value": 100
},
"fields": [
"name",
"amount"
]
}'
```

### Link to the documentation page

https://developer.box.com/reference/post-metadata-queries-execute-read/

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.