docs: add delete record section to version 1

This commit is contained in:
Stevan Freeborn
2023-04-25 07:43:50 -05:00
parent 46f93c8224
commit e9658b0ac3
6 changed files with 56 additions and 2 deletions
+6
View File
@@ -176,6 +176,12 @@ export const versionOne: DocsStructure = {
copy: 'copy.md',
example: 'example.md',
},
{
title: 'Delete Record',
folder: 'delete_record',
copy: 'copy.md',
example: 'example.md',
},
],
},
{
@@ -4,6 +4,7 @@
```bash
curl --location 'https://api.onspring.com/v1/Records/195' \
--header 'X-ApiKey: 000000ffffff000000ffffff/00000000-ffff-0000-ffff-000000000000' \
--header 'Content-Type: application/json' \
--data '{
"FieldData": {
@@ -0,0 +1,25 @@
# Delete Record {% #delete-record %}
This endpoint allows you to delete a record in an app. If the record deletion is successful a `204` response will be returned with an empty body.
## Path Parameters
{% table %}
- Parameter Name
- Data Type
- Description
---
- appId
- `number`
- The id of the app or survey that contains the record to be deleted.
---
- recordId
- `number`
- The id of the record that will be deleted.
{% /table %}
@@ -0,0 +1,21 @@
# Delete a record in an app
{% code method="DELETE" heading="/Records/{appId}/{recordId}" defaultLanguage="bash" %}
```bash
curl --location --request DELETE 'https://api.onspring.com/v1/Records/195/12' \
--header 'X-ApiKey: 000000ffffff000000ffffff/00000000-ffff-0000-ffff-000000000000'
```
```csharp
using Onspring.API.SDK.Helpers;
var httpHelper = new HttpHelper(
config.baseUrl,
config.apiKey
);
var result = httpHelper.DeleteAppRecord(195, 12);
```
{% /code %}
@@ -14,7 +14,7 @@ This endpoint allows you to update a record in an app. If the record update is s
- appId
- `number`
- The id of the app or survey that the record will be added to.
- The id of the app or survey that contains the record to be updated.
---
@@ -1,9 +1,10 @@
# Add a record in an app
# Update a record in an app
{% code method="PUT" heading="/Records/{appId}/{recordId}" defaultLanguage="bash" %}
```bash
curl --location --request PUT 'https://api.onspring.com/v1/Records/195/12' \
--header 'X-ApiKey: 000000ffffff000000ffffff/00000000-ffff-0000-ffff-000000000000' \
--header 'Content-Type: application/json' \
--data '{
"FieldData": {