Skip to content

Releases: AleksandrRogov/DynamicsWebApi

v2.2.0

09 Feb 19:09
Compare
Choose a tag to compare

Changes

  • ⚠️ Dropping official support for Node.js v16. Mainly because I cannot run actions with that version anymore, so I cannot guarantee that any future changes will continue working in it.
  • Replaced a custom UUID generator function with a built-in randomUUID (Crypto API).
    ⚠️ This may cause issues in the older browsers, and the library must now run in the "Secure Context" (https).
  • Slightly optimized dateReviver function.

Fixes

  • Modified expand property in the type definitions to accept a string. It could always accept a string together with an array of expand objects.

v2.1.7

16 Sep 15:24
Compare
Choose a tag to compare

Fixes:

  • Wrong type declaration for UploadRequest and DownloadRequest: property and fieldName should be optional, until fieldName is removed.

Changes:

  • Additional optimizations of regular expressions.

v2.1.6

10 Sep 16:50
Compare
Choose a tag to compare

Changes

  • ⚠️ Deprecated: fieldName in request properties for deleteRecord, uploadFile, downloadFile. Please use property instead.
  • Curly brackets won't be removed from the GUIDs inside filter if the value that contains the GUID is inside single quotes, which means it's a string. This is an improvement of an existing functionality.
    Before: "attribute eq 'some text {GUID} more text'" would result in "attribute eq 'some text GUID more text'"
    Now: "attribute eq 'some text {GUID} more text'" stays the same "attribute eq 'some text {GUID} more text'"
  • Improving performance by pre-compiling and optimizing regular expressions.
  • General refactoring to improve code readability.

v2.1.5

11 Jul 16:17
Compare
Choose a tag to compare

Fixes

  • Missing authorization token when request with a long URL is converted into a Batch request. #175

v2.1.4

11 Apr 12:30
Compare
Choose a tag to compare

Fixes

  • name property in a callFunction must be optional, until functionName is removed.

v2.1.3

11 Apr 02:58
Compare
Choose a tag to compare

Changes:

  • Added support for composable functions. Request object in callFunction now accepts select and filter parameters. #168
  • ContentId can be used as an URI reference inside the Batch Request. For example:
dynamicsWebApi.startBatch();

dynamicsWebApi.create({
  contentId: "1", //<-- this content id will be used in the next request
  collection: "contacts",
  data: {
    firstname: "James",
    lastname: "Doe"
  }
});

dynamicsWebApi.updateSingleProperty({
  contentId: "$1", //<-- using content id of the record created in a previous request
  // note, that neither "collection" nor "key" is used in this request, 
  // contentId replaces those
  fieldValuePair: { lastname: "Bond" }
});

const results = await dynamicsWebApi.executeBatch();
//results[0] will have an id of a contact record
//results[1] will be empty

Deprecations:

  • functionName parameter in callFunction is marked as deprecated and will be removed in one of the future versions. Please use name instead.

v1.7.12

10 Apr 15:38
Compare
Choose a tag to compare

Changes:

  • Added a skipNameCheck for composable functions workaround #168

v2.1.2

22 Dec 18:45
Compare
Choose a tag to compare

Changes:

  • Added @odata.nextLink, @odata.count and @odata.deltaLink to TypeScript definitions.

Fixes:

  • Duplicate query parameters during pagination with nextPageLink parameter in retrieveMultiple. #164
  • Duplicate serverUrl in a request url during pagination with nextPageLink parameter in retrieveMultiple. This only happened if serverUrl in DynamicsWebApi config had a closing slash. #164

v2.1.1

02 Sep 17:37
Compare
Choose a tag to compare

Changes:

  • Minor changes in type declarations.

v2.1.0

27 Aug 17:19
Compare
Choose a tag to compare

Changes:

  • Custom headers can now be added by default through the configuration object, or included with each request. #151
    For example: await dynamicsWebApi.retrieveMultiple({ collection: "contacts", headers: { "my-header": "value" } });
  • Added support for Microsoft Power Pages. Thanks to @03-CiprianoG for the PRs! More Info.