docs: add connectivity section to version 1
This commit is contained in:
@@ -40,5 +40,17 @@ export const versionOne: DocsStructure = {
|
||||
copy: 'copy.md',
|
||||
example: 'example.md',
|
||||
},
|
||||
{
|
||||
title: 'Resources',
|
||||
folder: 'resources',
|
||||
children: [
|
||||
{
|
||||
title: 'Connectivity',
|
||||
folder: 'connectivity',
|
||||
copy: 'copy.md',
|
||||
example: 'example.md',
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
# Connectivity {% #connectivity %}
|
||||
|
||||
This endpoint allows you to verify that you are able to connect to the Onspring API. When successful, a `204` response will be returned with no body.
|
||||
@@ -0,0 +1,25 @@
|
||||
# Checking for connection to the api
|
||||
|
||||
{% code method="GET" heading="/Ping" defaultLanguage="bash" %}
|
||||
|
||||
```bash
|
||||
curl --location 'https://api.onspring.com/v1/Ping' \
|
||||
--header 'X-ApiKey: 000000ffffff000000ffffff/00000000-ffff-0000-ffff-000000000000'
|
||||
```
|
||||
|
||||
```csharp
|
||||
using Onspring.API.SDK.Helpers;
|
||||
|
||||
var httpHelper = new HttpHelper(
|
||||
config.baseUrl,
|
||||
config.apiKey
|
||||
);
|
||||
|
||||
if (httpHelper.CanConnect())
|
||||
{
|
||||
Console.WriteLine("Connected to Onspring API");
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
{% /code %}
|
||||
Reference in New Issue
Block a user