!!! 5 html head title Swagger UI link(href='//fonts.googleapis.com/css?family=Droid+Sans:400,700', rel='stylesheet', type='text/css') link(href='/bower_components/swagger-ui/dist/css/highlight.default.css', media='screen', rel='stylesheet', type='text/css') link(href='/bower_components/swagger-ui/dist/css/screen.css', media='screen', rel='stylesheet', type='text/css') script(src='/bower_components/swagger-ui/dist/lib/shred.bundle.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/jquery-1.8.0.min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/jquery.slideto.min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/jquery.wiggle.min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/jquery.ba-bbq.min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/handlebars-1.0.0.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/underscore-min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/backbone-min.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/swagger.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/swagger-ui.js', type='text/javascript') script(src='/bower_components/swagger-ui/dist/lib/highlight.7.3.pack.js', type='text/javascript') script(type='text/javascript') $(function () { window.swaggerUi = new SwaggerUi({ url: "/api/v2/api-docs", dom_id: "swagger-ui-container", supportedSubmitMethods: ['get', 'post', 'put', 'delete'], onComplete: function(swaggerApi, swaggerUi){ if(console) { console.log("Loaded SwaggerUI") } $('pre code').each(function(i, e) {hljs.highlightBlock(e)}); }, onFailure: function(data) { if(console) { console.log("Unable to Load SwaggerUI"); console.log(data); } }, docExpansion: "none" }); debugger; $('#input_apiKey').change(function() { var key = $('#input_apiKey')[0].value; console.log("apiKey: " + key); if(key && key.trim() != "") { console.log("added key " + key); window.authorizations.add("apiKey", new ApiKeyAuthorization("x-api-key", key, "header")); } }) $('#input_uuid').change(function() { var key = $('#input_uuid')[0].value; console.log("uuid: " + key); if(key && key.trim() != "") { console.log("added key " + key); window.authorizations.add("uuid", new ApiKeyAuthorization("x-api-user", key, "header")); } }) window.swaggerUi.load(); }); body #header .swagger-ui-wrap a#logo(href='http://swagger.wordnik.com') HabitRPG API Documentation (Under Construction) .swagger-ui-wrap(style='padding:50px') form#api_selector .input input#input_uuid(placeholder='UUID', name='uuid', type='text') input#input_apiKey(placeholder='API Key', name='apiKey', type='text') //.input input#input_baseUrl(placeholder='http://example.com/api', name='baseUrl', type='text') //.input a#explore(href='#') Explore p(style='color:red') This documentation is a work in progress. If you'd like to help finish it, see #2217. #message-bar.swagger-ui-wrap #swagger-ui-container.swagger-ui-wrap