{
  "info": {
    "name": "GrabPenny API",
    "description": "GrabPenny API collection for creating and managing social media marketing campaigns. Get your API key from https://grabpenny.com/api-keys/",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "auth": {
    "type": "bearer",
    "bearer": [
      {
        "key": "token",
        "value": "{{api_key}}",
        "type": "string"
      }
    ]
  },
  "variable": [
    {
      "key": "base_url",
      "value": "https://grabpenny.com",
      "type": "string"
    },
    {
      "key": "api_key",
      "value": "YOUR_API_KEY_HERE",
      "type": "string"
    }
  ],
  "item": [
    {
      "name": "Authentication",
      "item": [
        {
          "name": "Validate API Key",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{base_url}}/api/v1/client/auth/me/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "auth",
                "me",
                ""
              ]
            },
            "description": "Validates your API key and returns account information including balance and API key details."
          }
        }
      ]
    },
    {
      "name": "Tasks",
      "item": [
        {
          "name": "List Available Tasks",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{base_url}}/api/v1/client/tasks/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "tasks",
                ""
              ]
            },
            "description": "Returns a list of available task types for creating campaigns. Each task includes platform, cost per engagement, and engagement limits."
          }
        }
      ]
    },
    {
      "name": "Campaigns",
      "item": [
        {
          "name": "Create Campaign",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"task_type_id\": 1,\n    \"name\": \"My Instagram Campaign\",\n    \"link\": \"https://instagram.com/myprofile\",\n    \"required_executions\": 100,\n    \"max_per_day\": 20,\n    \"gender\": -1\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/client/campaigns/create/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "campaigns",
                "create",
                ""
              ]
            },
            "description": "Creates a new campaign with the specified parameters.\n\nParameters:\n- task_type_id (required): ID of the task type from /tasks/ endpoint\n- name (required): Campaign name\n- link (required): URL to the social media profile/content\n- required_executions (required): Number of engagements required (min: 10)\n- max_per_day (optional): Maximum engagements per day (0 = unlimited)\n- gender (optional): Target gender: -1 (All), 0 (Male), 1 (Female)\n- misc_data (optional): Additional campaign data"
          }
        },
        {
          "name": "Create Instagram Follow Campaign",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"task_type_id\": 1,\n    \"name\": \"Instagram Followers Campaign\",\n    \"link\": \"https://instagram.com/myprofile\",\n    \"required_executions\": 500,\n    \"max_per_day\": 50,\n    \"gender\": -1\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/client/campaigns/create/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "campaigns",
                "create",
                ""
              ]
            },
            "description": "Example: Create an Instagram follow campaign"
          }
        },
        {
          "name": "Create YouTube Subscribe Campaign",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"task_type_id\": 2,\n    \"name\": \"YouTube Subscribers Campaign\",\n    \"link\": \"https://youtube.com/channel/mychannel\",\n    \"required_executions\": 1000,\n    \"max_per_day\": 100,\n    \"gender\": -1\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/client/campaigns/create/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "campaigns",
                "create",
                ""
              ]
            },
            "description": "Example: Create a YouTube subscribe campaign"
          }
        },
        {
          "name": "Create Female-Targeted Campaign",
          "request": {
            "method": "POST",
            "header": [
              {
                "key": "Content-Type",
                "value": "application/json"
              }
            ],
            "body": {
              "mode": "raw",
              "raw": "{\n    \"task_type_id\": 1,\n    \"name\": \"Female Audience Campaign\",\n    \"link\": \"https://instagram.com/fashionprofile\",\n    \"required_executions\": 200,\n    \"max_per_day\": 30,\n    \"gender\": 1,\n    \"misc_data\": {\n        \"notes\": \"Targeting female audience for fashion content\"\n    }\n}"
            },
            "url": {
              "raw": "{{base_url}}/api/v1/client/campaigns/create/",
              "host": [
                "{{base_url}}"
              ],
              "path": [
                "api",
                "v1",
                "client",
                "campaigns",
                "create",
                ""
              ]
            },
            "description": "Example: Create a campaign targeting female audience with custom data"
          }
        }
      ]
    }
  ]
}