12 lines
491 B
JavaScript
12 lines
491 B
JavaScript
const api = require('../utils/api');
|
|||
|
|
|
||
|
|
function getState() { return api.get('/account/service-consent'); }
|
||
|
|
function agree(documentVersions) {
|
||
|
|
return api.post('/account/service-consent', { documentVersions }, undefined, api.idempotencyKey('service-consent'));
|
||
|
|
}
|
||
|
|
function withdraw(consentType) {
|
||
|
|
return api.post('/account/service-consent/withdraw', { consentType }, undefined, api.idempotencyKey('service-consent-withdraw', consentType));
|
||
|
|
}
|
||
|
|
|
||
|
|
module.exports = { getState, agree, withdraw };
|