All URIs are relative to https://connect.squareup.com
Method | HTTP request | Description |
---|---|---|
ListEmployees | GET /v2/employees | ListEmployees |
RetrieveEmployee | GET /v2/employees/{id} | RetrieveEmployee |
ListEmployeesResponse ListEmployees (string locationId = null, string status = null, int? limit = null, string cursor = null)
ListEmployees
using System;
using System.Diagnostics;
using Square.Connect.Api;
using Square.Connect.Client;
using Square.Connect.Model;
namespace Example
{
public class ListEmployeesExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new EmployeesApi();
var locationId = locationId_example; // string | Filter employees returned to only those that are associated with the specified location. (optional)
var status = status_example; // string | Specifies the EmployeeStatus to filter the employee by. (optional)
var limit = 56; // int? | The number of employees to be returned on each page. (optional)
var cursor = cursor_example; // string | The token required to retrieve the specified page of results. (optional)
try
{
// ListEmployees
ListEmployeesResponse result = apiInstance.ListEmployees(locationId, status, limit, cursor);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling EmployeesApi.ListEmployees: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
locationId | string | Filter employees returned to only those that are associated with the specified location. | [optional] |
status | string | Specifies the EmployeeStatus to filter the employee by. | [optional] |
limit | int? | The number of employees to be returned on each page. | [optional] |
cursor | string | The token required to retrieve the specified page of results. | [optional] |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RetrieveEmployeeResponse RetrieveEmployee (string id)
RetrieveEmployee
using System;
using System.Diagnostics;
using Square.Connect.Api;
using Square.Connect.Client;
using Square.Connect.Model;
namespace Example
{
public class RetrieveEmployeeExample
{
public void main()
{
// Configure OAuth2 access token for authorization: oauth2
Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new EmployeesApi();
var id = id_example; // string | UUID for the employee that was requested.
try
{
// RetrieveEmployee
RetrieveEmployeeResponse result = apiInstance.RetrieveEmployee(id);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling EmployeesApi.RetrieveEmployee: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
id | string | UUID for the employee that was requested. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]