Scenario #4202: Revert Coop Shares Subscription

Given Properties

name value
memberNumber M-3101000
comment reverting some incorrect transaction
dateOfIncorrectTransaction 2024-02-15

Find membershipUuid

GET /api/hs/office/memberships/M-3101000
=> status: 200 OK 
{
  "uuid" : "77ff14b6-e2fa-4312-9929-c98694b5463e", // membershipUuid
  "partner" : {
    "uuid" : "72eb4871-122a-42d8-b9a7-e45b7faf9fef", // Partner: P-31010 - Test AG
    "partnerNumber" : "P-31010",
    "partnerRel" : {
      "uuid" : "a4914399-27dc-4094-bf76-d6230d4f8373", // partnerRelationUuid
      "anchor" : {
        "uuid" : "c6575205-1480-4b70-a30b-d0c5a1d7cc99", // Person: Hostsharing eG
        "personType" : "LEGAL_PERSON",
        "tradeName" : "Hostsharing eG",
        "salutation" : null,
        "title" : null,
        "givenName" : null,
        "familyName" : null
      },
      "holder" : {
        "uuid" : "f8f6ad7e-53d2-4cf0-9cb9-30ca2767c599", // partnerPersonUuid
        "personType" : "LEGAL_PERSON",
        "tradeName" : "Test AG",
        "salutation" : null,
        "title" : null,
        "givenName" : null,
        "familyName" : null
      },
      "type" : "PARTNER",
      "mark" : null,
      "contact" : {
        "uuid" : "22c8432b-6fc1-44b4-a977-e1d00327b323", // Contact: Test AG - China
        "caption" : "Test AG - China",
        "postalAddress" : {
          "city" : "Dongguan City",
          "firm" : "Test AG",
          "name" : "Fi Zhong-Kha",
          "street" : "No.2 Commercial Second Street",
          "country" : "China",
          "building" : "Thi Chi Koh Building",
          "district" : "Niushan Wei Wu",
          "province" : "Guangdong Province"
        },
        "emailAddresses" : {
          "main" : "norden@test-ag.example.org"
        },
        "phoneNumbers" : {
          "phone" : "++15 999 654321"
        }
      }
    },
    "details" : {
      "uuid" : "ee1fbee4-f675-42f6-8cb7-66aa0b15e1b8",
      "registrationOffice" : "Registergericht Hamburg",
      "registrationNumber" : "1234567",
      "birthName" : null,
      "birthPlace" : null,
      "birthday" : null,
      "dateOfDeath" : null
    }
  },
  "mainDebitor" : null,
  "memberNumber" : "M-3101000",
  "memberNumberSuffix" : "00",
  "validFrom" : "2020-10-15",
  "validTo" : "2023-12-31",
  "status" : "CANCELLED",
  "membershipFeeBillable" : true
}

Create the Coop-Shares-REVERSAL Transaction

POST /api/hs/office/coopsharestransactions
{
  "membership.uuid" : "77ff14b6-e2fa-4312-9929-c98694b5463e", // membershipUuid
  "transactionType" : "REVERSAL",
  "reference" : "sign 2024-02-15",
  "shareCount" : -100,
  "comment" : "coop-shares subscription transaction with wrong share count",
  "valueDate" : "2024-02-15",
  "revertedShareTx.uuid" : "ccbc0f59-4b3f-4e4c-b8ad-27cad5cb728a" // CoopShares-Transaction with incorrect shareCount
}
=> status: 201 CREATED a1934ce3-7a29-4c44-9cd8-3666622d1b48

Verify Coop-Shares REVERSAL-Transaction

GET /api/hs/office/coopsharestransactions/a1934ce3-7a29-4c44-9cd8-3666622d1b48
=> status: 200 OK 
{
  "uuid" : "a1934ce3-7a29-4c44-9cd8-3666622d1b48",
  "membership.uuid" : "77ff14b6-e2fa-4312-9929-c98694b5463e", // membershipUuid
  "transactionType" : "REVERSAL",
  "shareCount" : -100,
  "valueDate" : "2024-02-15",
  "reference" : "sign 2024-02-15",
  "comment" : "coop-shares subscription transaction with wrong share count",
  "revertedShareTx" : {
    "uuid" : "ccbc0f59-4b3f-4e4c-b8ad-27cad5cb728a", // CoopShares-Transaction with incorrect shareCount
    "membership.uuid" : null,
    "transactionType" : "SUBSCRIPTION",
    "shareCount" : 100,
    "valueDate" : "2024-02-15",
    "reference" : "sign 2024-02-15",
    "comment" : "coop-shares subscription transaction with wrong share count"
  },
  "reversalShareTx" : null
}

generated on 03-10-2025 12:07:44 for branch master