api: add first version of export api
This commit is contained in:
committed by
Carl-Gerhard Lindesvärd
parent
7ea95afe16
commit
7f8d857508
@@ -19,5 +19,6 @@
|
||||
},
|
||||
"javascript": "Javascript SDK",
|
||||
"web": "Web SDK",
|
||||
"api": "API"
|
||||
"api": "API",
|
||||
"export": "Export"
|
||||
}
|
||||
|
||||
21
apps/docs/src/pages/docs/export.mdx
Normal file
21
apps/docs/src/pages/docs/export.mdx
Normal file
@@ -0,0 +1,21 @@
|
||||
# Export API
|
||||
|
||||
## Authentication
|
||||
|
||||
To authenticate with the Export API, you need to use your `clientId` and `clientSecret`. Make sure your client has `read` or `root` mode. The default client does not have access to the Export API.
|
||||
|
||||
We expect you to send `openpanel-client-id` and `openpanel-client-secret` headers with your requests.
|
||||
|
||||
## Events
|
||||
|
||||
Get all `screen_view` events from project `abc` between `2024-04-15` and `2024-04-18`.
|
||||
|
||||
```bash
|
||||
curl 'https://api.openpanel.dev/export/events?project_id=abc&event=screen_view&start=2024-04-15&end=2024-04-18' \
|
||||
-H 'openpanel-client-id: CLIENT_ID' \
|
||||
-H 'openpanel-client-secret: CLIENT_SECRET'
|
||||
```
|
||||
|
||||
## Profiles
|
||||
|
||||
During development
|
||||
Reference in New Issue
Block a user