Campaign Folders

Organize your campaigns using folders.

Available methods

    • POST /campaign-folders Create campaign folder

      Create campaign folder

      POST /campaign-folders

      Create a new campaign folder.

      Request body parameters

      name Type: String Title: Folder Name Read only: false Name to associate with the folder.

      Response body parameters

      name Type: String Title: Folder Name Read only: false The name of the folder.
      id Type: String Title: Folder Id Read only: true A string that uniquely identifies this campaign folder.
      count Type: Integer Title: Campaign Count Read only: true The number of campaigns in the folder.
      _links Type: Array Title: Links Read only: true A list of link types and descriptions for the API schema documents.
      Show properties
      rel Type: String Title: Rel Read only: true As with an HTML ‘rel’ attribute, this describes the type of link.
      href Type: String Title: Href Read only: true This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
      method Type: String Title: Method Read only: true The HTTP method that should be used when accessing the URL defined in ‘href’.
      Possible Values:
      • GET
      • POST
      • PUT
      • PATCH
      • DELETE
      • OPTIONS
      • HEAD
      targetSchema Type: String Title: Target Schema Read only: true For GETs, this is a URL representing the schema that the response should conform to.
      schema Type: String Title: Schema Read only: true For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.

      Example request

      
      curl --request POST \
      --url 'https://usX.api.mailchimp.com/3.0/campaign-folders' \
      --user 'anystring:apikey' \
      --header 'content-type: application/json' \
      --data '{"name": "The name of the folder"}' \
      --include
                                      

      Example response

      
      HTTP/1.1 200 OK
      Server: nginx
      Content-Type: application/json; charset=utf-8
      Content-Length: 1112
      Vary: Accept-Encoding
      X-Request-Id: e26015f7-91b4-4178-bcaf-821699e9c9d1
      Link: <https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json>; rel="describedBy"
      Date: Mon, 30 Nov 2015 14:46:36 GMT
      Connection: keep-alive
      
      {
        "id": "8888969b77",
        "name": "The name of the folder",
        "count": 0,
        "_links": [
          {
            "rel": "parent",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
            "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
          },
          {
            "rel": "self",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/8888969b77",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "update",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/8888969b77",
            "method": "PATCH",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "delete",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/8888969b77",
            "method": "DELETE",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "campaigns",
            "href": "https://usX.api.mailchimp.com/3.0/campaigns?folder_id=8888969b77",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/Campaigns/Collection.json"
          }
        ]
      }
                                      

      Error response

      type Type: String Title: Problem Type Read only: false An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
      title Type: String Title: Error Title Read only: false A short, human-readable summary of the problem type. It shouldn’t change based on the occurrence of the problem, except for purposes of localization.
      status Type: Integer Title: HTTP Status Code Read only: false The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
      detail Type: String Title: Error Message Read only: false A human-readable explanation specific to this occurrence of the problem. Learn more about errors.
      instance Type: String Title: Instance ID Read only: false A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.
    • GET /campaign-folders Get all campaign folders
      GET /campaign-folders/{folder_id} Get a specific campaign folder

      Get all campaign folders

      GET /campaign-folders

      Get all folders used to organize campaigns.

      Query string parameters

      fields Type: Array Title: Fields Read only: false A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
      exclude_fields Type: Array Title: Exclude Fields Read only: false A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
      count Type: Integer Title: Count Read only: true The number of records to return. Default value is 10.
      offset Type: Integer Title: Offset Read only: false The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. Default value is 0.

      Response body parameters

      folders Type: Array Title: Campaign Folders Read only: false An array of objects representing campaign folders.
      Show properties
      name Type: String Title: Folder Name Read only: false The name of the folder.
      id Type: String Title: Folder Id Read only: true A string that uniquely identifies this campaign folder.
      count Type: Integer Title: Campaign Count Read only: true The number of campaigns in the folder.
      _links Type: Array Title: Links Read only: true A list of link types and descriptions for the API schema documents.
      Show properties
      rel Type: String Title: Rel Read only: true As with an HTML ‘rel’ attribute, this describes the type of link.
      href Type: String Title: Href Read only: true This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
      method Type: String Title: Method Read only: true The HTTP method that should be used when accessing the URL defined in ‘href’.
      Possible Values:
      • GET
      • POST
      • PUT
      • PATCH
      • DELETE
      • OPTIONS
      • HEAD
      targetSchema Type: String Title: Target Schema Read only: true For GETs, this is a URL representing the schema that the response should conform to.
      schema Type: String Title: Schema Read only: true For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.
      total_items Type: Integer Title: Item Count Read only: false The total number of items matching the query regardless of pagination.
      _links Type: Array Title: Links Read only: true A list of link types and descriptions for the API schema documents.
      Show properties
      rel Type: String Title: Rel Read only: true As with an HTML ‘rel’ attribute, this describes the type of link.
      href Type: String Title: Href Read only: true This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
      method Type: String Title: Method Read only: true The HTTP method that should be used when accessing the URL defined in ‘href’.
      Possible Values:
      • GET
      • POST
      • PUT
      • PATCH
      • DELETE
      • OPTIONS
      • HEAD
      targetSchema Type: String Title: Target Schema Read only: true For GETs, this is a URL representing the schema that the response should conform to.
      schema Type: String Title: Schema Read only: true For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.

      Example request

      
      curl --request GET \
      --url 'https://usX.api.mailchimp.com/3.0/campaign-folders' \
      --user 'anystring:apikey' \
      --include
                                      

      Example response

      
      HTTP/1.1 200 OK
      Server: nginx
      Content-Type: application/json; charset=utf-8
      Vary: Accept-Encoding
      X-Request-Id: c2431d0c-640f-4e7e-b5da-12101270ab82
      Link: <https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json>; rel="describedBy"
      Content-Length: 11707
      Date: Fri, 20 Nov 2015 21:47:16 GMT
      Connection: keep-alive
      
      {
        "folders": [
          {
            "id": "67d0d46c87",
            "name": "Purchases",
            "count": 0,
            "_links": [
              {
                "rel": "parent",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
                "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
              },
              {
                "rel": "self",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "update",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
                "method": "PATCH",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "delete",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
                "method": "DELETE",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "campaigns",
                "href": "https://usX.api.mailchimp.com/3.0/campaigns?folder_id=67d0d46c87",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/Campaigns/Collection.json"
              }
            ]
          },
          {
            "id": "d660e9e882",
            "name": "Product Announcements",
            "count": 0,
            "_links": [
              {
                "rel": "parent",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
                "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
              },
              {
                "rel": "self",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/d660e9e882",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "update",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/d660e9e882",
                "method": "PATCH",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "delete",
                "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/d660e9e882",
                "method": "DELETE",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
              },
              {
                "rel": "campaigns",
                "href": "https://usX.api.mailchimp.com/3.0/campaigns?folder_id=d660e9e882",
                "method": "GET",
                "targetSchema": "https://api.mailchimp.com/schema/3.0/Campaigns/Collection.json"
              }
            ]
          }
        ],
        "total_items": 2,
        "_links": [
          {
            "rel": "parent",
            "href": "https://usX.api.mailchimp.com/3.0/",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/Root.json"
          },
          {
            "rel": "self",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
            "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
          },
          {
            "rel": "create",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
            "method": "POST",
            "schema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          }
        ]
      }
                                      

      Error response

      type Type: String Title: Problem Type Read only: false An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
      title Type: String Title: Error Title Read only: false A short, human-readable summary of the problem type. It shouldn’t change based on the occurrence of the problem, except for purposes of localization.
      status Type: Integer Title: HTTP Status Code Read only: false The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
      detail Type: String Title: Error Message Read only: false A human-readable explanation specific to this occurrence of the problem. Learn more about errors.
      instance Type: String Title: Instance ID Read only: false A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.

      Get a specific campaign folder

      GET /campaign-folders/{folder_id}

      Get information about a specific folder used to organize campaigns.

      Path parameters

      folder_id The unique id for the campaign folder.

      Query string parameters

      fields Type: Array Title: Fields Read only: false A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
      exclude_fields Type: Array Title: Exclude Fields Read only: false A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.

      Response body parameters

      name Type: String Title: Folder Name Read only: false The name of the folder.
      id Type: String Title: Folder Id Read only: true A string that uniquely identifies this campaign folder.
      count Type: Integer Title: Campaign Count Read only: true The number of campaigns in the folder.
      _links Type: Array Title: Links Read only: true A list of link types and descriptions for the API schema documents.
      Show properties
      rel Type: String Title: Rel Read only: true As with an HTML ‘rel’ attribute, this describes the type of link.
      href Type: String Title: Href Read only: true This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
      method Type: String Title: Method Read only: true The HTTP method that should be used when accessing the URL defined in ‘href’.
      Possible Values:
      • GET
      • POST
      • PUT
      • PATCH
      • DELETE
      • OPTIONS
      • HEAD
      targetSchema Type: String Title: Target Schema Read only: true For GETs, this is a URL representing the schema that the response should conform to.
      schema Type: String Title: Schema Read only: true For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.

      Example request

      
      curl --request GET \
      --url 'https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87' \
      --user 'anystring:apikey' \
      --include
                                      

      Example response

      
      HTTP/1.1 200 OK
      Server: nginx
      Content-Type: application/json; charset=utf-8
      Content-Length: 1098
      Vary: Accept-Encoding
      X-Request-Id: a3a90fc3-d0de-4049-8220-5accc9c71692
      Link: <https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json>; rel="describedBy"
      Date: Fri, 20 Nov 2015 21:53:03 GMT
      Connection: keep-alive
      
      {
        "id": "67d0d46c87",
        "name": "Purchases",
        "count": 0,
        "_links": [
          {
            "rel": "parent",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
            "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
          },
          {
            "rel": "self",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "update",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "PATCH",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "delete",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "DELETE",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "campaigns",
            "href": "https://usX.api.mailchimp.com/3.0/campaigns?folder_id=67d0d46c87",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/Campaigns/Collection.json"
          }
        ]
      }
                                      

      Error response

      type Type: String Title: Problem Type Read only: false An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
      title Type: String Title: Error Title Read only: false A short, human-readable summary of the problem type. It shouldn’t change based on the occurrence of the problem, except for purposes of localization.
      status Type: Integer Title: HTTP Status Code Read only: false The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
      detail Type: String Title: Error Message Read only: false A human-readable explanation specific to this occurrence of the problem. Learn more about errors.
      instance Type: String Title: Instance ID Read only: false A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.
    • PATCH /campaign-folders/{folder_id} Update a campaign folder

      Update a campaign folder

      PATCH /campaign-folders/{folder_id}

      Update a specific folder used to organize campaigns.

      Path parameters

      folder_id The unique id for the campaign folder.

      Request body parameters

      name Type: String Title: Folder Name Read only: false Name to associate with the folder.

      Response body parameters

      name Type: String Title: Folder Name Read only: false The name of the folder.
      id Type: String Title: Folder Id Read only: true A string that uniquely identifies this campaign folder.
      count Type: Integer Title: Campaign Count Read only: true The number of campaigns in the folder.
      _links Type: Array Title: Links Read only: true A list of link types and descriptions for the API schema documents.
      Show properties
      rel Type: String Title: Rel Read only: true As with an HTML ‘rel’ attribute, this describes the type of link.
      href Type: String Title: Href Read only: true This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
      method Type: String Title: Method Read only: true The HTTP method that should be used when accessing the URL defined in ‘href’.
      Possible Values:
      • GET
      • POST
      • PUT
      • PATCH
      • DELETE
      • OPTIONS
      • HEAD
      targetSchema Type: String Title: Target Schema Read only: true For GETs, this is a URL representing the schema that the response should conform to.
      schema Type: String Title: Schema Read only: true For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.

      Example request

      
      curl --request GET \
      --url 'https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87' \
      --user 'anystring:apikey' \
      --header 'content-type: application/json' \
      --data '{"name": "The updated name of the folder"}' \
      --include
                                      

      Example response

      
      HTTP/1.1 200 OK
      Server: nginx
      Content-Type: application/json; charset=utf-8
      Content-Length: 1098
      Vary: Accept-Encoding
      X-Request-Id: 8f679758-57f3-4c65-8fdb-2f7c17ee9406
      Link: <https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json>; rel="describedBy"
      Date: Fri, 20 Nov 2015 21:54:56 GMT
      Connection: keep-alive
      
      {
        "id": "67d0d46c87",
        "name": "The updated name of the folder",
        "count": 0,
        "_links": [
          {
            "rel": "parent",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Collection.json",
            "schema": "https://api.mailchimp.com/schema/3.0/CollectionLinks/CampaignFolders.json"
          },
          {
            "rel": "self",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "update",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "PATCH",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "delete",
            "href": "https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87",
            "method": "DELETE",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/CampaignFolders/Instance.json"
          },
          {
            "rel": "campaigns",
            "href": "https://usX.api.mailchimp.com/3.0/campaigns?folder_id=67d0d46c87",
            "method": "GET",
            "targetSchema": "https://api.mailchimp.com/schema/3.0/Campaigns/Collection.json"
          }
        ]
      }
                                      

      Error response

      type Type: String Title: Problem Type Read only: false An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
      title Type: String Title: Error Title Read only: false A short, human-readable summary of the problem type. It shouldn’t change based on the occurrence of the problem, except for purposes of localization.
      status Type: Integer Title: HTTP Status Code Read only: false The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
      detail Type: String Title: Error Message Read only: false A human-readable explanation specific to this occurrence of the problem. Learn more about errors.
      instance Type: String Title: Instance ID Read only: false A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.
    • Delete a campaign folder

      DELETE /campaign-folders/{folder_id}

      Delete a specific campaign folder, and mark all the campaigns in the folder as ‘unfiled’.

      Path parameters

      folder_id The unique id for the campaign folder.

      Example request

      
      curl --request DELETE \
      --url 'https://usX.api.mailchimp.com/3.0/campaign-folders/67d0d46c87' \
      --user 'anystring:apikey' \
      --include
                                      

      Example response

      
      HTTP/1.1 204 No Content
      Server: nginx
      Content-Type: application/json; charset=utf-8
      Content-Length: 2
      X-Request-Id: ef3332c5-d70f-4bbb-8b5d-5546c742879d
      Date: Fri, 20 Nov 2015 21:59:20 GMT
      Connection: keep-alive
                                      

      Error response

      type Type: String Title: Problem Type Read only: false An absolute URI that identifies the problem type. When dereferenced, it should provide human-readable documentation for the problem type.
      title Type: String Title: Error Title Read only: false A short, human-readable summary of the problem type. It shouldn’t change based on the occurrence of the problem, except for purposes of localization.
      status Type: Integer Title: HTTP Status Code Read only: false The HTTP status code (RFC2616, Section 6) generated by the origin server for this occurrence of the problem.
      detail Type: String Title: Error Message Read only: false A human-readable explanation specific to this occurrence of the problem. Learn more about errors.
      instance Type: String Title: Instance ID Read only: false A string that identifies this specific occurrence of the problem. Please provide this ID when contacting support.