Closed awolfe76 closed 7 years ago
@awolfe76 Quick question about the second API endpoint. According to the spec as published in Regulation C there are two operations here:
1) Calculate check digit from loan id (loan id is LEI
+ loan or application identifier). A Universal Loan Identifier (ULI)
is then calculated by appending loan id followed by the check digit
2) Validate ULI. Given a complete ULI, determine whether it contains transcription errors with the check digit calculation
The second API endpoint is asking for a conversion from check digit --> ULI
, but that is something that based on this spec can't be done. The check digit is two numbers, while the ULI is a large string. What am I missing?
Good point (and good catch). I think I had the wrong terminology.
Based on what you found in Reg C it looks like we should be asking for a "loan id" as an input and from that, we should be able to return the check digit AND the ULI. Not sure if we need to return both but it doesn't hurt.
Then, the reverse would be asking for the ULI and from that, we should be able to return the loan id AND the check digit. OR we could just return true/false, valid or not.
Does that make more sense? Probably worth a bit of discussion.
If it is helpful - here is how we show the LEI/Loan ID/Check Digit breakdown in the FIG.
### Feel free to comment with changes here. This is just a suggestion to get us started.Based on conversations that endpoints and responses have been updated ... but still feel free to comment. 😄
We'll need 2 endpoints for the check digit API. Both should return
json
response and file uploads should allow for bothjson
andCSV
responses.A few quick notes:
/checkDigit
and/checkDigit/csv
POST
- Accepts a single loan id input or a file upload and responds with the check digit(s).Single input
Example
POST
data:Example single input response, in
json
format:File upload
Example file upload (
loans.txt
):Example file upload response, in
json
format:Example file upload response, in
CSV
format:/checkDigit/validate
POST
- Accepts a single ULI input or a file upload and responds with true/false.Single input
Example
POST
data:Example single input response, in
json
format:File upload
Example file (
ulis.txt
):Example file upload response, in
json
format:Example file upload response, in
CSV
format: