@fairandsmart/consents-ce 2.0.18 → 2.0.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/consents/api.d.ts CHANGED
@@ -3,6 +3,7 @@ import { ConsentContext, ConsentTransaction } from './interfaces';
3
3
  import { RCApiOptions } from '../http';
4
4
  export declare function createTransactionJson(ctx: ConsentContext, lang: string, options?: RCApiOptions): Observable<ConsentTransaction>;
5
5
  export declare function getTransactionJson(txid: string, options?: RCApiOptions): Observable<ConsentTransaction>;
6
+ export declare function getTransactionContext(txid: string): Observable<ConsentContext>;
6
7
  export declare function postSubmissionValuesJson(txid: string, values: {
7
8
  [key: string]: string[];
8
9
  }, options?: RCApiOptions): Observable<string>;
package/consents/api.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getSubmitFormPreview = exports.postSubmissionValuesJson = exports.getTransactionJson = exports.createTransactionJson = void 0;
3
+ exports.getSubmitFormPreview = exports.postSubmissionValuesJson = exports.getTransactionContext = exports.getTransactionJson = exports.createTransactionJson = void 0;
4
4
  var api_1 = require("../api");
5
5
  function createTransactionJson(ctx, lang, options) {
6
6
  return api_1.RightConsents.http({
@@ -27,6 +27,16 @@ function getTransactionJson(txid, options) {
27
27
  });
28
28
  }
29
29
  exports.getTransactionJson = getTransactionJson;
30
+ function getTransactionContext(txid) {
31
+ return api_1.RightConsents.http({
32
+ method: 'GET',
33
+ url: "".concat(api_1.RightConsents.config.apiRoot, "/consents/").concat(txid, "/context"),
34
+ headers: {
35
+ 'Content-Type': 'application/json',
36
+ }
37
+ });
38
+ }
39
+ exports.getTransactionContext = getTransactionContext;
30
40
  function postSubmissionValuesJson(txid, values, options) {
31
41
  return api_1.RightConsents.http({
32
42
  method: 'POST',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fairandsmart/consents-ce",
3
- "version": "2.0.18",
3
+ "version": "2.0.19",
4
4
  "description": "TypeScript mappings for the Fair&Smart's Right Consents Community features",
5
5
  "sideEffects": false,
6
6
  "scripts": {},