All URIs are relative to https://api.merge.dev/api/hris/v1
Method | HTTP request | Description |
---|---|---|
CompaniesList | GET /companies | |
CompaniesRetrieve | GET /companies/{id} |
PaginatedCompanyList CompaniesList (string xAccountToken, DateTime? createdAfter = null, DateTime? createdBefore = null, string cursor = null, bool? includeDeletedData = null, bool? includeRemoteData = null, DateTime? modifiedAfter = null, DateTime? modifiedBefore = null, int? pageSize = null, string remoteId = null)
Returns a list of Company
objects.
using System.Collections.Generic;
using System.Diagnostics;
using Merge.HRISClient.Api;
using Merge.HRISClient.Client;
using Merge.HRISClient.Model;
namespace Example
{
public class CompaniesListExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.merge.dev/api/hris/v1";
// Configure API key authorization: tokenAuth
config.AddApiKey("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("Authorization", "Bearer");
var apiInstance = new CompaniesApi(config);
var xAccountToken = xAccountToken_example; // string | Token identifying the end user.
var createdAfter = 2013-10-20T19:20:30+01:00; // DateTime? | If provided, will only return objects created after this datetime. (optional)
var createdBefore = 2013-10-20T19:20:30+01:00; // DateTime? | If provided, will only return objects created before this datetime. (optional)
var cursor = cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw; // string | The pagination cursor value. (optional)
var includeDeletedData = true; // bool? | Whether to include data that was marked as deleted by third party webhooks. (optional)
var includeRemoteData = true; // bool? | Whether to include the original data Merge fetched from the third-party to produce these models. (optional)
var modifiedAfter = 2013-10-20T19:20:30+01:00; // DateTime? | If provided, only objects synced by Merge after this date time will be returned. (optional)
var modifiedBefore = 2013-10-20T19:20:30+01:00; // DateTime? | If provided, only objects synced by Merge before this date time will be returned. (optional)
var pageSize = 56; // int? | Number of results to return per page. (optional)
var remoteId = remoteId_example; // string | The API provider's ID for the given object. (optional)
try
{
PaginatedCompanyList result = apiInstance.CompaniesList(xAccountToken, createdAfter, createdBefore, cursor, includeDeletedData, includeRemoteData, modifiedAfter, modifiedBefore, pageSize, remoteId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CompaniesApi.CompaniesList: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
xAccountToken | string | Token identifying the end user. | |
createdAfter | DateTime? | If provided, will only return objects created after this datetime. | [optional] |
createdBefore | DateTime? | If provided, will only return objects created before this datetime. | [optional] |
cursor | string | The pagination cursor value. | [optional] |
includeDeletedData | bool? | Whether to include data that was marked as deleted by third party webhooks. | [optional] |
includeRemoteData | bool? | Whether to include the original data Merge fetched from the third-party to produce these models. | [optional] |
modifiedAfter | DateTime? | If provided, only objects synced by Merge after this date time will be returned. | [optional] |
modifiedBefore | DateTime? | If provided, only objects synced by Merge before this date time will be returned. | [optional] |
pageSize | int? | Number of results to return per page. | [optional] |
remoteId | string | The API provider's ID for the given object. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
Company CompaniesRetrieve (string xAccountToken, Guid id, bool? includeRemoteData = null)
Returns a Company
object with the given id
.
using System.Collections.Generic;
using System.Diagnostics;
using Merge.HRISClient.Api;
using Merge.HRISClient.Client;
using Merge.HRISClient.Model;
namespace Example
{
public class CompaniesRetrieveExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api.merge.dev/api/hris/v1";
// Configure API key authorization: tokenAuth
config.AddApiKey("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("Authorization", "Bearer");
var apiInstance = new CompaniesApi(config);
var xAccountToken = xAccountToken_example; // string | Token identifying the end user.
var id = new Guid(); // Guid |
var includeRemoteData = true; // bool? | Whether to include the original data Merge fetched from the third-party to produce these models. (optional)
try
{
Company result = apiInstance.CompaniesRetrieve(xAccountToken, id, includeRemoteData);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling CompaniesApi.CompaniesRetrieve: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
xAccountToken | string | Token identifying the end user. | |
id | Guid | ||
includeRemoteData | bool? | Whether to include the original data Merge fetched from the third-party to produce these models. | [optional] |
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]