openapi: 3.0.0
info:
  title: MMS Campaigns
  description: Everything about MMS
servers:
  - url: https://rest.clicksend.com
components:
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
  schemas:
    mms_campaign:
      type: object
      properties:
        mms_campaign_id:
          type: integer
          description: The ID of the MMS campaign.
          example: 96
        name:
          type: string
          description: The name of the MMS campaign.
          example: Koala Campaign
        user_id:
          type: integer
          description: The ID of the user who created the campaign.
          example: 20807
        subaccount_id:
          type: integer
          description: The ID of the subaccount associated with the campaign.
          example: 15
        list_id:
          type: integer
          description: The ID of the list associated with the campaign.
          example: 85262
        from:
          type: string
          description: The sender's phone number or ID.
          example: '0451919865'
        subject:
          type: string
          description: The subject of the MMS campaign.
          example: New MMS campaign test
        file_name:
          type: string
          description: The name of the media file attached to the MMS.
          example: 8EA5FA8C-3216-4A5D-86EA-6BE78050E439.jpg
        body:
          type: string
          description: The body or content of the MMS.
          example: >-
            Hey (First Name), I want to ask if this is your lastname: (Last
            Name)? Also, do you like koalas? Visit http://smsu.io/xxxxx for more
            details.
        schedule:
          type: integer
          description: The schedule time of the MMS campaign.
          example: 1531800743
        status:
          type: string
          description: The status of the MMS campaign.
          example: Queued
        date_added:
          type: integer
          description: The date when the campaign was added.
          example: 1531800745
        _total_count:
          type: integer
          description: The total count associated with the campaign.
          example: 1
        _list_name:
          type: string
          description: The name of the list associated with the campaign.
          example: test
        _media_file_url:
          type: string
          description: The URL of the media file attached to the MMS.
          example: >-
            http://rest.clicksend.clicksend/files/8EA5FA8C-3216-4A5D-86EA-6BE78050E439.jpg
    send-mms-campaign:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: MMS campaign has been created.
        data:
          $ref: '#/components/schemas/mms_campaign'
    currency:
      type: object
      description: The parameters related to currency.
      properties:
        currency_name_short:
          type: string
          description: >-
            The currency used for the sender in three-letter format (e.g. USD,
            EUR, AUD, NZD, etc).
          example: AUD
        currency_prefix_d:
          type: string
          description: >-
            The symbol used to indicate the currency of the sender (e.g. $ , €,
            etc).
          example: $
        currency_prefix_c:
          type: string
          description: The currency basic unit (e.g. cents).
          example: c
        currency_name_long:
          type: string
          description: The full name of the currency.
          example: Australian Dollars
    calculate-mms-campaign-price:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: Here is your result.
        data:
          type: object
          properties:
            total_count:
              type: string
              description: The total number of records.
              example: 1
            total_price:
              type: string
              description: The total price of the MMS campaign.
              example: '0.429'
            data:
              type: object
              properties:
                from:
                  type: string
                  description: The sender id.
                  example: '+61411111111'
                schedule:
                  type: string
                  description: The schedule timestamp.
                  example: 1577833200
                body:
                  type: string
                  description: The message body.
                  example: >-
                    Hey test, I want to ask if this is your lastname: ? Also, do
                    you like koalas?
            _currency:
              $ref: '#/components/schemas/currency'
    view-mms-campaign:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: Here is your result.
        data:
          $ref: '#/components/schemas/mms_campaign'
    update-mms-campaign:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: MMS campaign has been updated.
        data:
          $ref: '#/components/schemas/mms_campaign'
    cancel-mms-campaign:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: Scheduled MMS campaign has been cancelled.
        data:
          $ref: '#/components/schemas/mms_campaign'
    pagination:
      type: object
      properties:
        total:
          type: integer
          description: The total number of items available for viewing.
          example: 2
        per_page:
          type: integer
          description: >-
            The number of items returned per page. This is specified in the
            limit parameter. You can have 100 items at maximum, and 15 at
            minimum.
          example: 15
        current_page:
          type: integer
          description: The current page number.
          example: 1
        last_page:
          type: integer
          description: The last page number.
          example: 1
        next_page_url:
          type: string
          nullable: true
          description: >-
            A URL of the next page. It will return **null** if there’s no next
            page.
          example: null
        prev_page_url:
          type: string
          nullable: true
          description: >-
            A URL of the previous page. It will return **null** if there’s no
            previous page.
          example: null
        from:
          type: integer
          description: The number of the first result in the current page.
          example: 1
        to:
          type: integer
          description: The number of the last result in the current page.
          example: 2
    view-all-mms-campaigns:
      type: object
      properties:
        http_code:
          type: integer
          description: The HTTP status code of the response.
          example: 200
        response_code:
          type: string
          description: The response code indicating the status of the operation.
          example: SUCCESS
        response_msg:
          type: string
          description: A message describing the outcome of the operation.
          example: Countries have been selected.
        data:
          allOf:
            - $ref: '#/components/schemas/pagination'
            - type: object
              properties:
                data:
                  type: array
                  items:
                    $ref: '#/components/schemas/mms_campaign'
paths:
  /v3/mms-campaigns/send:
    post:
      summary: Send MMS Campaign
      operationId: send-mms-campaign
      description: >-
        _Create mms campaign_


        ### Properties


        | Name | Type | Required | Restrictions | Description |

        | --- | --- | --- | --- | --- |

        | list_id | integer(int32) | true | none | Your list id. |

        | name | string | true | none | Your campaign name. |

        | body | string | true | none | Your campaign message. |

        | from | string | true |
        [yes](http://help.clicksend.com/SMS/what-is-a-sender-id-or-sender-number)
        | Your sender id |

        | schedule | integer(int32) | false | none | Your schedule timestamp. |

        | subject | string | true | none | Subject of MMS campaign. |

        | media_file | string | true | none | URL pointing to media file. |



        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.



        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                list_id:
                  type: string
                name:
                  type: string
                from:
                  type: string
                body:
                  type: string
                url_to_shorten:
                  type: string
                subject:
                  type: string
                media_file:
                  type: string
              example:
                list_id: '{{listId}}'
                name: Koala Campaign
                from: '+61411111111'
                body: >-
                  Hey (First Name), I want to ask if this is your lastname:
                  (Last Name)? Also, do you like koalas? Visit
                  http://smsg.io/xxxxx for more details.
                url_to_shorten: http://test.com.au
                subject: New MMS campaign test
                media_file: https://www.ivertech.com/Articles/Images/KoalaBear200x200.jpg
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/send-mms-campaign'
      x-codeSamples:
        - lang: curl
          source: |-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \
                 --request POST \

                 --header "Content-Type: application/json" \
                 --data-binary "{
                \"list_id\":428,
                \"name\":\"My Campaign 1\",
                \"from\":\"+61353787448\",
                \"body\":\"This is my new campaign message.\",
                \"schedule\":1444821615,
                \"subject\": \"test\",
                \"media_file\": \"http://yourdomain.com/tpLaX6A.gif\"
            }" \
            'https://rest.clicksend.com/v3/mms-campaigns/send'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $campaign = new \ClickSend\Model\MmsCampaign(); //
            \ClickSend\Model\MmsCampaign | MmsCampaign model

            $campaign->setListId(185161);

            $campaign->setName("My Campaign 1");

            $campaign->setBody("This is my new campaign message.");

            $campaign->setFrom("+61353787448");

            $campaign->setSchedule(1577013061);

            $campaign->setSubject("test");

            $campaign->setMediaFile("https://media.tenor.com/images/a3c2a6cf42e0ac49ebd7cd347d10fe94/tenor.gif");


            try {
                $result = $apiInstance->mmsCampaignsSendPost($campaign);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignsSendPost: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: >-
            using IO.ClickSend.ClickSend.Api;

            using IO.ClickSend.Client;

            using IO.ClickSend.ClickSend.Model;


            var configuration = new Configuration()

            {
                Username = USERNAME,
                Password = API_KEY  
            };

            var mmsCampaignApi = new MmsCampaignApi(configuration);

            var response = mmsCampaignApi.MmsCampaignsSendPost(new MmsCampaign()
            {
                ListId =  LIST_ID,
                Name = "Name",
                Body = "This is test body",
                From = "+11231231234",
                Schedule = TimeStamp,
                Subject = "Test subject",
                MediaFile = "https://yourdomain.com/file.jpg"
            });
        - lang: Java
          source: |-
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;
            import ClickSend.Model.MmsCampaign;

            public class create_mms_campaign {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                MmsCampaign campaign = new MmsCampaign(); // MmsCampaign | MmsCampaign model
                campaign.listId(new Integer(185161));
                campaign.name("My Campaign 1");
                campaign.body("This is my new campaign message.");
                campaign.from("+61353787448");
                campaign.schedule(new Integer(1545477071));
                campaign.subject("test");
                campaign.mediaFile("http://yourdomain.com/tpLaX6A.gif");
                try {
                    String result = apiInstance.mmsCampaignsSendPost(campaign);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignsSendPost");
                    e.printStackTrace();
                }

              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var campaign = new api.MmsCampaign();


            campaign.listId = 185161;

            campaign.name = "My Campaign 1";

            campaign.body = "This is my new campaign message.";

            campaign.from = "+61353787448";

            campaign.subject = "subject";

            campaign.mediaFile =
            "https://thumbs.gfycat.com/BelatedComplexJerboa-small.gif";


            mmsCampaignApi.mmsCampaignsSendPost(campaign).then(function(response)
            {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            # MmsCampaign | MmsCampaign model
            campaign = ClickSendClient::MmsCampaign.new(
              "schedule": 0,
              "list_id": 1234,
              "name": "name",
              "from": "from",
              "body": "body",
              "subject": "subject",
              "media_file": "media_file_url"
            )

            begin
              # Create mms campaign
              result = api_instance.mms_campaigns_send_post(campaign)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaigns_send_post: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            # MmsCampaign | MmsCampaign model

            campaign = clicksend_client.MmsCampaign(
                        list_id=185161,
                        name="My Campaign 1",
                        _from="+61353787448",
                        body="This is my new campaign message.",
                        schedule=1444821615,
                        subject="test",
                        media_file="http://yourdomain.com/tpLaX6A.gif")

            try:
                # Create mms campaign
                api_response = api_instance.mms_campaigns_send_post(campaign)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaigns_send_post: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;

            use WWW::ClickSendClient::Object::MmsCampaign;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my %params = (
                'list_id'    => 'list_id',
                'name'       => 'name',
                'body'       => 'body',
                'from'       => 'from',
                'schedule'   => 'schedule',
                'subject'    => 'subject',
                'media_file' => 'media_file_url'
            );


            my $mms_obj =
            WWW::ClickSendClient::Object::MmsCampaign->new(%params);

            my $json_output = $api->mms_campaigns_send_post('campaign' =>
            $mms_obj);


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaign *campaign = [[CSMmsCampaign alloc] init];

            campaign.listId = @(428);

            campaign.name = @"name";

            campaign.body = @"body";

            campaign.from = @"+61353787448";

            campaign.subject = @"subject";

            campaign.mediaFile = @"http://yourdomain.com/tpLaX6A.gif";


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi mmsCampaignsSendPostWithCampaign:campaign
            completionHandler:^(NSString *output, NSError *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire

            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {
                ClickSendClientAPI.customHeaders = [authHeader.key : authHeader.value]
            }


            let mmsCampaign = MmsCampaign(
                                listId: 428,
                                name: "name",
                                body: "body",
                                from: "+61353787448",
                                schedule: nil,
                                subject: "subject",
                                mediaFile: "http://yourdomain.com/tpLaX6A.gif"
                            )

            MmsCampaignAPI.mmsCampaignsSendPost(campaign: mmsCampaign) {
            (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                            print(error)
                        }
                    }
                }
            }
  /v3/mms-campaigns/price:
    post:
      summary: Calculate MMS Campaign Price
      operationId: calculate-mms-campaign-price
      description: >-
        _Calculate price for mms campaign_


        ### Properties


        | Name | Type | Required | Restrictions | Description |

        | --- | --- | --- | --- | --- |

        | list_id | integer(int32) | true | none | Your list id. |

        | name | string | true | none | Your campaign name. |

        | body | string | true | none | Your campaign message. |

        | from | string | true |
        [yes](http://help.clicksend.com/SMS/what-is-a-sender-id-or-sender-number)
        | Your sender id |

        | schedule | integer(int32) | false | none | Your schedule timestamp. |

        | subject | string | true | none | Subject of MMS campaign. |

        | media_file | string | true | none | URL pointing to media file. |



        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.



        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example:
                list_id: 12345
                name: Koala Campaign
                from: '+61411111111'
                body: >-
                  Hey (First Name), I want to ask if this is your lastname:
                  (Last Name)? Also, do you like koalas? Visit
                  http://smsg.io/xxxxx for more details.
                url_to_shorten: http://test.com.au
                subject: New MMS campaign test
                media_file: https://www.ivertech.com/Articles/Images/KoalaBear200x200.jpg
                schedule: 1577833200
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/calculate-mms-campaign-price'
      x-codeSamples:
        - lang: curl
          source: |-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \
                 --request POST \

                 --header "Content-Type: application/json" \
                 --data-binary "{
                \"list_id\":428,
                \"name\":\"My Campaign 1\",
                \"from\":\"+61353787448\",
                \"body\":\"(First Name), this is your new campaign message.\",
                \"subject\": \"test\",
                \"media_file\": \"http://yourdomain.com/tpLaX6A.gif\"
            }" \
            'https://rest.clicksend.com/v3/mms-campaigns/price'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $campaign = new \ClickSend\Model\MmsCampaign(); //
            \ClickSend\Model\MmsCampaign | MmsCampaign model

            $campaign->setListId(185161);

            $campaign->setName("My Campaign 1");

            $campaign->setBody("This is my new campaign message.");

            $campaign->setFrom("+61353787448");

            $campaign->setSchedule(1577013061);

            $campaign->setSubject("test");

            $campaign->setMediaFile("https://media.tenor.com/images/a3c2a6cf42e0ac49ebd7cd347d10fe94/tenor.gif");


            try {
                $result = $apiInstance->mmsCampaignsPricePost($campaign);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignsPricePost: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: >-
            using IO.ClickSend.ClickSend.Api;

            using IO.ClickSend.Client;

            using IO.ClickSend.ClickSend.Model;


            var configuration = new Configuration()

            {
                Username = USERNAME,
                Password = API_KEY  
            };

            var mmsCampaignApi = new MmsCampaignApi(configuration);

            var response = mmsCampaignApi.MmsCampaignsPricePost(new
            MmsCampaign() {
                ListId =  LIST_ID,
                Name = "Name",
                Body = "This is test body",
                From = "+11231231234",
                Schedule = TimeStamp,
                Subject = "Test subject",
                MediaFile = "https://yourdomain.com/file.jpg"
            });
        - lang: Java
          source: |-
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;
            import ClickSend.Model.MmsCampaign;

            public class calculate_mms_campaign_price {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                MmsCampaign campaign = new MmsCampaign(); // MmsCampaign | MmsCampaign model
                campaign.listId(new Integer(185161));
                campaign.name("My Campaign 1");
                campaign.body("This is my new campaign message.");
                campaign.from("+61353787448");
                campaign.schedule(new Integer(1545477071));
                campaign.subject("test");
                campaign.mediaFile("http://yourdomain.com/tpLaX6A.gif");
                try {
                    String result = apiInstance.mmsCampaignsPricePost(campaign);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignsPricePost");
                    e.printStackTrace();
                }
              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var campaign = new api.MmsCampaign();


            campaign.listId = 185161;

            campaign.name = "My Campaign 1";

            campaign.body = "This is my new campaign message.";

            campaign.from = "+61353787448";

            campaign.subject = "subject";

            campaign.mediaFile =
            "https://thumbs.gfycat.com/BelatedComplexJerboa-small.gif";


            mmsCampaignApi.mmsCampaignsPricePost(campaign).then(function(response)
            {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            # MmsCampaign | MmsCampaign model
            campaign = ClickSendClient::MmsCampaign.new(
              "schedule": 0,
              "list_id": 1234,
              "name": "name",
              "from": "from",
              "body": "body",
              "subject": "subject",
              "media_file": "media_file_url"
            )

            begin
              # Calculate price for mms campaign
              result = api_instance.mms_campaigns_price_post(campaign)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaigns_price_post: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            # MmsCampaign | MmsCampaign model

            campaign = clicksend_client.MmsCampaign(
                        list_id=185161,
                        name="My Campaign 1",
                        _from="+61353787448",
                        body="This is my new campaign message.",
                        schedule=1444821615,
                        subject="test",
                        media_file="http://yourdomain.com/tpLaX6A.gif")

            try:
                # Calculate price for mms campaign
                api_response = api_instance.mms_campaigns_price_post(campaign)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaigns_price_post: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;

            use WWW::ClickSendClient::Object::MmsCampaign;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my %params = (
                'list_id'    => 'list_id',
                'name'       => 'name',
                'body'       => 'body',
                'from'       => 'from',
                'schedule'   => 'schedule',
                'subject'    => 'subject',
                'media_file' => 'media_file_url'
            );


            my $mms_obj =
            WWW::ClickSendClient::Object::MmsCampaign->new(%params);

            my $json_output = $api->mms_campaigns_price_post('campaign' =>
            $mms_obj);


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaign *campaign = [[CSMmsCampaign alloc] init];

            campaign.listId = @(428);

            campaign.name = @"name";

            campaign.body = @"body";

            campaign.from = @"+61353787448";

            campaign.subject = @"subject";

            campaign.mediaFile = @"http://yourdomain.com/tpLaX6A.gif";


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi mmsCampaignsPricePostWithCampaign:campaign
            completionHandler:^(NSString *output, NSError *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire

            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {

            ClickSendClientAPI.customHeaders = [authHeader.key :
            authHeader.value]

            }


            let mmsCampaign = MmsCampaign(listId: 428, name: "name", body:
            "body", from: "+61353787448", schedule: nil, subject: "subject",
            mediaFile: "http://yourdomain.com/tpLaX6A.gif")


            MmsCampaignAPI.mmsCampaignsPricePost(campaign: mmsCampaign) {
            (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                            print(error)
                        }
                    }
                }
            }
  /v3/mms-campaigns/{mms_campaign_id}:
    put:
      summary: Update MMS Campaign
      operationId: update-mms-campaign
      description: >-
        _Update mms campaign_


        ### Parameters


        | Parameter | In | Type | Required | Description |

        | --- | --- | --- | --- | --- |

        | mms_campaign_id | path | integer(int32) | true | ID of MMS campaign to
        update |


        ### Properties


        | Name | Type | Required | Restrictions | Description |

        | --- | --- | --- | --- | --- |

        | list_id | integer(int32) | true | none | Your list id. |

        | name | string | true | none | Your campaign name. |

        | body | string | true | none | Your campaign message. |

        | from | string | true |
        [yes](http://help.clicksend.com/SMS/what-is-a-sender-id-or-sender-number)
        | Your sender id |

        | schedule | integer(int32) | false | none | Your schedule timestamp. |

        | subject | string | true | none | Subject of MMS campaign. |

        | media_file | string | true | none | URL pointing to media file. |


        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.


        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                list_id:
                  type: string
                name:
                  type: string
                from:
                  type: string
                body:
                  type: string
              example:
                list_id: '{{list_id}}'
                name: My Campaign
                from: '+61411111111'
                body: >-
                  Hey (First Name), I want to ask if this is your lastname:
                  (Last Name)?
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
        - name: mms_campaign_id
          in: path
          schema:
            type: string
          required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/update-mms-campaign'
      x-codeSamples:
        - lang: curl
          source: |-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \
                 --request PUT \

                 --header "Content-Type: application/json" \
                 --data-binary "{
                \"list_id\":428,
                \"name\":\"Awesome campaign.\",
                \"from\":\"+61353787447\",
                \"body\":\"his is an awesome message.\",
                \"schedule\":1444821615,
                \"subject\": \"test\",
                \"media_file\": \"http://yourdomain.com/tpLaX6A.gif\"
            }" \
            'https://rest.clicksend.com/v3/mms-campaigns/{mms_campaign_id}'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $mms_campaign_id = 2492; // int | ID of MMS campaign to update

            $campaign = new \ClickSend\Model\MmsCampaign(); //
            \ClickSend\Model\MmsCampaign | MmsCampaign model

            $campaign->setListId(185161);

            $campaign->setName("My Campaign 1");

            $campaign->setBody("This is my new campaign message.");

            $campaign->setFrom("+61353787448");

            $campaign->setSchedule(1577013061);

            $campaign->setSubject("test");

            $campaign->setMediaFile("https://media.tenor.com/images/a3c2a6cf42e0ac49ebd7cd347d10fe94/tenor.gif");


            try {
                $result = $apiInstance->mmsCampaignsByMmsCampaignIdPut($mms_campaign_id, $campaign);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignsByMmsCampaignIdPut: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: >-
            using IO.ClickSend.ClickSend.Api;

            using IO.ClickSend.Client;

            using IO.ClickSend.ClickSend.Model;


            var configuration = new Configuration()

            {
                Username = USERNAME,
                Password = API_KEY  
            };

            var mmsCampaignApi = new MmsCampaignApi(configuration);

            var response =
            mmsCampaignApi.MmsCampaignsByMmsCampaignIdPut(CAMPAIGN_ID,new
            MmsCampaign() {
                ListId =  LIST_ID,
                Name = "Name",
                Body = "This is test body",
                From = "+11231231234",
                Schedule = TimeStamp,
                Subject = "Test subject",
                MediaFile = "https://yourdomain.com/file.jpg"
            });
        - lang: Java
          source: |-
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;
            import ClickSend.Model.MmsCampaign;

            public class update_mms_campaign {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                Integer mmsCampaignId = 1845; // Integer | ID of MMS campaign to update
                MmsCampaign campaign = new MmsCampaign(); // MmsCampaign | MmsCampaign model
                campaign.listId(new Integer(185161));
                campaign.name("name");
                campaign.body("body");
                campaign.from("+6135378744");
                campaign.schedule(new Integer(1478523369));
                campaign.subject("subject");
                campaign.mediaFile("http://yourdomain.com/tpLaX6A.gif");
                try {
                    String result = apiInstance.mmsCampaignsByMmsCampaignIdPut(mmsCampaignId, campaign);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignsByMmsCampaignIdPut");
                    e.printStackTrace();
                }
              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var mmsCampaignId = 2277;


            var campaign = new api.MmsCampaign();


            campaign.listId = 185161;

            campaign.name = "My Campaign 1";

            campaign.body = "This is my new campaign message.";

            campaign.from = "+61353787448";

            campaign.subject = "subject";

            campaign.mediaFile =
            "https://thumbs.gfycat.com/BelatedComplexJerboa-small.gif";


            mmsCampaignApi.mmsCampaignsByMmsCampaignIdPut(mmsCampaignId,
            campaign).then(function(response) {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            mms_campaign_id = 56 # Integer | ID of MMS campaign to update

            # MmsCampaign | MmsCampaign model
            campaign = ClickSendClient::MmsCampaign.new(
              "schedule": 0,
              "list_id": 1234,
              "name": "name",
              "from": "from",
              "body": "body",
              "subject": "subject",
              "media_file": "media_file_url"
            )

            begin
              # Update mms campaign
              result = api_instance.mms_campaigns_by_mms_campaign_id_put(mms_campaign_id, campaign)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaigns_by_mms_campaign_id_put: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            mms_campaign_id = 1641 # int | ID of MMS campaign to update

            # MmsCampaign | MmsCampaign model

            campaign = clicksend_client.MmsCampaign(
                        list_id=185161,
                        name="My Campaign 1",
                        _from="+61353787448",
                        body="This is my new campaign message.",
                        schedule=1542884932,
                        subject="test",
                        media_file="http://yourdomain.com/tpLaX6A.gif")

            try:
                # Update mms campaign
                api_response = api_instance.mms_campaigns_by_mms_campaign_id_put(mms_campaign_id, campaign)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaigns_by_mms_campaign_id_put: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;

            use WWW::ClickSendClient::Object::MmsCampaign;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my %params = (
                'list_id'    => 'list_id',
                'name'       => 'name',
                'body'       => 'body',
                'from'       => 'from',
                'schedule'   => 'schedule',
                'subject'    => 'subject',
                'media_file' => 'media_file_url'
            );


            my $mms_obj =
            WWW::ClickSendClient::Object::MmsCampaign->new(%params);

            my $json_output =
            $api->mms_campaigns_by_mms_campaign_id_put('campaign' => $mms_obj
            ,'mms_campaign_id' => '12345' );


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaign *campaign = [[CSMmsCampaign alloc] init];

            campaign.listId = @(428);

            campaign.name = @"name";

            campaign.body = @"body";

            campaign.from = @"+61353787448";

            campaign.subject = @"subject";

            campaign.mediaFile = @"http://yourdomain.com/tpLaX6A.gif";


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi
            mmsCampaignsByMmsCampaignIdPutWithMmsCampaignId:@(428)
            campaign:campaign completionHandler:^(NSString *output, NSError
            *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire

            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {
                ClickSendClientAPI.customHeaders = [authHeader.key : authHeader.value]
            }


            let mmsCampaign = MmsCampaign(
                                listId: 428,
                                name: "name",
                                body: "body",
                                from: "+61353787448",
                                schedule: nil,
                                subject: "subject",
                                mediaFile: "http://yourdomain.com/tpLaX6A.gif"
                            )

            MmsCampaignAPI.mmsCampaignsByMmsCampaignIdPut(mmsCampaignId: 428,
            campaign: mmsCampaign) { (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                            print(error)
                        }
                    }
                }
            }
    get:
      summary: View MMS Campaign
      operationId: view-mms-campaign
      description: >-
        _Get specific mms campaign_


        ### Parameters


        | Parameter | In | Type | Required | Description |

        | --- | --- | --- | --- | --- |

        | mms_campaign_id | path | integer(int32) | true | ID of MMS campaign to
        retrieve |



        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.



        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
        - name: mms_campaign_id
          in: path
          schema:
            type: string
          required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/view-mms-campaign'
      x-codeSamples:
        - lang: curl
          source: |-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \

            'https://rest.clicksend.com/v3/mms-campaigns/{mms_campaign_id}'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $mms_campaign_id = 2492; // int | ID of MMS campaign to retrieve


            try {
                $result = $apiInstance->mmsCampaignByMmsCampaignIdGet($mms_campaign_id);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignByMmsCampaignIdGet: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: >-
            using IO.ClickSend.ClickSend.Api;

            using IO.ClickSend.Client;

            using IO.ClickSend.ClickSend.Model;


            var configuration = new Configuration()

            {
                Username = USERNAME,
                Password = API_KEY  
            };

            var mmsCampaignApi = new MmsCampaignApi(configuration);

            var response =
            mmsCampaignApi.MmsCampaignByMmsCampaignIdGet(CAMPAIGN_ID);
        - lang: Java
          source: |
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;

            public class view_specific_mms_campaign {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                Integer mmsCampaignId = 1910; // Integer | ID of MMS campaign to retrieve
                try {
                    String result = apiInstance.mmsCampaignByMmsCampaignIdGet(mmsCampaignId);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignByMmsCampaignIdGet");
                    e.printStackTrace();
                }
              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var mmsCampaignId = 1637;


            mmsCampaignApi.mmsCampaignByMmsCampaignIdGet(mmsCampaignId).then(function(response)
            {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            mms_campaign_id = 56 # Integer | ID of MMS campaign to retrieve

            begin
              # Get specific mms campaign
              result = api_instance.mms_campaign_by_mms_campaign_id_get(mms_campaign_id)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaign_by_mms_campaign_id_get: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            mms_campaign_id = 1637 # int | ID of MMS campaign to retrieve


            try:
                # Get specific mms campaign
                api_response = api_instance.mms_campaign_by_mms_campaign_id_get(mms_campaign_id)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaign_by_mms_campaign_id_get: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my $json_output = my $json_output =
            $api->mms_campaign_by_mms_campaign_id_get('mms_campaign_id'  =>
            '1234');


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi
            mmsCampaignByMmsCampaignIdGetWithMmsCampaignId:@(428)
            completionHandler:^(NSString *output, NSError *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire


            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {
                ClickSendClientAPI.customHeaders = [authHeader.key : authHeader.value]
            }


            MmsCampaignAPI.mmsCampaignByMmsCampaignIdGet(mmsCampaignId: 428) {
            (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                            print(error)
                        }
                    }
                }
            }
  /v3/mms-campaigns/{mms_campaign_id}/cancel:
    put:
      summary: Cancel MMS Campaign
      operationId: cancel-mms-campaign
      description: >-
        _Cancel mms campaign_


        ### Parameters


        | Parameter | In | Type | Required | Description |

        | --- | --- | --- | --- | --- |

        | mms_campaign_id | path | integer(int32) | true | ID of MMS Campaign to
        cancel |



        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.



        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                list_id:
                  type: string
                name:
                  type: string
                from:
                  type: string
                body:
                  type: string
              example:
                list_id: '{{listId}}'
                name: My Campaign
                from: '+61411111111'
                body: >-
                  Hey (First Name), I want to ask if this is your lastname:
                  (Last Name)?
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
        - name: mms_campaign_id
          in: path
          schema:
            type: string
          required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/cancel-mms-campaign'
      x-codeSamples:
        - lang: curl
          source: >-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \
                 --request PUT \

            'https://rest.clicksend.com/v3/mms-campaigns/{mms_campaign_id}/cancel'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $mms_campaign_id = 2491; // int | ID of MMS Campaign to cancel


            try {
                $result = $apiInstance->mmsCampaignsCancelByMmsCampaignIdPut($mms_campaign_id);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignsCancelByMmsCampaignIdPut: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: >-
            using IO.ClickSend.ClickSend.Api;

            using IO.ClickSend.Client;

            using IO.ClickSend.ClickSend.Model;


            var configuration = new Configuration()

            {
                Username = USERNAME,
                Password = API_KEY  
            };

            var mmsCampaignApi = new MmsCampaignApi(configuration);

            var response =
            mmsCampaignApi.MmsCampaignsCancelByMmsCampaignIdPut(CAMPAIGN_ID);
        - lang: Java
          source: |-
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;
            import ClickSend.Model.MmsCampaign;

            public class cancel_mms_campaign {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                Integer mmsCampaignId = 1846; // Integer | ID of MMS Campaign to cancel
                try {
                    String result = apiInstance.mmsCampaignsCancelByMmsCampaignIdPut(mmsCampaignId);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignsCancelByMmsCampaignIdPut");
                    e.printStackTrace();
                }
              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var mmsCampaignId = 2277;


            mmsCampaignApi.mmsCampaignsCancelByMmsCampaignIdPut(mmsCampaignId).then(function(response)
            {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            mms_campaign_id = 56 # Integer | ID of MMS Campaign to cancel

            begin
              # Cancel mms campaign
              result = api_instance.mms_campaigns_cancel_by_mms_campaign_id_put(mms_campaign_id)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaigns_cancel_by_mms_campaign_id_put: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            mms_campaign_id = 1642 # int | ID of MMS Campaign to cancel


            try:
                # Cancel mms campaign
                api_response = api_instance.mms_campaigns_cancel_by_mms_campaign_id_put(mms_campaign_id)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaigns_cancel_by_mms_campaign_id_put: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my %params = (
                'list_id'    => 'list_id',
                'name'       => 'name',
                'body'       => 'body',
                'from'       => 'from',
                'schedule'   => 'schedule',
                'subject'    => 'subject',
                'media_file' => 'media_file_url'
            );


            my $json_output =
            $api->mms_campaigns_cancel_by_mms_campaign_id_put('mms_campaign_id'
            => '12345' );


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi
            mmsCampaignsCancelByMmsCampaignIdPutWithMmsCampaignId:@(428)
            completionHandler:^(NSString *output, NSError *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire


            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {
                ClickSendClientAPI.customHeaders = [authHeader.key : authHeader.value]
            }


            let mmsCampaign = MmsCampaign(
                                listId: 428,
                                name: "name",
                                body: "body",
                                from: "+61353787448",
                                schedule: nil,
                                subject: "subject",
                                mediaFile: "http://yourdomain.com/tpLaX6A.gif"
                            )

            MmsCampaignAPI.mmsCampaignsCancelByMmsCampaignIdPut(mmsCampaignId:
            428) { (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                            print(error)
                        }
                    }
                }
            }
  /v3/mms-campaigns:
    get:
      summary: View All MMS Campaigns
      operationId: view-all-mms-campaigns
      description: >-
        _Get list of mms campaigns_


        ### Parameters


        | Parameter | In | Type | Required | Description |

        | --- | --- | --- | --- | --- |

        | page | query | integer(int32) | false | [Page number](/#pagination) |

        | limit | query | integer(int32) | false | [Number of records per
        page](/#pagination) |



        Refer to [Status Codes](/#status-codes) for definitions of HTTP status
        code responses.



        <div style="background-color: #FF6A4B; padding: 10px; border-radius:
        8px;">
          <span style="color: white;">This endpoint requires authentication,</span> 
          <a href="/#authentication" style="color: white; text-decoration: underline;">more info...</a>
        </div>
      security:
        - basicAuth: []
      parameters:
        - name: Content-Type
          in: header
          schema:
            type: string
          example: application/json
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/view-all-mms-campaigns'
      x-codeSamples:
        - lang: curl
          source: |-
            curl --include \
                 --header "Authorization: Basic YXBpLXVzZXJuYW1lOmFwaS1wYXNzd29yZA=="  \

            'https://rest.clicksend.com/v3/mms-campaigns'
        - lang: PHP
          source: >-
            <?php

            require_once(__DIR__ . '/vendor/autoload.php');


            // Configure HTTP basic authorization: BasicAuth

            $config = ClickSend\Configuration::getDefaultConfiguration()
                          ->setUsername('USERNAME')
                          ->setPassword('API_KEY');

            $apiInstance = new ClickSend\Api\MmsCampaignApi(new
            GuzzleHttp\Client(),$config);

            $page = 1; // int | Page number

            $limit = 10; // int | Number of records per page


            try {
                $result = $apiInstance->mmsCampaignsGet($page, $limit);
                print_r($result);
            } catch (Exception $e) {
                echo 'Exception when calling MmsCampaignApi->mmsCampaignsGet: ', $e->getMessage(), PHP_EOL;
            }

            ?>
        - lang: C#
          source: |-
            using IO.ClickSend.ClickSend.Api;
            using IO.ClickSend.Client;
            using IO.ClickSend.ClickSend.Model;

            var configuration = new Configuration()
            {
                Username = USERNAME,
                Password = API_KEY  
            };
            var mmsCampaignApi = new MmsCampaignApi(configuration);
            var response = mmsCampaignApi.MmsCampaignsGet();
        - lang: Java
          source: |-
            package ClickSend;

            import ClickSend.Api.MmsCampaignApi;

            public class view_all_mms_campaign {
              public static void main(String[] args) {
                ApiClient defaultClient = new ApiClient();
                defaultClient.setUsername("USERNAME");
                defaultClient.setPassword("API_KEY");
                MmsCampaignApi apiInstance = new MmsCampaignApi(defaultClient);
                Integer page = 1; // Integer | Page number
                Integer limit = 10; // Integer | Number of records per page
                try {
                    String result = apiInstance.mmsCampaignsGet(page, limit);
                    System.out.println(result);
                } catch (ApiException e) {
                    System.err.println("Exception when calling MmsCampaignApi#mmsCampaignsGet");
                    e.printStackTrace();
                }
              }
            }
        - lang: Node.js
          source: >-
            var api = require('./api.js');


            var mmsCampaignApi = new api.MmsCampaignApi("USERNAME", "API_KEY");


            var page = 1;

            var limit = 10;


            mmsCampaignApi.mmsCampaignsGet(page, limit).then(function(response)
            {
              console.log(response.body);
            }).catch(function(err){
              console.error(err.body);
            });
        - lang: Ruby
          source: |-
            # load the gem
            require 'clicksend_client'
            require 'json'

            # setup authorization
            ClickSendClient.configure do |config|
              # Configure HTTP basic authorization: BasicAuth
              config.username = 'USERNAME'
              config.password = 'API_KEY'
            end

            api_instance = ClickSendClient::MmsCampaignApi.new

            opts = {
              page: 1,  # Integer | Page number
              limit: 10 # Integer | Number of records per page
            }

            begin
              # Get list of mms campaigns
              result = api_instance.mms_campaigns_get(opts)
              p JSON.parse(result)
            rescue ClickSendClient::ApiError => e
              puts "Exception when calling MmsCampaignApi->mms_campaigns_get: #{e.response_body}"
            end
        - lang: Python
          source: >-
            from __future__ import print_function

            import clicksend_client

            from clicksend_client.rest import ApiException


            # Configure HTTP basic authorization: BasicAuth

            configuration = clicksend_client.Configuration()

            configuration.username = 'USERNAME'

            configuration.password = 'API_KEY'


            # create an instance of the API class

            api_instance =
            clicksend_client.MmsCampaignApi(clicksend_client.ApiClient(configuration))

            page = 1 # int | Page number (optional) (default to 1)

            limit = 10 # int | Number of records per page (optional) (default to
            10)


            try:
                # Get list of mms campaigns
                api_response = api_instance.mms_campaigns_get(page=page, limit=limit)
                print(api_response)
            except ApiException as e:
                print("Exception when calling MmsCampaignApi->mms_campaigns_get: %s\n" % e)
        - lang: perl
          source: >-
            use WWW::ClickSendClient::MmsCampaignApi;


            my $username = 'YOUR_API_USER_NAME';

            my $password = 'YOUR_API_PASSWORD';


            my $api = WWW::ClickSendClient::MmsCampaignApi->new(username =>
            $username, password => $password);


            my $json_output = $api->mms_campaigns_get('page'=> '1', 'limit' =>
            '10');


            print $json_output;
        - lang: objc
          source: >-
            #import "CSMmsCampaign.h"

            #import "CSDefaultConfiguration.h"


            CSDefaultConfiguration *apiConfig = [CSDefaultConfiguration
            sharedConfig];

            // Configure HTTP basic authorization (authentication scheme:
            BasicAuth)

            [apiConfig setUsername:@"USERNAME"];

            [apiConfig setPassword:@"PASSWORD"];


            CSMmsCampaignApi *mmsCampaignApi = [[CSMmsCampaignApi alloc] init];

            [mmsCampaignApi mmsCampaignsGetWithPage:@(1) limit:@(15)
            completionHandler:^(NSString *output, NSError *error) {
                if (error) {
                    NSLog(@"Error: %@", error);
                } else {
                    NSLog(@"%@", output);
                }
            }];
        - lang: swift
          source: >-
            import Alamofire

            if let authHeader = Request.authorizationHeader(user: "USERNAME",
            password: "PASSWORD") {
                ClickSendClientAPI.customHeaders = [authHeader.key : authHeader.value]
            }


            MmsCampaignAPI.mmsCampaignsGet { (dataString, error) in
                if let error = error {
                    print(error)
                } else {
                    if let data = dataString!.data(using: String.Encoding.utf8) {
                        do {
                            if let dictonary = try (JSONSerialization.jsonObject(with: data, options: []) as? NSDictionary) {
                                print(dictonary)
                            } else {
                                print("Cannot convert the String value to JSON")
                            }
                        } catch let error as NSError {
                        print(error)
                        }
                    }
                }
            }
