---
updatedAt: 2025-09-23T21:00:22.000Z
agentTools:
  projectIndex: https://developers.berkeleypayment.com/llms.txt
---

# Create Collection

This API endpoint allows you to create a `Collection` payment in real-time.  


### Request 

| Field          | Required | Type              | Description | 
|----------------|------------|-----------|--------------------------|
| email          | yes | string | Customer email address   |
| first_name     | yes |  string  | Customer first name      |
| last_name      | yes | string  | Customer last name       |
| amount         | yes | integer  | Payment amount for collection in cents   |
| expiry        | no  | string  | Datetime formatted in RFC3339 |
| external_tag   | no | string            | User defined searchable tag              |
| currency       | yes  |  string  | 3 letter Currency Code                   |
| account_ref    | no |  string  | User defined account reference (used in payment portal and for reporting) |


### Response

| Field | Value | Description|
|----|----|----|
|id             | string | 
|status         | string | 
|first_name     | string | 
|last_name      | string | 
|amount         | integer | 
|currency       | string | 
|email          | string | 
|expiry         | string | 
|account_ref    | string | 
|external_tag   | string | 
|txn_id         | string | 
|txn_time       | string | 
|void_txn_id    | string | 
|void_txn_time  | string | 
|return_txn_id  | string | 
|return_txn_time| string | 
|created_at     | string |

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "Debt Collections",
    "description": "This set of API endpoints allow you to provide your Collections team the ability to receive payments on outstanding collections in real-time.",
    "version": "1.0.0",
    "contact": {}
  },
  "servers": [
    {
      "url": "https://api.staging.pungle.co/",
      "description": "Staging/Test"
    },
    {
      "url": "https://api.pungle.io",
      "description": "Production"
    }
  ],
  "paths": {
    "/api/v1/collections/requests": {
      "post": {
        "tags": [
          "Collections"
        ],
        "summary": "Create Collection",
        "description": "This API endpoint allows you to create a `Collection` payment in real-time.  \n\n\n### Request \n\n| Field          | Required | Type              | Description | \n|----------------|------------|-----------|--------------------------|\n| email          | yes | string | Customer email address   |\n| first_name     | yes |  string  | Customer first name      |\n| last_name      | yes | string  | Customer last name       |\n| amount         | yes | integer  | Payment amount for collection in cents   |\n| expiry        | no  | string  | Datetime formatted in RFC3339 |\n| external_tag   | no | string            | User defined searchable tag              |\n| currency       | yes  |  string  | 3 letter Currency Code                   |\n| account_ref    | no |  string  | User defined account reference (used in payment portal and for reporting) |\n\n\n### Response\n\n| Field | Value | Description|\n|----|----|----|\n|id             | string | \n|status         | string | \n|first_name     | string | \n|last_name      | string | \n|amount         | integer | \n|currency       | string | \n|email          | string | \n|expiry         | string | \n|account_ref    | string | \n|external_tag   | string | \n|txn_id         | string | \n|txn_time       | string | \n|void_txn_id    | string | \n|void_txn_time  | string | \n|return_txn_id  | string | \n|return_txn_time| string | \n|created_at     | string |",
        "operationId": "createCollection",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "amount": {
                    "type": "number",
                    "example": 100
                  },
                  "currency": {
                    "type": "string",
                    "example": "CAD"
                  },
                  "email": {
                    "type": "string",
                    "example": "test@berkeleypayment.com"
                  },
                  "expiry": {
                    "type": "string",
                    "example": "2021-08-27T20:08:58Z"
                  },
                  "first_name": {
                    "type": "string",
                    "example": "Ozzy"
                  },
                  "last_name": {
                    "type": "string",
                    "example": "Mandias"
                  }
                }
              },
              "example": {
                "amount": 100,
                "currency": "CAD",
                "email": "test@berkeleypayment.com",
                "expiry": "2021-08-27T20:08:58Z",
                "first_name": "Ozzy",
                "last_name": "Mandias"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Create Collection",
            "headers": {
              "Connection": {
                "schema": {
                  "type": "string",
                  "example": "keep-alive"
                }
              },
              "Content-Length": {
                "schema": {
                  "type": "string",
                  "example": "367"
                }
              },
              "Content-Security-Policy": {
                "schema": {
                  "type": "string",
                  "example": "default-src 'self'; script-src 'self' 'unsafe-inline' 'unsafe-eval' https://stackpath.bootstrapcdn.com https://code.jquery.com https://cdnjs.cloudflare.com; img-src 'self' https://*.dev.pungle.co https://*.staging.pungle.co https://images.pungle.io https://s3.amazonaws.com data:; style-src 'self' 'unsafe-inline' https://fonts.googleapis.com https://fonts.gstatic.com https://at.alicdn.com https://stackpath.bootstrapcdn.com https://code.jquery.com https://cdnjs.cloudflare.com; font-src 'self' https://themes.googleusercontent.com https://fonts.googleapis.com https://fonts.gstatic.com https://at.alicdn.com; object-src 'none'"
                }
              },
              "Date": {
                "schema": {
                  "type": "string",
                  "example": "Wed, 24 Jun 2020 17:55:08 GMT"
                }
              },
              "Referrer-Policy": {
                "schema": {
                  "type": "string",
                  "example": "same-origin"
                }
              },
              "Set-Cookie": {
                "schema": {
                  "type": "string",
                  "example": "HttpOnly; Secure;"
                }
              },
              "Strict-Transport-Security": {
                "schema": {
                  "type": "string",
                  "example": "max-age=63072000; includeSubdomains; preload"
                }
              },
              "Via": {
                "schema": {
                  "type": "string",
                  "example": "1.1 48d93733622a65c33a44fdfefe00cf31.cloudfront.net (CloudFront)"
                }
              },
              "X-Amz-Cf-Id": {
                "schema": {
                  "type": "string",
                  "example": "KxW-lrscUolyGjOHDBReWebm_VRJVGBfFYP8xRbGYkMukWZAVIEcaQ=="
                }
              },
              "X-Amz-Cf-Pop": {
                "schema": {
                  "type": "string",
                  "example": "YTO50-C1"
                }
              },
              "X-Cache": {
                "schema": {
                  "type": "string",
                  "example": "Miss from cloudfront"
                }
              },
              "X-Content-Type-Options": {
                "schema": {
                  "type": "string",
                  "example": "nosniff"
                }
              },
              "X-Frame-Options": {
                "schema": {
                  "type": "string",
                  "example": "SAMEORIGIN"
                }
              },
              "X-XSS-Protection": {
                "schema": {
                  "type": "string",
                  "example": "1; mode=block"
                }
              },
              "cache-control": {
                "schema": {
                  "type": "string",
                  "example": "max-age=0, private, must-revalidate, no-store, no-cache"
                }
              },
              "cross-origin-window-policy": {
                "schema": {
                  "type": "string",
                  "example": "deny"
                }
              },
              "pragma": {
                "schema": {
                  "type": "string",
                  "example": "no-cache"
                }
              },
              "server": {
                "schema": {
                  "type": "string",
                  "example": "Cowboy"
                }
              },
              "x-download-options": {
                "schema": {
                  "type": "string",
                  "example": "noopen"
                }
              },
              "x-permitted-cross-domain-policies": {
                "schema": {
                  "type": "string",
                  "example": "none"
                }
              },
              "x-request-id": {
                "schema": {
                  "type": "string",
                  "example": "FhuMcHenmXYdSoAAATkR"
                }
              }
            },
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "account_ref": {
                          "nullable": true,
                          "example": null
                        },
                        "amount": {
                          "type": "number",
                          "example": 100
                        },
                        "created_at": {
                          "type": "string",
                          "example": "2020-06-24T17:55:07Z"
                        },
                        "currency": {
                          "type": "string",
                          "example": "CAD"
                        },
                        "email": {
                          "type": "string",
                          "example": "test@berkeleypayment.com"
                        },
                        "expiry": {
                          "type": "string",
                          "example": "2020-06-29T17:55:07Z"
                        },
                        "external_tag": {
                          "nullable": true,
                          "example": null
                        },
                        "first_name": {
                          "type": "string",
                          "example": "Ozzy"
                        },
                        "id": {
                          "type": "number",
                          "example": 9
                        },
                        "last_name": {
                          "type": "string",
                          "example": "Mandias"
                        },
                        "return_txn_id": {
                          "nullable": true,
                          "example": null
                        },
                        "return_txn_time": {
                          "nullable": true,
                          "example": null
                        },
                        "status": {
                          "type": "string",
                          "example": "email_sent"
                        },
                        "txn_id": {
                          "nullable": true,
                          "example": null
                        },
                        "txn_time": {
                          "nullable": true,
                          "example": null
                        },
                        "void_txn_id": {
                          "nullable": true,
                          "example": null
                        },
                        "void_txn_time": {
                          "nullable": true,
                          "example": null
                        }
                      }
                    }
                  }
                },
                "examples": {
                  "Create Collection": {
                    "value": {
                      "data": {
                        "account_ref": null,
                        "amount": 100,
                        "created_at": "2020-06-24T17:55:07Z",
                        "currency": "CAD",
                        "email": "test@berkeleypayment.com",
                        "expiry": "2020-06-29T17:55:07Z",
                        "external_tag": null,
                        "first_name": "Ozzy",
                        "id": 9,
                        "last_name": "Mandias",
                        "return_txn_id": null,
                        "return_txn_time": null,
                        "status": "email_sent",
                        "txn_id": null,
                        "txn_time": null,
                        "void_txn_id": null,
                        "void_txn_time": null
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true,
    "samples-enabled": true
  }
}
```