Positions

This section has operations to manage positions taken by investors in green assets, i.e. showing, adding, and removing positions

Returns the investments in green assets by an investor

POST https://api.bws.ninja/v1/call

Use this operation to retrieve the investments of a particlar investor.

Request Body

Example response

[
    {
        "position_id": 6,
        "position_amount": 2400000,
        "position_currency_code": "EUR",
        "position_days": 180,
        "position_start_date": "2023-02-01",
        "investor_identifier": "3a6515809856",
        "investor_name": "John Smith",
        "asset_identifier": "XS24427682",
        "asset_name": "Asset X, 5-year",
        "issuer_identifier": "good-bank-issuer",
        "issuer_name": "Good Bank"
    },
    {
        "position_id": 16,
        "position_amount": 300000,
        "position_currency_code": "NOK",
        "position_days": 365,
        "position_start_date": "2023-01-01",
        "investor_identifier": "3a6515809856",
        "investor_name": "John Smith",
        "asset_identifier": "XS25798443",
        "asset_name": "Asset Y, 4-year",
        "issuer_identifier": "good-bank-issuer",
        "issuer_name": "Good Bank"
    }
]

Operation parameters

Example code

curl --location 'https://api.bws.ninja/v1/call' \
--header 'X-Api-Key: API-KEY' \
--header 'Content-Type: application/json' \
--data '{
    "solution": "BWS.ESG.Credits",
    "operation": "getPositions",
    "parameters": {
        "investor_identifier": "9c809eb86ee6",
        "asset_identifier": "XS123456",
        "issuer_identifier": "good_issuer",
        "decryption_key": "64dh_WtAnyMK-f3dtb5-ESweLX80P__a3FjXsgg3Y="
        }
    }

Creates and updates an investment in a green asset of an investor

POST https://api.bws.ninja/v1/call

Use this operation to register investments to a particular investor.

Request Body

Example response

{
    "message": "Existing position was successfully changed (id). 6"
}

Operation parameters

Example code

curl --location 'https://api.bws.ninja/v1/call' \
--header 'X-Api-Key: API-KEY' \
--header 'Content-Type: application/json' \
--data '{
    "solution": "BWS.ESG.Credits",
    "operation": "addPosition",
    "parameters": {
        "investor_identifier": "9c809eb86ee6",
        "asset_identifier": "XS123456",
        "position_amount": 2500000,
        "position_currency_code": "EUR",
        "reporting_year": 2023,
        "position_days": 180,
        "position_start_date": "2023-02-01"
        }
    }

Removes an investment in a green asset, and also its impact

POST https://api.bws.ninja/v1/call

Use this operation to remove an investment from a particular investor, where also any associated ESG impact records will be removed.

Request Body

Example response

{
    "Position was successfully removed"
}

Operation parameters

Example code

curl --location 'https://api.bws.ninja/v1/call' \
--header 'X-Api-Key: API-KEY' \
--header 'Content-Type: application/json' \
--data '{
    "solution": "BWS.ESG.Credits",
    "operation": "removePosition",
    "parameters": {
        "investor_identifier": "9c809eb86ee6",
        "position_id": 45
    }

Last updated