Skip to content
This repository has been archived by the owner on Jan 20, 2024. It is now read-only.

Automated release 1.0 #19

Open
wants to merge 1 commit into
base: 1.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions docs/CampaignApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Method | HTTP request | Description
------------- | ------------- | -------------
[**CreateCampaign**](CampaignApi.md#createcampaign) | **POST** /hub/v1/campaigns | createCampaign
[**DeleteCampaignById**](CampaignApi.md#deletecampaignbyid) | **DELETE** /hub/v1/campaigns/{id} | deleteCampaignById
[**GetAllCampaigns**](CampaignApi.md#getallcampaigns) | **GET** /hub/v1/campaigns | getAllCampaigns
[**GetCampaignById**](CampaignApi.md#getcampaignbyid) | **GET** /hub/v1/campaigns/{id} | getCampaignById


Expand Down Expand Up @@ -130,6 +131,63 @@ No authorization required

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

<a name="getallcampaigns"></a>
# **GetAllCampaigns**
> GetAllCampaignsResponse GetAllCampaigns ()

getAllCampaigns

Gets all campaigns.

### Example
```csharp
using System;
using System.Diagnostics;
using Salesforce.MarketingCloud.Api;
using Salesforce.MarketingCloud.Client;
using Salesforce.MarketingCloud.Model;

namespace Example
{
public class GetAllCampaignsExample
{
public void main()
{
var apiInstance = new CampaignApi();

try
{
// getAllCampaigns
GetAllCampaignsResponse result = apiInstance.GetAllCampaigns();
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling CampaignApi.GetAllCampaigns: " + e.Message );
}
}
}
}
```

### Parameters
This endpoint does not need any parameter.

### Return type

[**GetAllCampaignsResponse**](GetAllCampaignsResponse.md)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: Not defined

[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

<a name="getcampaignbyid"></a>
# **GetCampaignById**
> Campaign GetCampaignById (string id)
Expand Down
12 changes: 12 additions & 0 deletions docs/GetAllCampaignsResponse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Salesforce.MarketingCloud.Model.GetAllCampaignsResponse
## Properties

Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Items** | [**List&lt;Campaign&gt;**](Campaign.md) | | [optional]
**Count** | **int?** | Number of pages | [optional]
**Page** | **int?** | Page number to return. | [optional]
**PageSize** | **int?** | Number of campaigns, which are array elements, to return per paged response. | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Api/AssetApi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
159 changes: 158 additions & 1 deletion src/Salesforce.MarketingCloud/Api/CampaignApi.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down Expand Up @@ -69,6 +69,25 @@ public interface ICampaignApi
/// <returns>ApiResponse of Object(void)</returns>
ApiResponse<Object> DeleteCampaignByIdWithHttpInfo (string id);
/// <summary>
/// getAllCampaigns
/// </summary>
/// <remarks>
/// Gets all campaigns.
/// </remarks>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>GetAllCampaignsResponse</returns>
GetAllCampaignsResponse GetAllCampaigns ();

/// <summary>
/// getAllCampaigns
/// </summary>
/// <remarks>
/// Gets all campaigns.
/// </remarks>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of GetAllCampaignsResponse</returns>
ApiResponse<GetAllCampaignsResponse> GetAllCampaignsWithHttpInfo ();
/// <summary>
/// getCampaignById
/// </summary>
/// <remarks>
Expand Down Expand Up @@ -134,6 +153,25 @@ public interface ICampaignApi
/// <returns>Task of ApiResponse</returns>
System.Threading.Tasks.Task<ApiResponse<Object>> DeleteCampaignByIdAsyncWithHttpInfo (string id);
/// <summary>
/// getAllCampaigns
/// </summary>
/// <remarks>
/// Gets all campaigns.
/// </remarks>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>Task of GetAllCampaignsResponse</returns>
System.Threading.Tasks.Task<GetAllCampaignsResponse> GetAllCampaignsAsync ();

/// <summary>
/// getAllCampaigns
/// </summary>
/// <remarks>
/// Gets all campaigns.
/// </remarks>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>Task of ApiResponse (GetAllCampaignsResponse)</returns>
System.Threading.Tasks.Task<ApiResponse<GetAllCampaignsResponse>> GetAllCampaignsAsyncWithHttpInfo ();
/// <summary>
/// getCampaignById
/// </summary>
/// <remarks>
Expand Down Expand Up @@ -445,6 +483,125 @@ public async System.Threading.Tasks.Task<ApiResponse<Object>> DeleteCampaignById
null);
}

/// <summary>
/// getAllCampaigns Gets all campaigns.
/// </summary>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>GetAllCampaignsResponse</returns>
public GetAllCampaignsResponse GetAllCampaigns ()
{
ApiResponse<GetAllCampaignsResponse> localVarResponse = GetAllCampaignsWithHttpInfo();
return localVarResponse.Data;
}

/// <summary>
/// getAllCampaigns Gets all campaigns.
/// </summary>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>ApiResponse of GetAllCampaignsResponse</returns>
public ApiResponse< GetAllCampaignsResponse > GetAllCampaignsWithHttpInfo ()
{

var localVarPath = "/hub/v1/campaigns";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;

// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);



// make the HTTP request
IRestResponse localVarResponse = (IRestResponse) this.Configuration.ApiClient.CallApi(localVarPath,
Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);

int localVarStatusCode = (int) localVarResponse.StatusCode;

if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("GetAllCampaigns", localVarResponse);
if (exception != null) throw exception;
}

return new ApiResponse<GetAllCampaignsResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Name, x => x.Value.ToString()),
(GetAllCampaignsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetAllCampaignsResponse)));
}

/// <summary>
/// getAllCampaigns Gets all campaigns.
/// </summary>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>Task of GetAllCampaignsResponse</returns>
public async System.Threading.Tasks.Task<GetAllCampaignsResponse> GetAllCampaignsAsync ()
{
ApiResponse<GetAllCampaignsResponse> localVarResponse = await GetAllCampaignsAsyncWithHttpInfo();
return localVarResponse.Data;

}

/// <summary>
/// getAllCampaigns Gets all campaigns.
/// </summary>
/// <exception cref="Salesforce.MarketingCloud.Client.ApiException">Thrown when fails to make API call</exception>
/// <returns>Task of ApiResponse (GetAllCampaignsResponse)</returns>
public async System.Threading.Tasks.Task<ApiResponse<GetAllCampaignsResponse>> GetAllCampaignsAsyncWithHttpInfo ()
{

var localVarPath = "/hub/v1/campaigns";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(this.Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;

// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
};
String localVarHttpContentType = this.Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);

// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
};
String localVarHttpHeaderAccept = this.Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);



// make the HTTP request
IRestResponse localVarResponse = (IRestResponse) await this.Configuration.ApiClient.CallApiAsync(localVarPath,
Method.GET, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);

int localVarStatusCode = (int) localVarResponse.StatusCode;

if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("GetAllCampaigns", localVarResponse);
if (exception != null) throw exception;
}

return new ApiResponse<GetAllCampaignsResponse>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Name, x => x.Value.ToString()),
(GetAllCampaignsResponse) this.Configuration.ApiClient.Deserialize(localVarResponse, typeof(GetAllCampaignsResponse)));
}

/// <summary>
/// getCampaignById Retrieves a campaign.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Client/ApiClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Client/ApiException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Client/ApiResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
8 changes: 4 additions & 4 deletions src/Salesforce.MarketingCloud/Client/Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down Expand Up @@ -31,7 +31,7 @@ public class Configuration : IReadableConfiguration
/// Version of the package.
/// </summary>
/// <value>Version of the package.</value>
public const string Version = "1.0.0";
public const string Version = "1.1.0";

/// <summary>
/// SDK Name
Expand Down Expand Up @@ -442,8 +442,8 @@ public static String ToDebugReport()
String report = "C# SDK (Salesforce.MarketingCloud) Debug Report:\n";
report += " OS: " + System.Environment.OSVersion + "\n";
report += " .NET Framework Version: " + System.Environment.Version + "\n";
report += " Version of the API: 1.0.0\n";
report += " SDK Package Version: 1.0.0\n";
report += " Version of the API: 1.1.0\n";
report += " SDK Package Version: 1.1.0\n";

return report;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Client/ExceptionFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Client/IApiAccessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Salesforce.MarketingCloud/Model/ApiError.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* Marketing Cloud's REST API is our newest API. It supports multi-channel use cases, is much more lightweight and easy to use than our SOAP API, and is getting more comprehensive with every release.
*
* OpenAPI spec version: 1.0.0
* OpenAPI spec version: 1.1.0
* Contact: [email protected]
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
Expand Down
Loading