Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.0.48
2.0.48
30 changes: 30 additions & 0 deletions lib/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
interface config {
uri: string;
apiKey: string;
secretKey: string;
}

interface apiOptions {
retrieve(request: any): { path: string; method: 'GET' };
create(request: any): { path: string; method: 'POST' };
update(request: any): { path: string; method: 'PUT' };
delete(request: any): { path: string; method: 'DELETE' };
retrieve(request: any): { path: string; method: 'GET' };
retrieveList(request: any): { path: string; method: 'GET' };
}

// * Add new resources to here
interface initResult {
_config: config;
apiTest: apiTest;
}

// * Resources Types
interface apiTest extends apiOptions {
_config: config;
}

declare module 'iyzipay' {
function Iyzipay(config: config): initResult;
export = Iyzipay;
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "2.0.48",
"description": "iyzipay api node.js client",
"main": "lib/Iyzipay.js",
"typings": "index.d.ts",
"scripts": {
"test": "mocha $(find test -name '*Test.js')",
"samples": "mocha $(find samples -name '*Samples.js')",
Expand Down