@ifunny/ifunny-api-types 0.7.8 → 0.7.9
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/CHANGELOG.md +10 -0
- package/dist/errors/index.js +1 -0
- package/dist/errors/index.js.map +1 -1
- package/dist/errors/unauthorized.js +8 -0
- package/dist/errors/unauthorized.js.map +1 -0
- package/package.json +1 -1
- package/types/errors/error.d.ts +2 -1
- package/types/errors/error.d.ts.map +1 -1
- package/types/errors/index.d.ts +1 -0
- package/types/errors/index.d.ts.map +1 -1
- package/types/errors/unauthorized.d.ts +12 -0
- package/types/errors/unauthorized.d.ts.map +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,16 @@
|
|
|
2
2
|
> All notable changes to this project will be documented in this file.
|
|
3
3
|
> This Changelog adheres to the [Semantic Versioning]("https://semver.org/")
|
|
4
4
|
|
|
5
|
+
## [v0.7.9](https://github.com/ifunny-co/ifunny-api-types/compare/v0.7.8...v0.7.9) - 2022-09-10
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* Add Unauthorized error @MakeShiftArtist ([`5800a15`](https://github.com/ifunny-co/ifunny-api-types/commit/5800a154371b354caa3559a074c34612e4adfc60))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
5
15
|
## [v0.7.8](https://github.com/ifunny-co/ifunny-api-types/compare/v0.7.7...v0.7.8) - 2022-09-10
|
|
6
16
|
|
|
7
17
|
|
package/dist/errors/index.js
CHANGED
|
@@ -20,4 +20,5 @@ __exportStar(require("./email_exists"), exports);
|
|
|
20
20
|
__exportStar(require("./error_base"), exports);
|
|
21
21
|
__exportStar(require("./error"), exports);
|
|
22
22
|
__exportStar(require("./invalid_email"), exports);
|
|
23
|
+
__exportStar(require("./unauthorized"), exports);
|
|
23
24
|
//# sourceMappingURL=index.js.map
|
package/dist/errors/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,qDAAmC;AACnC,iDAA+B;AAC/B,+CAA6B;AAC7B,0CAAwB;AACxB,kDAAgC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,qDAAmC;AACnC,iDAA+B;AAC/B,+CAA6B;AAC7B,0CAAwB;AACxB,kDAAgC;AAChC,iDAA+B"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UNAUTHORIZED = void 0;
|
|
4
|
+
var UNAUTHORIZED;
|
|
5
|
+
(function (UNAUTHORIZED) {
|
|
6
|
+
UNAUTHORIZED["GUESTS"] = "Requested operation is unavailable for guests";
|
|
7
|
+
})(UNAUTHORIZED = exports.UNAUTHORIZED || (exports.UNAUTHORIZED = {}));
|
|
8
|
+
//# sourceMappingURL=unauthorized.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unauthorized.js","sourceRoot":"","sources":["../../src/errors/unauthorized.ts"],"names":[],"mappings":";;;AAUA,IAAY,YAEX;AAFD,WAAY,YAAY;IACvB,wEAAwD,CAAA;AACzD,CAAC,EAFW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAEvB"}
|
package/package.json
CHANGED
package/types/errors/error.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { RESTAPIErrorBadRequest } from "./bad_request";
|
|
|
3
3
|
import { RESTAPIErrorCaptchaRequired } from "./captcha_required";
|
|
4
4
|
import { RESTAPIErrorEmailExists } from "./email_exists";
|
|
5
5
|
import { RESTAPIErrorInvalidEmail } from "./invalid_email";
|
|
6
|
+
import { RESTAPIErrorUnauthorized } from "./unauthorized";
|
|
6
7
|
/**
|
|
7
8
|
* Returns when the request throws an error.\
|
|
8
9
|
* Automatically evaluates the error based on other values
|
|
@@ -16,7 +17,7 @@ import { RESTAPIErrorInvalidEmail } from "./invalid_email";
|
|
|
16
17
|
* }
|
|
17
18
|
* }
|
|
18
19
|
*/
|
|
19
|
-
export declare type RESTAPIErrorResponse = RESTAPIErrorBadRequest | RESTAPIErrorCaptchaRequired | RESTAPIErrorEmailExists | RESTAPIErrorInvalidEmail;
|
|
20
|
+
export declare type RESTAPIErrorResponse = RESTAPIErrorBadRequest | RESTAPIErrorCaptchaRequired | RESTAPIErrorEmailExists | RESTAPIErrorInvalidEmail | RESTAPIErrorUnauthorized;
|
|
20
21
|
/**
|
|
21
22
|
* Use this if you don't know the error being thrown or don't want full intellisense support
|
|
22
23
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/errors/error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"error.d.ts","sourceRoot":"","sources":["../../src/errors/error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,2BAA2B,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,MAAM,gBAAgB,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAC3D,OAAO,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAC;AAE1D;;;;;;;;;;;;GAYG;AACH,oBAAY,oBAAoB,GAC7B,sBAAsB,GACtB,2BAA2B,GAC3B,uBAAuB,GACvB,wBAAwB,GACxB,wBAAwB,CAAC;AAE5B;;GAEG;AACH,oBAAY,mBAAmB,GAAG,YAAY,CAAC"}
|
package/types/errors/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IFUNNY_ERRORS, RESTAPIError } from "./error_base";
|
|
2
|
+
export interface RESTAPIErrorUnauthorized extends RESTAPIError {
|
|
3
|
+
error: IFUNNY_ERRORS.UNAUTHORIZED;
|
|
4
|
+
error_description: RESTAPIUnauthorizedMessage;
|
|
5
|
+
status: 400;
|
|
6
|
+
}
|
|
7
|
+
export default RESTAPIErrorUnauthorized;
|
|
8
|
+
export declare enum UNAUTHORIZED {
|
|
9
|
+
GUESTS = "Requested operation is unavailable for guests"
|
|
10
|
+
}
|
|
11
|
+
declare type RESTAPIUnauthorizedMessage = `${UNAUTHORIZED}`;
|
|
12
|
+
//# sourceMappingURL=unauthorized.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unauthorized.d.ts","sourceRoot":"","sources":["../../src/errors/unauthorized.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE3D,MAAM,WAAW,wBAAyB,SAAQ,YAAY;IAC7D,KAAK,EAAE,aAAa,CAAC,YAAY,CAAC;IAClC,iBAAiB,EAAE,0BAA0B,CAAC;IAC9C,MAAM,EAAE,GAAG,CAAC;CACZ;AAED,eAAe,wBAAwB,CAAC;AAExC,oBAAY,YAAY;IACvB,MAAM,kDAAkD;CACxD;AAED,aAAK,0BAA0B,GAAG,GAAG,YAAY,EAAE,CAAC"}
|