At present, when we try to create invoice through NXT Invoice API the sequence in which the distribution is created is not the same that we have passed in the request payload.
I have attached two image files here for reference. The Request_Payload_Sequence.png will show the sequence in which distribution was passed through an Invoice API and another image with Sequence_Created_At_NXT_Through_API.png name will show the sequence in which it was created in NXT.
The request is to keep the same sequence of distribution as it was passed through Invoice API.