Created
July 4, 2014 09:54
-
-
Save tmtk75/ab92d1c547bb25f67a5c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function test_05_turnUser_disable(params, context, done) { | |
$.ajax({ | |
type: 'PUT', | |
url: params['baseURL'] + '/apps/' + context.getAppID() | |
+ '/users/' + params['userID'] + '/status', | |
headers: { | |
'x-kii-appid': context.getAppID(), | |
'x-kii-appkey':context.getAppKey(), | |
'authorization': 'bearer ' + params['token'] | |
}, | |
contentType: 'application/json', | |
data: JSON.stringify({ | |
'disabled': true | |
}) | |
}).then( | |
function(data, status, xhr) { | |
done(); | |
}, | |
function(xhr, status, error) { | |
done(xhr.status + " " + status + " " + error); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment