diff --git a/oauth3.domains.js b/oauth3.domains.js index 17d0e79..2b5b0b0 100644 --- a/oauth3.domains.js +++ b/oauth3.domains.js @@ -18,6 +18,20 @@ OAUTH3.api['domains.checkAvailability'] = function (providerUri, opts) { }); }; +OAUTH3.api['domains.purchase'] = function (providerUri, opts) { + var session = opts.session; + + return OAUTH3.request({ + method: 'POST' + , url: OAUTH3.url.normalize(providerUri) + + '/api/com.daplie.domains/accounts/' + session.token.sub + '/registrations' + , session: session + , data: opts.data + }).then(function (res) { + return res; + }); +}; + OAUTH3.api['domains.list'] = function (providerUri, opts) { var session = opts.session;