Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Update DPoS constants endpoint #1281

Closed
Tracked by #1304
sameersubudhi opened this issue Oct 10, 2022 · 0 comments
Closed
Tracked by #1304

Update DPoS constants endpoint #1281

sameersubudhi opened this issue Oct 10, 2022 · 0 comments

Comments

@sameersubudhi
Copy link
Contributor

sameersubudhi commented Oct 10, 2022

Description

The wallets require the information to determine the native token for a given chain before they can create the voting transactions. Lisk Service will need to update the /api/v3/dpos/constants endpoint to provide the said information once the SDK creates the necessary endpoint which should be available after the LiskArchive/lisk-sdk#7622 epic is complete.

Update the following endpoint.

Current:

HTTP GET /api/v3/dpos/constants
RPC  get.dpos.constants

Expected:

HTTP GET /api/v3/pos/constants
RPC  get.pos.constants

Acceptance Criteria

  • The endpoints are updated as expected above
  • The response body is up-to-date
  • All the methods, variables, files are renamed and refactored appropriately
  • Swagger is up-to-date
  • Integration tests are up-to-date

Additional information

Response:

200 OK

{
    "data": {
        "factorSelfStakes": 10, // prev: factorSelfVotes
        "maxLengthName": 20,
        "maxNumberSentStakes": 10, // prev: maxNumberSentVotes
        "maxNumberPendingUnlocks": 20,
        "failSafeMissedBlocks": 50,
        "failSafeInactiveWindow": 260000,
        "punishmentWindow": 780000,
        "roundLength": 103,
        "minWeightStandby": "100000000000",
        "numberActiveValidators": 101, // prev: numberActiveDelegates
        "numberStandbyValidators": 2, // prev: numberStandbyDelegates
        "posTokenID": "0000000000000000", // prev: tokenIDDPoS
        "maxBFTWeightCap": 500,
        "commissionIncreasePeriod": 260000,
        "maxCommissionIncreaseRate": 500,
        "extraCommandFees": {
            "validatorRegistrationFee": "1000000000"
        }
    },
    "meta": {}
}
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants