Skip to content

Legal API: need to accept share values more than 16 digits #32999

Closed

Description

@severinbeauvais

As a result of #32772, the UI allows entry of "maximum shares" and "par values" up to the limit of a "Number" type (which is the same in JS, JSON and our db). However, the API validation is currently rejecting some valid data.

Steps to reproduce:

  1. create an IA
  2. add a share class
  3. set maxNumberOfShares = 10000000000000000000
  4. set par value = 0.000000000000000000000000000000000001
  5. fill in the rest of the IA and submit it
  6. observe HTTP 400 error (bad response):

image.png

In the above example, maxNumberOfShares is a valid Number (and so is parValue). Here are the rules (as per the original requirements in ticket #3837 and presently implemented in the UI):

  • Maximum number of shares supports up to 20 digits.
  • Par value supports up to 38 digits.
  • Both number of shares and par value can have a maximum of 16 significant digits.

For example, the following are valid numbers of shares:

  • 10000000000000000000 (max 20 characters)
  • 1234567890123456 (max 16 significant digits)

The following are valid par values:

  • 0.000000000000000000000000000000000001 (max 38 characters)
  • 10000000000000000000000000000000000000 (max 38 characters)
  • 1234567890123456 (max 16 significant digits)
  • 0.1234567890123456 (max 16 significant digits)

QA Notes [LO 2026-05-11]

Activity

  1. added
    bug
    Entities Team
    on Mar 30, 2026
  2. self-assigned this
    on May 11, 2026
  3. self-assigned this
    on May 19, 2026
  4. gunanagar commented on May 20, 2026

    @gunanagar
    Collaborator

    Tested Share value both in UI & API - API alinged with UI

    Screenshot 2026-05-20 at 1.40.30 PM.png

    Screenshot 2026-05-20 at 1.41.50 PM.png

  5. gunanagar commented on May 20, 2026

    @gunanagar
    Collaborator

    API with more than 16 it accepted. - PASS

    Screenshot 2026-05-20 at 1.44.01 PM.png

  6. gunanagar commented on May 21, 2026

    @gunanagar
    Collaborator

    10000000000000000000000000000000000000 (max 38 characters) - Positive and negative - All PASS both API and UI aligned

    Screenshot 2026-05-21 at 11.13.51 AM.png

    Screenshot 2026-05-21 at 11.13.24 AM.png

    Screenshot 2026-05-21 at 11.09.16 AM.png

    Screenshot 2026-05-21 at 11.07.09 AM.png

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Entities Teambug

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions