{
  "openapi": "3.0.0",
  "info": {
    "x-metadata": {
      "apiId": [
        "Class Partner v1"
      ],
      "tags": [
        "Class Partner"
      ]
    },
    "title": "Beneficiary Data",
    "version": "1.0",
    "description": "The Beneficiary Data provides endpoints for managing beneficiary information within a Fund.\n\n\n<div class=\"env-panel\" data-component-name=\"EnvPanel\"><div class=\"env-panel__header\">Servers</div><div class=\"env-panel__body\"><div class=\"env-row\"><div class=\"env-name\">Partner Integration Environment (Sandbox)</div><div class=\"env-url-row\"><span class=\"env-url\">https://apigateway.class-pie.com.au/api/1.0</span><button type=\"button\" class=\"copy-btn\" data-copy=\"https://apigateway.class-pie.com.au/api/1.0\" aria-label=\"Copy\"><svg viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" aria-hidden=\"true\"><path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M5.16667 2.66667C5.16667 2.57462 5.24129 2.5 5.33333 2.5H12C12.092 2.5 12.1667 2.57462 12.1667 2.66667V10.6667C12.1667 10.7587 12.092 10.8333 12 10.8333H10H5.33333C5.24129 10.8333 5.16667 10.7587 5.16667 10.6667V4.66667V2.66667ZM4.16667 4.16667V2.66667C4.16667 2.02233 4.689 1.5 5.33333 1.5H12C12.6443 1.5 13.1667 2.02233 13.1667 2.66667V10.6667C13.1667 11.311 12.6443 11.8333 12 11.8333H10.5V13.3333C10.5 13.6428 10.3771 13.9395 10.1583 14.1583C9.9395 14.3771 9.64275 14.5 9.33333 14.5H2.66667C2.35725 14.5 2.0605 14.3771 1.84171 14.1583C1.62292 13.9395 1.5 13.6428 1.5 13.3333V5.33333C1.5 5.02391 1.62292 4.72717 1.84171 4.50838C2.0605 4.28958 2.35725 4.16667 2.66667 4.16667H4.16667ZM9.5 11.8333V13.3333C9.5 13.3775 9.48244 13.4199 9.45118 13.4512C9.41993 13.4824 9.37754 13.5 9.33333 13.5H2.66667C2.62246 13.5 2.58007 13.4824 2.54882 13.4512C2.51756 13.4199 2.5 13.3775 2.5 13.3333V5.33333C2.5 5.28913 2.51756 5.24674 2.54882 5.21548C2.58007 5.18423 2.62246 5.16667 2.66667 5.16667H4.16667V10.6667C4.16667 11.311 4.689 11.8333 5.33333 11.8333H9.5Z\" fill=\"currentColor\"/></svg></button></div></div><div class=\"env-row\"><div class=\"env-name\">Production Environment</div><div class=\"env-url-row\"><span class=\"env-url\">https://apigateway.class.com.au/api/1.0</span><button type=\"button\" class=\"copy-btn\" data-copy=\"https://apigateway.class.com.au/api/1.0\" aria-label=\"Copy\"><svg viewBox=\"0 0 16 16\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\" aria-hidden=\"true\"><path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M5.16667 2.66667C5.16667 2.57462 5.24129 2.5 5.33333 2.5H12C12.092 2.5 12.1667 2.57462 12.1667 2.66667V10.6667C12.1667 10.7587 12.092 10.8333 12 10.8333H10H5.33333C5.24129 10.8333 5.16667 10.7587 5.16667 10.6667V4.66667V2.66667ZM4.16667 4.16667V2.66667C4.16667 2.02233 4.689 1.5 5.33333 1.5H12C12.6443 1.5 13.1667 2.02233 13.1667 2.66667V10.6667C13.1667 11.311 12.6443 11.8333 12 11.8333H10.5V13.3333C10.5 13.6428 10.3771 13.9395 10.1583 14.1583C9.9395 14.3771 9.64275 14.5 9.33333 14.5H2.66667C2.35725 14.5 2.0605 14.3771 1.84171 14.1583C1.62292 13.9395 1.5 13.6428 1.5 13.3333V5.33333C1.5 5.02391 1.62292 4.72717 1.84171 4.50838C2.0605 4.28958 2.35725 4.16667 2.66667 4.16667H4.16667ZM9.5 11.8333V13.3333C9.5 13.3775 9.48244 13.4199 9.45118 13.4512C9.41993 13.4824 9.37754 13.5 9.33333 13.5H2.66667C2.62246 13.5 2.58007 13.4824 2.54882 13.4512C2.51756 13.4199 2.5 13.3775 2.5 13.3333V5.33333C2.5 5.28913 2.51756 5.24674 2.54882 5.21548C2.58007 5.18423 2.62246 5.16667 2.66667 5.16667H4.16667V10.6667C4.16667 11.311 4.689 11.8333 5.33333 11.8333H9.5Z\" fill=\"currentColor\"/></svg></button></div></div></div></div>"
  },
  "servers": [
    {
      "url": "https://apigateway.class-pie.com.au/api/1.0",
      "description": "Partner Integration Environment (Sandbox)"
    },
    {
      "url": "https://apigateway.class.com.au/api/1.0",
      "description": "Production Environment"
    }
  ],
  "paths": {
    "/f/{businessCode}/{fundCode}/beneficiary-data/list-beneficiary-accounts": {
      "get": {
        "operationId": "listBeneficiaryAccounts",
        "summary": "Beneficiary accounts",
        "description": "Retrieves a list of all beneficiary accounts in the Fund including account balance, type, status, and associated beneficiary information.",
        "parameters": [
          {
            "$ref": "#/components/parameters/businessCodeParam"
          },
          {
            "$ref": "#/components/parameters/fundCodeParam"
          }
        ],
        "responses": {
          "200": {
            "description": "Success (Ok)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "Data"
                  ],
                  "properties": {
                    "Data": {
                      "$ref": "#/components/schemas/BeneficiaryData_BeneficiaryAccount"
                    },
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Error Message",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/UnauthorizedErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ForbiddenErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "Resource not available or user does not have access to the fund",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ResourceUnavailableErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "default": {
            "description": "Unexpected error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Class_oAuth": [
              "fund.read"
            ]
          }
        ]
      }
    },
    "/f/{businessCode}/{fundCode}/beneficiary-data/beneficiary-detail/{id}": {
      "get": {
        "operationId": "getBeneficiaryDetail",
        "summary": "Beneficiary detail",
        "description": "Retrieves the complete details of a specific beneficiary including personal information, contact details, tax file number, and organisation details if applicable.",
        "parameters": [
          {
            "$ref": "#/components/parameters/businessCodeParam"
          },
          {
            "$ref": "#/components/parameters/fundCodeParam"
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "A globally unique identifier (GUID) in standard UUID format to identify the beneficiary",
            "schema": {
              "example": "550e8400-e29b-41d4-a716-446655440000"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success (Ok)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "Data"
                  ],
                  "properties": {
                    "Data": {
                      "$ref": "#/components/schemas/BeneficiaryDetailResponse"
                    },
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Error Message",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/UnauthorizedErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ForbiddenErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "Resource not available or user does not have access to the fund",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ResourceUnavailableErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "default": {
            "description": "Unexpected error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Class_oAuth": [
              "fund.member.read"
            ]
          }
        ]
      },
      "post": {
        "operationId": "postBeneficiaryDetail",
        "summary": "Update beneficiary detail",
        "description": "Updates the details of a specific beneficiary including personal information, contact details, and organisation details.",
        "parameters": [
          {
            "$ref": "#/components/parameters/businessCodeParam"
          },
          {
            "$ref": "#/components/parameters/fundCodeParam"
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "description": "A globally unique identifier (GUID) in standard UUID format to identify the beneficiary",
            "schema": {
              "example": "550e8400-e29b-41d4-a716-446655440000"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Success (Ok)",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/StandardApiResponse"
                }
              }
            }
          },
          "400": {
            "description": "Error Message",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/UnauthorizedErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ForbiddenErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "Resource not available or user does not have access to the fund",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ResourceUnavailableErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "default": {
            "description": "Unexpected error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateBeneficiaryDetail"
              }
            }
          }
        },
        "security": [
          {
            "Class_oAuth": [
              "fund.member.maintain"
            ]
          }
        ]
      }
    },
    "/f/{businessCode}/{fundCode}/beneficiary-data/list-beneficiaries": {
      "get": {
        "operationId": "beneficiaryList",
        "summary": "Beneficiary list",
        "description": "Retrieves a summarised list of all beneficiaries in the Fund including their status, display name, and member number.",
        "parameters": [
          {
            "$ref": "#/components/parameters/businessCodeParam"
          },
          {
            "$ref": "#/components/parameters/fundCodeParam"
          }
        ],
        "responses": {
          "200": {
            "description": "Success (Ok)",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "Data"
                  ],
                  "properties": {
                    "Data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/BeneficiaryData_BeneficiarySummaryList"
                      }
                    },
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Error Message",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ErrorResponse"
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/UnauthorizedErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ForbiddenErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "404": {
            "description": "Resource not available or user does not have access to the fund",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ResourceUnavailableErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          },
          "default": {
            "description": "Unexpected error",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "Errors": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/InternalErrorCommon"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "Class_oAuth": [
              "fund.member.read"
            ]
          }
        ]
      }
    }
  },
  "components": {
    "schemas": {
      "ApiError": {
        "type": "object",
        "required": [
          "Code",
          "Message"
        ],
        "properties": {
          "Code": {
            "type": "string"
          },
          "Message": {
            "type": "string"
          }
        }
      },
      "ApiResponseBase": {
        "type": "object",
        "required": [
          "ErrorCodes",
          "Errors",
          "CreatedUri",
          "IsCreatedResponse"
        ],
        "properties": {
          "ErrorCodes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "Errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ApiError"
            }
          },
          "CreatedUri": {
            "type": "string"
          },
          "IsCreatedResponse": {
            "type": "boolean"
          }
        }
      },
      "ApiRestLink": {
        "type": "object",
        "required": [
          "Id",
          "Url"
        ],
        "properties": {
          "Id": {
            "type": "string"
          },
          "Url": {
            "type": "string"
          }
        }
      },
      "Api_RequestId": {
        "type": "object",
        "required": [
          "id"
        ],
        "properties": {
          "id": {
            "$ref": "#/components/schemas/guid"
          }
        }
      },
      "BeneficiaryData_BeneficiarySummaryList": {
        "type": "object",
        "description": "A list of beneficiary summaries for an Fund",
        "required": [
          "BeneficiarySummaries"
        ],
        "properties": {
          "BeneficiarySummaries": {
            "type": "array",
            "description": "Collection of beneficiary summary records",
            "items": {
              "$ref": "#/components/schemas/BeneficiaryData_BeneficiarySummary"
            }
          }
        }
      },
      "BeneficiaryData_BeneficiarySummary": {
        "type": "object",
        "description": "Summary information for a beneficiary in an Fund",
        "required": [
          "Link",
          "Status",
          "DefaulDisplayName",
          "BeneficiaryNumber"
        ],
        "properties": {
          "Link": {
            "$ref": "#/components/schemas/ApiRestLink",
            "description": "API link to access the full beneficiary details"
          },
          "Status": {
            "$ref": "#/components/schemas/StatusCode",
            "description": "The current status of the beneficiary membership"
          },
          "DefaulDisplayName": {
            "type": "string",
            "description": "The default display name for the beneficiary",
            "example": "John Smith"
          },
          "BeneficiaryNumber": {
            "type": "string",
            "description": "The unique member number assigned to the beneficiary within the Fund",
            "example": "1"
          }
        }
      },
      "BeneficiaryData_BeneficiaryAccount": {
        "type": "object",
        "description": "Represents a beneficiary's account within an Fund including balance and status information",
        "required": [
          "Id",
          "Description",
          "Type",
          "Balance",
          "Status",
          "BeneficiaryName",
          "BeneficiaryId"
        ],
        "properties": {
          "Id": {
            "type": "string",
            "description": "The unique identifier for the beneficiary account",
            "example": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
          },
          "Description": {
            "type": "string",
            "description": "A description of the beneficiary account",
            "example": "Accumulation Account - John Smith"
          },
          "Type": {
            "type": "string",
            "description": "The type of Fund member account",
            "example": "Accumulation"
          },
          "Balance": {
            "type": "number",
            "format": "decimal",
            "description": "The current balance of the beneficiary account in AUD",
            "example": 485000.5
          },
          "Status": {
            "$ref": "#/components/schemas/StatusCode",
            "description": "The current status of the beneficiary account"
          },
          "BeneficiaryName": {
            "type": "string",
            "description": "The full name of the beneficiary",
            "example": "John William Smith"
          },
          "BeneficiaryId": {
            "type": "string",
            "description": "The unique identifier for the beneficiary",
            "example": "7c9e6679-7425-40de-944b-e07fc1f90ae7"
          }
        }
      },
      "BeneficiaryDetailResponse": {
        "type": "object",
        "description": "Response wrapper for retrieving beneficiary details, including the beneficiary data and any processing errors.",
        "properties": {
          "Data": {
            "type": "object",
            "description": "Beneficiary details returned by the system.",
            "properties": {
              "Link": {
                "type": "object",
                "description": "Hypermedia link identifying the beneficiary resource.",
                "properties": {
                  "Id": {
                    "type": "string",
                    "format": "uuid",
                    "description": "Unique identifier of the beneficiary.",
                    "example": "eef8e2fe-3000-47c6-9976-171c8f77a7f8"
                  },
                  "Url": {
                    "type": "string",
                    "format": "uri",
                    "description": "Fully qualified URL to retrieve this beneficiary resource.",
                    "example": "https://api.class-test.com.au/api/1.0/f/API/DEMO_SummerDemo/beneficiary-data/beneficiary-detail/eef8e2fe-3000-47c6-9976-171c8f77a7f8"
                  }
                }
              },
              "Status": {
                "type": "string",
                "enum": [
                  "Active",
                  "Suspended",
                  "Cancelled"
                ],
                "description": "Current lifecycle status of the beneficiary within the fund.",
                "example": "Active"
              },
              "Number": {
                "type": "string",
                "description": "Beneficiary number within the fund.",
                "example": "1"
              },
              "TaxFileNumber": {
                "type": "string",
                "nullable": true,
                "description": "Australian Tax File Number (TFN) of the beneficiary. May be null if not recorded.",
                "example": null
              },
              "PartyType": {
                "type": "string",
                "enum": [
                  "Person",
                  "Organisation"
                ],
                "description": "Indicates whether the beneficiary is an individual or an organisation.",
                "example": "Person"
              },
              "PersonalDetails": {
                "type": "object",
                "nullable": true,
                "description": "Personal details applicable when the beneficiary is an individual.",
                "properties": {
                  "Title": {
                    "type": "string",
                    "description": "Title of the individual.",
                    "example": "MR"
                  },
                  "FirstName": {
                    "type": "string",
                    "description": "First name of the beneficiary.",
                    "example": "John"
                  },
                  "MiddleNames": {
                    "type": "string",
                    "description": "Middle names of the beneficiary.",
                    "example": ""
                  },
                  "LastName": {
                    "type": "string",
                    "description": "Last name (surname) of the beneficiary.",
                    "example": "Smith"
                  },
                  "Gender": {
                    "type": "string",
                    "description": "Gender of the beneficiary.",
                    "example": "Male"
                  },
                  "DateOfBirth": {
                    "type": "string",
                    "format": "date",
                    "description": "Date of birth of the beneficiary.",
                    "example": "1985-06-15"
                  },
                  "PreferredSalutation": {
                    "type": "string",
                    "description": "Preferred salutation for correspondence.",
                    "example": ""
                  },
                  "PreferredName": {
                    "type": "string",
                    "description": "Preferred display or greeting name.",
                    "example": "John"
                  }
                }
              },
              "OrganisationDetails": {
                "type": "object",
                "nullable": true,
                "description": "Organisation details applicable when the beneficiary is an organisation.",
                "properties": {
                  "OrganisationName": {
                    "type": "string",
                    "nullable": true,
                    "description": "Legal name of the organisation.",
                    "example": null
                  }
                }
              },
              "ContactDetails": {
                "type": "object",
                "description": "Contact, address, and invitation information for the beneficiary.",
                "properties": {
                  "PreferredVoiceContact": {
                    "type": "string",
                    "nullable": true,
                    "description": "Preferred voice contact method.",
                    "example": null
                  },
                  "PreferredWrittenContact": {
                    "type": "string",
                    "nullable": true,
                    "description": "Preferred written communication method.",
                    "example": "Email"
                  },
                  "HomePhone": {
                    "type": "string",
                    "nullable": true,
                    "description": "Home phone number.",
                    "example": null
                  },
                  "WorkPhone": {
                    "type": "string",
                    "nullable": true,
                    "description": "Work phone number.",
                    "example": ""
                  },
                  "Mobile": {
                    "type": "string",
                    "nullable": true,
                    "description": "Mobile phone number.",
                    "example": null
                  },
                  "Direct": {
                    "type": "string",
                    "nullable": true,
                    "description": "Direct phone number.",
                    "example": null
                  },
                  "Fax": {
                    "type": "string",
                    "nullable": true,
                    "description": "Fax number.",
                    "example": null
                  },
                  "Email": {
                    "type": "string",
                    "nullable": true,
                    "description": "Email address used for correspondence.",
                    "example": ""
                  },
                  "InvitationDetails": {
                    "type": "object",
                    "description": "Invitation and access status information for the beneficiary.",
                    "properties": {
                      "InvitationStatus": {
                        "type": "string",
                        "description": "Current invitation status for beneficiary user access.",
                        "example": "NotInvited"
                      },
                      "CanInviteUsers": {
                        "type": "boolean",
                        "description": "Indicates whether the beneficiary is permitted to invite users.",
                        "example": true
                      },
                      "PersistedEmailAddress": {
                        "type": "string",
                        "description": "Email address associated with existing invitations.",
                        "example": ""
                      },
                      "BeneficiaryId": {
                        "type": "string",
                        "format": "uuid",
                        "description": "Identifier of the beneficiary associated with the invitation.",
                        "example": "eef8e2fe-3000-47c6-9976-171c8f77a7f8"
                      }
                    }
                  },
                  "UsePhysicalAddressForMailingAddress": {
                    "type": "boolean",
                    "description": "Indicates whether the physical address is also used as the mailing address.",
                    "example": true
                  },
                  "PhysicalAddress": {
                    "type": "object",
                    "description": "Physical (residential or business) address of the beneficiary.",
                    "properties": {
                      "Type": {
                        "type": "string",
                        "description": "Address usage type.",
                        "example": "Physical"
                      },
                      "Addressee": {
                        "type": "string",
                        "nullable": true,
                        "description": "Care-of or addressee name.",
                        "example": null
                      },
                      "Line1": {
                        "type": "string",
                        "description": "Address line 1.",
                        "example": ""
                      },
                      "Line2": {
                        "type": "string",
                        "description": "Address line 2.",
                        "example": ""
                      },
                      "Line3": {
                        "type": "string",
                        "description": "Address line 3.",
                        "example": ""
                      },
                      "Line4": {
                        "type": "string",
                        "description": "Address line 4.",
                        "example": ""
                      },
                      "Suburb": {
                        "type": "string",
                        "description": "Suburb or locality.",
                        "example": ""
                      },
                      "State": {
                        "type": "string",
                        "description": "State or region.",
                        "example": ""
                      },
                      "PostCode": {
                        "type": "string",
                        "description": "Postal code.",
                        "example": ""
                      },
                      "ValidateAddress": {
                        "type": "boolean",
                        "description": "Indicates whether the address has been validated.",
                        "example": false
                      },
                      "Country": {
                        "type": "string",
                        "description": "Country code of the physical address.",
                        "example": "AUS"
                      }
                    }
                  },
                  "MailingAddress": {
                    "type": "object",
                    "description": "Mailing address of the beneficiary.",
                    "properties": {
                      "Type": {
                        "type": "string",
                        "description": "Address usage type.",
                        "example": "Mailing"
                      },
                      "Addressee": {
                        "type": "string",
                        "description": "Care-of or addressee name.",
                        "example": ""
                      },
                      "Line1": {
                        "type": "string",
                        "description": "Address line 1.",
                        "example": ""
                      },
                      "Line2": {
                        "type": "string",
                        "description": "Address line 2.",
                        "example": ""
                      },
                      "Line3": {
                        "type": "string",
                        "description": "Address line 3.",
                        "example": ""
                      },
                      "Line4": {
                        "type": "string",
                        "description": "Address line 4.",
                        "example": ""
                      },
                      "Suburb": {
                        "type": "string",
                        "description": "Suburb or locality.",
                        "example": ""
                      },
                      "State": {
                        "type": "string",
                        "description": "State or region.",
                        "example": ""
                      },
                      "PostCode": {
                        "type": "string",
                        "description": "Postal code.",
                        "example": ""
                      },
                      "ValidateAddress": {
                        "type": "boolean",
                        "description": "Indicates whether the address has been validated.",
                        "example": false
                      },
                      "Country": {
                        "type": "string",
                        "description": "Country code of the mailing address.",
                        "example": "AUS"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "UpdateBeneficiaryDetail": {
        "type": "object",
        "description": "Represents a beneficiary to be created or updated within a fund. The structure supports both individual (person) and organisational beneficiaries. Certain fields are conditionally required depending on the party type and address usage rules.\n",
        "required": [
          "Status",
          "Number",
          "PartyType",
          "ContactDetails"
        ],
        "properties": {
          "Status": {
            "type": "string",
            "enum": [
              "Active",
              "Suspended",
              "Cancelled"
            ],
            "description": "The lifecycle status of the beneficiary within the fund. This value determines whether the beneficiary is active, suspended, or cancelled.\n",
            "example": "Active"
          },
          "Number": {
            "type": "string",
            "description": "The beneficiary’s unique number within the fund. This is used to identify the beneficiary for reporting and administration purposes.\n",
            "example": "1"
          },
          "TaxFileNumber": {
            "type": "string",
            "description": "The Australian Tax File Number (TFN) of the beneficiary. This field is optional and only applicable where a TFN is available and permitted to be stored.\n",
            "example": "123456789"
          },
          "PartyType": {
            "type": "string",
            "enum": [
              "Person",
              "Organisation"
            ],
            "description": "Indicates whether the beneficiary is an individual person or an organisation. This value determines which detail object (PersonalDetails or OrganisationDetails) is required.\n",
            "example": "Person"
          },
          "PersonalDetails": {
            "type": "object",
            "description": "Personal information about an individual beneficiary. This object is required when PartyType is set to Person.\n",
            "properties": {
              "Title": {
                "type": "string",
                "description": "Title of the individual (e.g. Mr, Mrs, Ms). The value must match a supported salutation code.\n",
                "example": "MR"
              },
              "FirstName": {
                "type": "string",
                "description": "First (given) name of the beneficiary.\n",
                "example": "John"
              },
              "MiddleNames": {
                "type": "string",
                "description": "Middle names of the beneficiary, if applicable.\n",
                "example": "William"
              },
              "LastName": {
                "type": "string",
                "description": "Family name (surname) of the beneficiary.\n",
                "example": "Smith"
              },
              "DateOfBirth": {
                "type": "string",
                "format": "date",
                "description": "Date of birth of the beneficiary.\n",
                "example": "1985-06-15"
              },
              "Gender": {
                "type": "string",
                "description": "Gender of the beneficiary.\n",
                "example": "Male"
              },
              "PreferredSalutation": {
                "type": "string",
                "description": "Preferred salutation used for correspondence.\n",
                "example": "Mr"
              },
              "PreferredName": {
                "type": "string",
                "description": "Preferred name used for display or greetings.\n",
                "example": "Johnny"
              }
            }
          },
          "OrganisationDetails": {
            "type": "object",
            "description": "Organisation information for a non-individual beneficiary. This object is required when PartyType is set to Organisation.\n",
            "properties": {
              "OrganisationName": {
                "type": "string",
                "description": "The registered legal name of the organisation.\n",
                "example": "Acme Corporation Pty Ltd"
              }
            }
          },
          "ContactDetails": {
            "type": "object",
            "description": "Contact and address information for the beneficiary. Address information is mandatory to ensure the beneficiary has a valid physical and mailing location recorded.\n",
            "required": [
              "UsePhysicalAddressForMailingAddress",
              "PhysicalAddress",
              "MailingAddress"
            ],
            "properties": {
              "PreferredVoiceContact": {
                "type": "string",
                "description": "Preferred voice contact method (e.g. Mobile, Home, Work).\n",
                "example": "Mobile"
              },
              "PreferredWrittenContact": {
                "type": "string",
                "description": "Preferred written communication method (e.g. Email).\n",
                "example": "Email"
              },
              "HomePhone": {
                "type": "string",
                "description": "Home phone number of the beneficiary.\n",
                "example": "61298765432"
              },
              "WorkPhone": {
                "type": "string",
                "description": "Work phone number of the beneficiary.\n",
                "example": "61212345678"
              },
              "Mobile": {
                "type": "string",
                "description": "Mobile phone number of the beneficiary.\n",
                "example": "61400123456"
              },
              "Fax": {
                "type": "string",
                "description": "Fax number of the beneficiary, if applicable.\n",
                "example": "61299999999"
              },
              "Direct": {
                "type": "string",
                "description": "Direct phone number of the beneficiary.\n",
                "example": "61212345679"
              },
              "Email": {
                "type": "string",
                "format": "email",
                "description": "Email address used for correspondence and invitations.\n",
                "example": "john.smith@example.com"
              },
              "UsePhysicalAddressForMailingAddress": {
                "type": "boolean",
                "description": "Indicates whether the physical address should also be used as the mailing address. When set to true, the mailing address details may mirror the physical address.\n",
                "example": true
              },
              "PhysicalAddress": {
                "type": "object",
                "description": "The physical (residential or business) address of the beneficiary. A valid country must always be supplied.\n",
                "required": [
                  "Country"
                ],
                "properties": {
                  "Line1": {
                    "type": "string",
                    "description": "Address line 1.",
                    "example": "123 George Street"
                  },
                  "Line2": {
                    "type": "string",
                    "description": "Address line 2.",
                    "example": ""
                  },
                  "Line3": {
                    "type": "string",
                    "description": "Address line 3.",
                    "example": ""
                  },
                  "Line4": {
                    "type": "string",
                    "description": "Address line 4.",
                    "example": ""
                  },
                  "Suburb": {
                    "type": "string",
                    "description": "Suburb or locality.",
                    "example": "Sydney"
                  },
                  "State": {
                    "type": "string",
                    "description": "State or region.",
                    "example": "NSW"
                  },
                  "PostCode": {
                    "type": "string",
                    "description": "Postal code.",
                    "example": "2000"
                  },
                  "ValidateAddress": {
                    "type": "boolean",
                    "description": "Indicates whether the address has been validated through an address verification process.\n",
                    "example": false
                  },
                  "Country": {
                    "type": "string",
                    "description": "Country code of the physical address. The value must uniquely identify a supported country.\n",
                    "example": "AU"
                  }
                }
              },
              "MailingAddress": {
                "type": "object",
                "description": "The mailing address of the beneficiary. This address is always required, even when the physical address is used for mailing purposes.\n",
                "required": [
                  "Country"
                ],
                "properties": {
                  "Addressee": {
                    "type": "string",
                    "description": "Name of the addressee or care-of recipient for mail.\n",
                    "example": "John Smith"
                  },
                  "Line1": {
                    "type": "string",
                    "description": "Address line 1.",
                    "example": "123 George Street"
                  },
                  "Line2": {
                    "type": "string",
                    "description": "Address line 2.",
                    "example": ""
                  },
                  "Line3": {
                    "type": "string",
                    "description": "Address line 3.",
                    "example": ""
                  },
                  "Line4": {
                    "type": "string",
                    "description": "Address line 4.",
                    "example": ""
                  },
                  "Suburb": {
                    "type": "string",
                    "description": "Suburb or locality.",
                    "example": "Sydney"
                  },
                  "State": {
                    "type": "string",
                    "description": "State or region.",
                    "example": "NSW"
                  },
                  "PostCode": {
                    "type": "string",
                    "description": "Postal code.",
                    "example": "2000"
                  },
                  "ValidateAddress": {
                    "type": "boolean",
                    "description": "Indicates whether the mailing address has been validated.\n",
                    "example": false
                  },
                  "Country": {
                    "type": "string",
                    "description": "Country code of the mailing address.\n",
                    "example": "AU"
                  }
                }
              }
            }
          }
        }
      },
      "StatusCode": {
        "type": "string",
        "description": "The status of a beneficiary or account within the Fund",
        "enum": [
          "Active",
          "Cancelled",
          "Pending",
          "Suspended"
        ],
        "example": "Active"
      },
      "StandardApiResponse": {
        "type": "object",
        "allOf": [
          {
            "$ref": "#/components/schemas/ApiResponseBase"
          }
        ]
      },
      "guid": {
        "type": "string",
        "description": "A globally unique identifier (GUID) in standard UUID format",
        "format": "uuid",
        "example": "550e8400-e29b-41d4-a716-446655440000"
      },
      "InternalErrorCommon": {
        "type": "object",
        "properties": {
          "Code": {
            "type": "string",
            "example": "API_INTERNAL_ERROR"
          },
          "Message": {
            "type": "string",
            "example": "An unexpected error occurred on the server. Please try again later."
          }
        }
      },
      "ErrorResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "nullable": true
          },
          "message": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ForbiddenErrorCommon": {
        "type": "object",
        "properties": {
          "Code": {
            "type": "string",
            "example": "FORBIDDEN"
          },
          "Message": {
            "type": "string",
            "example": "You do not have permission to access this resource."
          }
        }
      },
      "ResourceUnavailableErrorCommon": {
        "type": "object",
        "properties": {
          "Code": {
            "type": "string",
            "example": "API_NOT_FOUND"
          },
          "Message": {
            "type": "string",
            "example": "Resource not available or user does not have access to the fund."
          }
        }
      },
      "UnauthorizedErrorCommon": {
        "type": "object",
        "properties": {
          "Code": {
            "type": "string",
            "example": "API_NOT_AUTHORISED"
          },
          "Message": {
            "type": "string",
            "example": "Not authorised"
          }
        }
      }
    },
    "securitySchemes": {
      "Class_oAuth": {
        "type": "oauth2",
        "description": "Class uses oAuth2 and OpenID for authentication and authorisation",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://app.class-test.com.au/connect/authorize",
            "tokenUrl": "https://app.class-test.com.au/connect/token",
            "scopes": {
              "business.fund.list": "List summarised data of funds in the business",
              "business.fund.create": "Create new funds in the business",
              "fund.details.read": "View basic fund details",
              "fund.details.maintain": "View and maintain basic fund details",
              "fund.member.read": "View member details",
              "fund.member.maintain": "View and maintain member details",
              "fund.read": "View all fund information",
              "fund.maintain": "View and maintain all fund information"
            }
          }
        }
      }
    },
    "parameters": {
      "businessCodeParam": {
        "name": "businessCode",
        "in": "path",
        "description": "Class business code",
        "required": true,
        "schema": {
          "type": "string",
          "example": "demo-business"
        }
      },
      "fundCodeParam": {
        "name": "fundCode",
        "description": "Class entity code",
        "in": "path",
        "required": true,
        "schema": {
          "type": "string",
          "example": "demo-fund"
        }
      }
    }
  }
}