---
title: POST SavedCard (cloned)
slug: post-savedcard-cloned
icon: 🟩
createdAt: 2022-03-23T01:57:46.000Z
---

**Important notes:**

- `patientId`  is the field needed to tie the Patient in FeatherPay DB to the PMS Patient.  This ID represents FeatherPay's ID for that patient.  This is returned when creating / updating a patient via FeatherPay API.

:::ApiMethodV2
```json
{
  "tab": "examples",
  "url": "https://gfp-api.acdev.io/api/v1/savedpayments/card",
  "name": "Create / Update patient",
  "method": "POST",
  "request": {
    "pathParameters": [],
    "queryParameters": [],
    "headerParameters": [],
    "bodyDataParameters": [
      {
        "kind": "required",
        "name": "patientId",
        "type": "string",
        "children": [],
        "description": "FeatherPay Patient ID"
      },
      {
        "kind": "required",
        "name": "ephemerialToken",
        "type": "string",
        "children": [],
        "description": "Encrypted token generated by JS Library"
      },
      {
        "kind": "required",
        "name": "expiry",
        "type": "string",
        "children": [],
        "description": "Expiry Date of Credit Card"
      },
      {
        "kind": "required",
        "name": "postal",
        "type": "string",
        "children": [],
        "description": "Postal Code of Credit Card"
      },
      {
        "kind": "optional",
        "name": "cardType",
        "type": "string",
        "children": [],
        "description": "e.g. Visa, American Express, etc.  Use JS Library to retrieve this data."
      }
    ],
    "formDataParameters": []
  },
  "results": {
    "languages": [
      {
        "id": "c0f7bjPcqHaJiKYiBqEF0",
        "code": "{\n  \"savedPaymentId\":\"01GQSVMZH59XSSXFXKNBZNW6PY\"\n}\n",
        "language": "200",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "c0f7bjPcqHaJiKYiBqEF0"
  },
  "examples": {
    "languages": [
      {
        "id": "TsJH4BARuElrAzdNuPV8E",
        "code": "curl -X POST \\\n  --url 'https://gfp-api.acdev.io/api/v1/patients/' \\\n  --header 'content-type: application/json;charset=UTF-8' \\\n  --header 'accept: application/json' \\\n  --header 'X-Api-Key: {Secret API Key}' \\\n  --header 'X-Store-Id: {Store ULID}' \\\n  --data-raw '\n  {\n    \"patientId\": \"307\",\n    \"ephemeralToken\": \"<token from JS Library>\",\n    \"expiry\": \"04/27\",\n    \"postal\": \"30030\",\n    \"cardType\": \"Visa\"\n  }'",
        "language": "json",
        "customLabel": ""
      }
    ],
    "selectedLanguageId": "TsJH4BARuElrAzdNuPV8E"
  },
  "description": "From your backend code, create / update the patient with your store id and private key.",
  "currentNewParameter": {
    "label": "Body Parameter",
    "value": "bodyDataParameters"
  }
}
```
:::



