What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
Feature
What is the new behavior (if this is a feature change)?
Creates a few new resources on the client, exposing a few new methods: record.uploadFromUrl(), folder.create(), share.createRecordShareLink, share.createFolderShareLink, as well as creating the required init() method that sets up the session to be called after a client is created.
Client config parameters have also changed, exposing baseUrl as an optional param to help easily test against local, and using archiveNbr instead of archiveId, which is more practically useful internally it turns out. And now the client will throw an exception if required params are missing!
This PR got a little larger change-wise than intended due to:
Updating types and interfaces for API requests and responses to make use of generics when appropriate to actually return the appropriate type signature with the expected VO field, instead of a bunch of optional params that all return as, like FolderVO | undefined instead of just FolderVO. This added a lot of line changes in otherwise untouched files. But a worthy change! Just makes the diff a little larger.
A check-in call with TheirStory with a realization that they'll need to share multiple items in a single batch instead of single files from the jump, which required adding the folder.create and createFolderShareLink methods in this PR instead of for another later issue.
My demo code (minus client config) that creates a folder, uploads files to the folder, and generates a share link is as follows for reference:
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) Feature
What is the new behavior (if this is a feature change)? Creates a few new resources on the client, exposing a few new methods:
record.uploadFromUrl()
,folder.create()
,share.createRecordShareLink
,share.createFolderShareLink
, as well as creating the requiredinit()
method that sets up the session to be called after a client is created.Client config parameters have also changed, exposing
baseUrl
as an optional param to help easily test against local, and usingarchiveNbr
instead ofarchiveId
, which is more practically useful internally it turns out. And now the client will throw an exception if required params are missing!This PR got a little larger change-wise than intended due to:
FolderVO | undefined
instead of justFolderVO
. This added a lot of line changes in otherwise untouched files. But a worthy change! Just makes the diff a little larger.folder.create
andcreateFolderShareLink
methods in this PR instead of for another later issue.My demo code (minus client config) that creates a folder, uploads files to the folder, and generates a share link is as follows for reference: