All URIs are relative to https://ci.appveyor.com/api
Method | HTTP request | Description |
---|---|---|
AddRole | Post /roles | Add role |
DeleteRole | Delete /roles/{roleId} | Delete role |
GetRole | Get /roles/{roleId} | Get role |
GetRoles | Get /roles | Get roles |
UpdateRole | Put /roles | Update role |
RoleWithGroups AddRole (RoleAddition body)
Add role
using System;
using System.Diagnostics;
using Itofinity.Appveyor.Refit.Api;
using Itofinity.Appveyor.Refit.Client;
using Itofinity.Appveyor.Refit.Model;
namespace Example
{
public class AddRoleExample
{
public void main()
{
// Configure API key authorization: apiToken
Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");
var apiInstance = new RoleApi();
var body = new RoleAddition(); // RoleAddition |
try
{
// Add role
RoleWithGroups result = apiInstance.AddRole(body);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling RoleApi.AddRole: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
body | RoleAddition |
- Content-Type: application/json
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
void DeleteRole (int? roleId)
Delete role
using System;
using System.Diagnostics;
using Itofinity.Appveyor.Refit.Api;
using Itofinity.Appveyor.Refit.Client;
using Itofinity.Appveyor.Refit.Model;
namespace Example
{
public class DeleteRoleExample
{
public void main()
{
// Configure API key authorization: apiToken
Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");
var apiInstance = new RoleApi();
var roleId = 56; // int? | Role ID
try
{
// Delete role
apiInstance.DeleteRole(roleId);
}
catch (Exception e)
{
Debug.Print("Exception when calling RoleApi.DeleteRole: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
roleId | int? | Role ID |
void (empty response body)
- Content-Type: application/json
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RoleWithGroups GetRole (int? roleId)
Get role
using System;
using System.Diagnostics;
using Itofinity.Appveyor.Refit.Api;
using Itofinity.Appveyor.Refit.Client;
using Itofinity.Appveyor.Refit.Model;
namespace Example
{
public class GetRoleExample
{
public void main()
{
// Configure API key authorization: apiToken
Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");
var apiInstance = new RoleApi();
var roleId = 56; // int? | Role ID
try
{
// Get role
RoleWithGroups result = apiInstance.GetRole(roleId);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling RoleApi.GetRole: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
roleId | int? | Role ID |
- Content-Type: application/json
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
List GetRoles ()
Get roles
using System;
using System.Diagnostics;
using Itofinity.Appveyor.Refit.Api;
using Itofinity.Appveyor.Refit.Client;
using Itofinity.Appveyor.Refit.Model;
namespace Example
{
public class GetRolesExample
{
public void main()
{
// Configure API key authorization: apiToken
Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");
var apiInstance = new RoleApi();
try
{
// Get roles
List<Role> result = apiInstance.GetRoles();
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling RoleApi.GetRoles: " + e.Message );
}
}
}
}
This endpoint does not need any parameter.
- Content-Type: application/json
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RoleWithGroups UpdateRole (RoleWithGroups body)
Update role
using System;
using System.Diagnostics;
using Itofinity.Appveyor.Refit.Api;
using Itofinity.Appveyor.Refit.Client;
using Itofinity.Appveyor.Refit.Model;
namespace Example
{
public class UpdateRoleExample
{
public void main()
{
// Configure API key authorization: apiToken
Configuration.Default.ApiKey.Add("Authorization", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// Configuration.Default.ApiKeyPrefix.Add("Authorization", "Bearer");
var apiInstance = new RoleApi();
var body = new RoleWithGroups(); // RoleWithGroups |
try
{
// Update role
RoleWithGroups result = apiInstance.UpdateRole(body);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling RoleApi.UpdateRole: " + e.Message );
}
}
}
}
Name | Type | Description | Notes |
---|---|---|---|
body | RoleWithGroups |
- Content-Type: application/json
- Accept: application/json, application/xml
[Back to top] [Back to API list] [Back to Model list] [Back to README]