All URIs are relative to https://api-v2.fattureincloud.it
Method | HTTP request | Description |
---|---|---|
GetUserInfo | GET /user/info | Get User Info |
ListUserCompanies | GET /user/companies | List User Companies |
GetUserInfoResponse GetUserInfo ()
Get User Info
Gets the current user's info.
using System.Collections.Generic;
using System.Diagnostics;
using It.FattureInCloud.Sdk.Api;
using It.FattureInCloud.Sdk.Client;
using It.FattureInCloud.Sdk.Model;
namespace Example
{
public class GetUserInfoExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api-v2.fattureincloud.it";
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new UserApi(config);
try
{
// Get User Info
GetUserInfoResponse result = apiInstance.GetUserInfo();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.GetUserInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// Get User Info
ApiResponse<GetUserInfoResponse> response = apiInstance.GetUserInfoWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.GetUserInfoWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | - | |
401 | Unauthorized. | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListUserCompaniesResponse ListUserCompanies ()
List User Companies
Lists the companies controlled by the current user.
using System.Collections.Generic;
using System.Diagnostics;
using It.FattureInCloud.Sdk.Api;
using It.FattureInCloud.Sdk.Client;
using It.FattureInCloud.Sdk.Model;
namespace Example
{
public class ListUserCompaniesExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "https://api-v2.fattureincloud.it";
// Configure OAuth2 access token for authorization: OAuth2AuthenticationCodeFlow
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new UserApi(config);
try
{
// List User Companies
ListUserCompaniesResponse result = apiInstance.ListUserCompanies();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.ListUserCompanies: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
This returns an ApiResponse object which contains the response data, status code and headers.
try
{
// List User Companies
ApiResponse<ListUserCompaniesResponse> response = apiInstance.ListUserCompaniesWithHttpInfo();
Debug.Write("Status Code: " + response.StatusCode);
Debug.Write("Response Headers: " + response.Headers);
Debug.Write("Response Body: " + response.Data);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.ListUserCompaniesWithHttpInfo: " + e.Message);
Debug.Print("Status Code: " + e.ErrorCode);
Debug.Print(e.StackTrace);
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
Status code | Description | Response headers |
---|---|---|
200 | User Companies. | - |
401 | Unauthorized | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]