Skip to content
Browse files

added support for private API instances

  • Loading branch information...
1 parent ce9d707 commit 4d3895c1f0db4e878d2722177c83849f84592f74 @pdfcrowd committed Aug 27, 2012
Showing with 3 additions and 2 deletions.
  1. +3 −2 lib/pdfcrowd.js
View
5 lib/pdfcrowd.js
@@ -3,7 +3,7 @@ var querystring = require('querystring');
var fs = require('fs');
-var Pdfcrowd = function(username, apikey) {
+var Pdfcrowd = function(username, apikey, host) {
if (!username)
throw new Error('Missing username.');
@@ -12,6 +12,7 @@ var Pdfcrowd = function(username, apikey) {
this.username = username;
this.apikey = apikey;
+ this.host = host || "pdfcrowd.com";
};
@@ -203,7 +204,7 @@ var convertInternal = function(that, opts) {
// http options
httpOptions = {
- host: 'pdfcrowd.com',
+ host: that.host,
port: 80,
method: 'POST',
path: opts.endpoint,

0 comments on commit 4d3895c

Please sign in to comment.
Something went wrong with that request. Please try again.