diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 00000000..19f4ee3d --- /dev/null +++ b/index.d.ts @@ -0,0 +1,10 @@ +declare class OAuth { + constructor(requestTokenUrl: string, accessTokenUrl: string, applicationConsumerKey: string, applicationSecret: string, oauthVersion: string, something: any, encryption: string); + get(url: string, userToken: string, userSecret: string, callback: (error: any, data: any, response: any) => any): OAuth; + delete(url: string, userToken: string, userSecret: string, callback: (error: any, data: any, response: any) => any): OAuth; + post(url: string, oauth_token: string, oauth_token_secret: string, post_body: any, post_content_type: string, callback: any): OAuth; + put(url: string, oauth_token: string, oauth_token_secret: string, post_body: any, post_content_type: string, callback: any): OAuth; + getOAuthRequestToken(callback: (error: any, oauth_token: string, oauth_token_secret: string, results: any) => void): void; +} + +export { OAuth }; diff --git a/package.json b/package.json index 1a555333..dbe25311 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ , "directories" : { "lib" : "./lib" } , "main" : "index.js" , "author" : "Ciaran Jessup " +, "typings": "index.d.ts" , "repository" : { "type":"git", "url":"http://github.com/ciaranj/node-oauth.git" } , "devDependencies": { "vows": "0.5.x" diff --git a/typings.json b/typings.json new file mode 100644 index 00000000..544b7b4d --- /dev/null +++ b/typings.json @@ -0,0 +1,3 @@ +{ + +} \ No newline at end of file