-
Notifications
You must be signed in to change notification settings - Fork 9
Closed
Description
The LnpOrder class does not have the same getNotes() method as the Order class. This is a problem because you cannot query notes on an LNPOrder since calling getNotes() for an Order that is not of type LNPOrder does not work.
Since the API endpoint supports calling /notes on the /orders/ and the /portIns/ resource, I fixed this by adding the same methods from the Order class to the LnpOrder class and changing the orderId and URI path before recompiling the SDK:
public void addNote(Note note) throws Exception {
client.put(client.buildAccountModelUri(new String[] { IrisPath.LNP_URI_PATH, orderId, "notes" }), note);
}
public Notes getNotes() throws Exception {
return client.get(client.buildAccountModelUri(new String[] { IrisPath.LNP_URI_PATH, orderId, "notes" }), Notes.class);
}
I'll add a PR and unit tests soon.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels