You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by sn...@apache.org on 2015/06/25 22:28:39 UTC

[41/51] [partial] incubator-usergrid git commit: Moving website from SVN to Git.

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/c8b7d6c5/website/content/docs/managing-access-defining-permission-rules.md
----------------------------------------------------------------------
diff --git a/website/content/docs/managing-access-defining-permission-rules.md b/website/content/docs/managing-access-defining-permission-rules.md
new file mode 100644
index 0000000..f606ddd
--- /dev/null
+++ b/website/content/docs/managing-access-defining-permission-rules.md
@@ -0,0 +1,218 @@
+---
+title: Managing access by defining permission rules
+category: docs
+layout: docs
+---
+
+Managing access by defining permission rules
+============================================
+
+You control your app users' access to application resources by defining
+roles and permission rules. In your Apache Usergrid application, you assign
+application users a *role* that represents a set of permissions. Through
+these permissions, you allow users to perform certain operations (GET,
+POST, PUT, or DELETE) on specific resources. When the user submits a
+request via your app code to the Apache Usergrid API, the user’s
+permissions are checked against the resource paths that the user is
+trying to access. The request succeeds only if access to the resource is
+allowed by the permission rules you specify.
+
+You specify roles for unauthenticated users and those who authenticate
+as an Application User, as defined in [Authenticating users and
+application clients](/authenticating-users-and-application-clients).
+Roles are not applied for the other authentication levels: Application,
+Admin User, and Organization. Access at these levels can't be restricted
+by roles and permission rules. You should allow clients to authenticate
+at these levels sparingly and carefully.
+
+Roles included by default
+-------------------------
+
+When defining user access to your application's data, you create roles,
+specify permission rules for them, then associate users with the roles.
+Apache Usergrid includes three predefined roles when you create an
+application.
+
+The following table lists the three roles included by default. Note that
+two of these are in effect and applied from the time your application is
+created (until you change them). Apache Usergrid applies the following
+default behavior:
+
+1.  An unauthenticated user is automatically added to the Guest role so
+    that they can register for a user account.
+2.  A user who has a user account and authenticates with it is
+    automatically added to the Default role. **Note that by default,
+    this role is very permissive.** Be sure to restrict it with specific
+    permission rules before deploying to production.
+
++-------------------------+-------------------------+-------------------------+
+| Role                    | Description             | Notes                   |
++=========================+=========================+=========================+
+| Guest                   | Default for             | Grants permission for a |
+|                         | unauthenticated users.  | user to create a user   |
+|                         | Includes a basic set of | account and for their   |
+|                         | permissions for         | device to be            |
+|                         | unregistered or         | registered. You can     |
+|                         | unauthenticated users.  | change permission rules |
+|                         | Users are automatically | based on your goals for |
+|                         | added to the Guest role | unregistered user       |
+|                         | before they’re          | access. This role is    |
+|                         | authenticated. After    | designed to provide     |
+|                         | they’re authenticated,  | access for people who   |
+|                         | users are automatically | haven't yet registered, |
+|                         | added to the Default    | and allow them to       |
+|                         | role.                   | register.               |
++-------------------------+-------------------------+-------------------------+
+| Default                 | Default for             | By default, **grants    |
+|                         | authenticated users.    | full access for all     |
+|                         | Includes permissions    | resources in your       |
+|                         | for the set of          | application**. A first  |
+|                         | operations you want an  | task in securing your   |
+|                         | authenticated user to   | application should be   |
+|                         | be able to perform.     | to restrict access by   |
+|                         | Users are added to this | redefining this role to |
+|                         | role after they're      | narrow the access it    |
+|                         | authenticated.          | provides. Remove the    |
+|                         |                         | default full permission |
+|                         |                         | rule and add            |
+|                         |                         | restrictive permission  |
+|                         |                         | rules for a production  |
+|                         |                         | deployment.             |
++-------------------------+-------------------------+-------------------------+
+| Administrator           | Unused until you        | Grants no access.       |
+|                         | associate it with users | Consider this a blank   |
+|                         | or groups. By default,  | slate. Add permission   |
+|                         | includes no permissions | rules and associate     |
+|                         | that provide access.    | this role with users    |
+|                         |                         | and groups as needed.   |
+|                         |                         |                         |
+|                         |                         | **Note**: The           |
+|                         |                         | Administrator role is   |
+|                         |                         | *not the same* as an    |
+|                         |                         | organization            |
+|                         |                         | administrator -- that   |
+|                         |                         | is, someone who         |
+|                         |                         | authenticates as an     |
+|                         |                         | Admin User. The Admin   |
+|                         |                         | User is an implicit     |
+|                         |                         | user created when you   |
+|                         |                         | create an organization. |
+|                         |                         | After authenticating,   |
+|                         |                         | the Admin User has full |
+|                         |                         | access to all of the    |
+|                         |                         | administration features |
+|                         |                         | of the Apache Usergrid     |
+|                         |                         | API. By comparison, the |
+|                         |                         | Administrator role is   |
+|                         |                         | simply a role           |
+|                         |                         | (initially without      |
+|                         |                         | permissions) that can   |
+|                         |                         | be assigned to any      |
+|                         |                         | user.                   |
++-------------------------+-------------------------+-------------------------+
+
+Defining your own roles and permissions
+---------------------------------------
+
+When preparing an application for production use, a good first step is
+to edit permission rules for the Default role. This role will be applied
+for every user who authenticates as an Application User.
+
+The admin portal is the best place to manage roles. While you can manage
+roles and permissions programmatically (see [Role](/role)),
+security-related calls from a mobile app will pose a security risk.
+Consider doing so only from a server-side web application.
+
+For easy-to-read examples, this section expresses permission rules in
+this way:
+
+    <operations>:<entity path pattern>
+
+-   \<operations\> is a comma-delimited set of REST operations
+    (GET, PUT, POST, DELETE) that are allowed for the specified entity
+    path.
+-   \<entity path pattern\> is a parameter evaluated using Apache Ant
+    pattern matching
+    (see [http://ant.apache.org/manual/dirtasks.html\#patterns](http://ant.apache.org/manual/dirtasks.html#patterns)).
+
+For example, in the Default role, first remove the permission rule that
+grants full access to all authenticated users. You could then begin by
+creating a rule that grants access for the authenticated user to makes
+changes only to data associated with their account. 
+
+    GET,PUT,POST,DELETE:/users/me/**
+
+Use the Admin Portal to make role and permission rule changes. On the
+left sidebar of the portal, click Users, then click Roles. This displays
+the roles defined for the application. To create a role, click the Add
+button (it looks like a person's silhouette). To delete a role, select
+the role you want to delete and click the Remove button (it looks like a
+trash can). To view the privileges in a role, click the role.
+
+Suppose you created a role named "customer". Here’s what the privileges
+for the role might look like:
+
+![](/docs/sites/docs/files/worker_permissions.png)
+
+Notice that specific privileges for operations are represented using
+checkboxes in the Permission Rules section. The path indicates the
+resource path for which the permissions apply. The permissions apply to
+all resources in the specified path directory and its subdirectories. As
+currently specified, the worker role has GET permission on the base
+directory path (/) and all resource paths below it (in other words, all
+resource paths).
+
+You can add a permission, by entering the entity path pattern in the
+Path field of the Add Permission Rule section, and checking the
+operation checkboxes (get, post, put, and delete) as appropriate. For
+example, the following adds permission to create a user:
+
+![](/docs/sites/docs/files/add_permission.png)
+
+Click Add, and the permission is added to the role.
+
+![](/docs/sites/docs/files/pemission_list.png)
+
+Permission rule examples
+------------------------
+
+Here are some examples to illustrate how permissions are specified:
+
+-   Authenticated user can change any data related to the:\
+
+        POST:/users/*
+
+-   A permission the permits the current user to make any changes to
+    resources associated with them:\
+
+        GET,PUT,POST,DELETE:/users/me/**
+
+-   A permission that allows someone to look at a specific user:\
+
+        GET:/users/john.doe
+
+-   A permission that allows the current user to see his activity feed:\
+
+        GET:/users/${user}/feed/*
+
+    The \${user} in the entity path refers to a variable that represents
+    the current user’s UUID.
+
+-   A permission allowing linked entities to be read:\
+
+        GET:/users/${user}/**
+
+    The /\*\* in the entity path is a wildcard that matches everything
+    under that path. This means that the full specification matches
+    multiple resource paths, including, but not limited to, the
+    following:
+
+        /users/${user}/feed
+        /users/${user}/feed/item1/a/b/c
+
+-   A permission that allows the current user to add himself or another
+    user to a group:\
+
+        POST:/groups/${user}/users/**
+
+

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/c8b7d6c5/website/content/docs/messagee-example.md
----------------------------------------------------------------------
diff --git a/website/content/docs/messagee-example.md b/website/content/docs/messagee-example.md
new file mode 100644
index 0000000..e9ec380
--- /dev/null
+++ b/website/content/docs/messagee-example.md
@@ -0,0 +1,192 @@
+---
+title: Messagee Example
+category: docs
+layout: docs
+---
+
+Messagee Example
+================
+
+*Messagee* is a simple Twitter-style messaging application that
+leverages the extensive functionality of App services. This section
+describes some of the features of Messagee.
+
+There are three client versions of Messagee:
+
+-   An [iOS client](#iOS_client)
+-   An [Android client](#android_client)
+-   An [HTML5 client](#html5_client)
+
+The sections below describe how to create a new app, enter some test
+users, and run the app. You also learn how to use the App services admin
+portal, a user interface that streamlines data and application
+management in the App services system. The portal is also a reference
+application that shows how to incorporate App services APIs with
+JavaScript. For a more detailed discussion of the portal's
+functionality, see [Admin portal](/admin-portal).
+
+Creating a user account in App services
+---------------------------------------
+
+Go to [https://apigee.com/usergrid/](https://apigee.com/usergrid/) to
+access the login screen for the App services admin portal. If you are
+new to App services, sign up for an account to access the portal,
+specifying an organization (e.g., the name of your company or project
+team) and a username and password that you can use to authenticate.
+Because App services are designed for use by development teams, the same
+username can be associated with one or more organizations.
+
+If you create a new account, you receive a confirmation email that
+contains a URL that you must click to activate the account. After this,
+simply log in to the portal with your username and password.
+
+![](/docs/sites/docs/files/styles/large/public/login.png?itok=ws5DhLDI)
+
+Creating an app and users
+-------------------------
+
+When you have logged in, you need to create a new application.
+
+![](/docs/sites/docs/files/styles/large/public/portal-1.png?itok=4o63Ia-y)
+
+1.  2.  Enter a unique application name. The name must be unique to
+    avoid a conflict with another user running the same application.
+
+    ![](/docs/sites/docs/files/styles/large/public/portal-2.png?itok=yz8QznI7)
+
+3.  4.  Make sure that the portal shows the application name you entered
+    as the active application beneath the Applications menu **(1)**.
+
+    If the correct name is not displayed, click the menu and select your
+    application.
+
+    Next, you need to populate a test user *user-test-1* that is going
+    to log in to your copy of the server-side Messagee app.
+
+5.  6.  Click the Users box on the left side of the console **(2)**.
+
+    ![](/docs/sites/docs/files/styles/large/public/portal-3.png?itok=ncRlqPGQ)
+
+7.  8.  Click the Add button and enter the user information for your
+    application in the pop-up window (be sure to create a password you
+    can remember), and then click the Create button. Repeat these steps
+    to create a second username *test-user-2*.
+
+    ![](/docs/sites/docs/files/styles/large/public/portal-4.png?itok=X_kKe5Ke)
+
+9.  
+
+When you have finished all these steps, you have a new application and
+two new users.
+
+![](/docs/sites/docs/files/styles/large/public/portal-5.png?itok=jSmAcwc3)
+
+Now that you have created a uniquely named copy of the Messagee
+application as well as two user accounts (*test-user-1* and
+*test-user-2*), you are ready to test out the Messagee app. Use
+test-user-1 to log in to the app, and test-user-2 as the user to follow.
+
+To continue with the example, follow the instructions for a client app
+([iOS client](#iOS_client), [Android client](#android_client), or [HTML5
+client](#html5_client)).
+
+iOS client
+----------
+
+Messagee is available as an iPhone app that uses Apache Usergrid and
+RestKit. The source for the iOS version of Messagee is available in the
+/samples/messagee directory of the [Apache Usergrid iOS SDK](#ios_sdk)
+
+Here are the steps to run the Messagee app on iOS:
+
+1.  2.  Run Steps 1-6 under [Creating an app and users](#app_user).
+
+    These steps create a unique instance of the Messagee app on the
+    server and two test users, *test-user-1* and *test-user-2*.
+
+3.  4.  Access the Messagee server app by typing a URL similar to the
+    following into your iOS mobile client (replace \<Messagee\> with the
+    unique name of your application):
+
+    [https://api.usergrid.com](https://api.usergrid.com)/\<Messagee\>/index.html
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-1-chooseapp.jpg?itok=NSQcdJrj)
+
+5.  6.  On the mobile client, complete the registration information and
+    click Register.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-2-register.jpg?itok=Xzqe7mXV)
+
+7.  8.  Log in to the Messagee app by entering the *test-user-1* account
+    information created previously, and click the Sign in button.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-4-signin.jpg?itok=0M9QYU7b)
+
+    At this point, the message board is empty:
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-5-emptyfeed.jpg?itok=EWcUVMQN)
+
+9.  10. To post a message using the app, click the top-right icon in the
+    message board to create a message, write the message text, and send
+    it by clicking Post.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-6-newmsg.jpg?itok=Wj16l_5V)
+
+    **Note:** The posted message should appear in the message board
+    within few seconds.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-7-feed1msg.jpg?itok=RclSnHuU)
+
+    For your instance of the Messagee application to act like Twitter,
+    you need to "follow" another user.
+
+11. 12. In the message board, click Add People and add *test-user-2* as
+    a person that *test-user-1* follows.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-9-follow.jpg?itok=yJeaYnEj)
+
+13. 14. Log in as *test-user-2* and post a message as this user to the
+    message board.
+15. 16. Go back and log in as user *test-user-1*.
+
+    Because *test-user-1* follows *test-user-2*, you should see the
+    message sent by *test-user-2* in the message board.
+
+    ![](/docs/sites/docs/files/styles/large/public/iOS-10-seeusermsg.jpg?itok=Wcd7avBh)
+
+17. 
+
+iOS SDK
+-------
+
+If you want to write iOS applications that connect to App services,
+[download the Apache Usergrid iOS
+SDK](http://www.apigee.com/docs/content/ios-sdk-redirect)
+
+**Note:** The Messagee iOS application uses RestKit, a popular REST
+framework for iOS, to communicate with App services. Because App
+services use a REST API, you can use any REST framework to talk with the
+service. However, the official App services iOS SDK provides a more
+convenient communication mechanism that you should use unless you're
+already using RestKit or some other framework in your project.
+
+Android client and SDK
+----------------------
+
+Messagee is available as a sample Android app that acts as a App
+services client. The source for the Android version is packaged with the
+Apache Usergrid Android SDK in the /samples/messagee directory.
+
+[Download the Apache Usergrid Android
+SDK](http://www.apigee.com/docs/content/android-sdk-redirect).
+
+Javascript/HTML5 client and SDK
+-------------------------------
+
+Messagee is also available as a sample HTML5 app that behaves in much
+the same way as the two previous examples. The source for the HTML5
+version is packaged with the Apache Usergrid Javascript/HTML5 SDK in the
+/samples/messagee directory.
+
+[Download the Apache Usergrid Javascript/HTML5
+SDK](http://www.apigee.com/docs/content/javascript-sdk-redirect).

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/c8b7d6c5/website/content/docs/nodejs-module.md
----------------------------------------------------------------------
diff --git a/website/content/docs/nodejs-module.md b/website/content/docs/nodejs-module.md
new file mode 100644
index 0000000..e9f10f9
--- /dev/null
+++ b/website/content/docs/nodejs-module.md
@@ -0,0 +1,61 @@
+---
+title: Node.js module
+category: docs
+layout: docs
+---
+
+Installation
+------------
+
+From the command-line, run:
+
+```bash
+$ npm install usergrid
+```
+
+
+Client Initialization
+---------------------
+
+TODO
+
+
+
+Organizations
+-------------
+
+```javascript
+// Create an Organization
+var options = {
+    method:'POST',
+    endpoint:'management/orgs',
+    body:{ 
+          password:'test12345', 
+          email:'tester12345@gmail.com', 
+          name:'test', 
+          username:'tes123', 
+          organization:'testorg' 
+    }    
+};
+client.request(options, function (err, data) {
+    if (err) {
+        //error — POST failed
+    } else {
+        //success — data will contain raw results from API call        
+    }
+});
+
+
+// Read an Organization
+var options = {
+    method:'GET',
+    endpoint:'management/orgs/testorg'
+};
+client.request(options, function (err, data) {
+    if (err) {
+        //error — GET failed
+    } else {
+        //success — data will contain raw results from API call        
+    }
+});
+```
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/c8b7d6c5/website/content/docs/old-forks.md
----------------------------------------------------------------------
diff --git a/website/content/docs/old-forks.md b/website/content/docs/old-forks.md
new file mode 100644
index 0000000..276e694
--- /dev/null
+++ b/website/content/docs/old-forks.md
@@ -0,0 +1,35 @@
+---
+title: What about old forks of Apigee Usergrid?
+category: docs
+layout: docs
+---
+If you previously developed with Apigee Usergrid (i.e. before we moved to Apache), you know our code used to be structured into _separate_ repositories: usergrid-stack, usergrid-portal, etc. We are now using a _merged_ repository.
+
+### How to update your code setup & pull changes from your old forks
+
+You just need to clone this repository, and use [git subtree (usually requires git 1.8+)](http://engineeredweb.com/blog/how-to-install-git-subtree/) to merge your changes under the new structure. Here’s an example for a portal fork. Adjust the prefix, repository address and branch you want to pull from as necessary.
+
+    git clone git@github.com:apache/incubator-usergrid.git
+    cd usergrid
+    git subtree pull --prefix=portal git@github.com:my-github-account/my-usergrid-portal-fork.git master
+
+This will pull (i.e. merge) the changes you made from the master branch of github.com/my-github-account/my-usergrid-portal-fork into the portal/ subfolder. It should ask you to provide a commit message for the merge. There’s lot of flexibility on how to fetch and merge, [please see the git subtree manual](https://github.com/git/git/blob/master/contrib/subtree/git-subtree.txt) for details. Then please do consider sending us a pull request with these changes ;)
+
+
+### How to pull commits made on this repo into your old forks
+
+You should really update your old repositories to the new structure with the instructions above, but the following may work for you, although we make no guarantee they will work in the future.
+
+You can produce a branch compatible with the old repos by using [git subtree (usually requires git 1.8+)](http://engineeredweb.com/blog/how-to-install-git-subtree/). Then from this repository you can
+
+    git clone git@github.com:apache/incubator-usergrid.git
+    cd usergrid
+    git checkout master
+    git subtree split --prefix=portal -b portal
+    git checkout portal
+
+This will create a “portal” branch that is compatible with the old usergrid-portal repository, from the code under the portal/ directory. You can pull from that branch (or push changes to it, although we will not accept pull requests sent thusly).
+
+The `git subtree split` above should function for portal, ugc, and any of the SDKs, but will not work for the stack, due to some anonymous comments left in the tree that prevent a split, and cannot be corrected lest we break the history and force a rebase on all forks.
+
+**Please update your code setup as soon as possible and [ask the dev list](https://mail-archives.apache.org/mod_mbox/incubator-usergrid-dev/) if you have any questions!**

http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/c8b7d6c5/website/content/docs/organization.md
----------------------------------------------------------------------
diff --git a/website/content/docs/organization.md b/website/content/docs/organization.md
new file mode 100644
index 0000000..388e4e0
--- /dev/null
+++ b/website/content/docs/organization.md
@@ -0,0 +1,1266 @@
+---
+title: Organization
+category: docs
+layout: docs
+---
+
+An organization represents the highest level of the Apache Usergrid data
+hierarchy. It contains applications (and the entities and collections
+they contain) and is associated with one or more administrators. An
+organization can be representative of a company, team, or project. It
+allows multiple applications  to be shared within the organization with
+other administrators.
+
+Using the App services API, you can create an organization through a
+form post and get an organization by UUID or name. In addition, you can
+activate or reactivate an organization, generate and retrieve an
+organization's client credentials, and get an organization's activity
+feed. You can also create an organization application through a form
+post, generate and retrieve credentials for the application, and delete
+the application. You can also get the applications in an organization.
+Additionally, you can add an admin user to an organization, get the
+admin users in an organization, and remove an admin user from an
+organization.
+
+Creating an organization
+------------------------
+
+Use the POST method to create an organization through a form post.
+
+### Request URI
+
+POST /organizations|orgs {request body}
+
+### Parameters
+
+Parameter
+
+Description
+
+request body
+
+The following set of organization properties supplied through a form:
+
+Property
+
+Description
+
+organization (string)
+
+The name of the organization.
+
+username (string)
+
+The username of the administrator.
+
+name (string)
+
+The name of the administrator.
+
+email (string)
+
+The email address of the administrator.
+
+password (string)
+
+The password of the administrator.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_create_org)
+-   [JavaScript (HTML5)](#javascript_create_org)
+-   [Ruby](#ruby_create_org)
+-   [Node.js](#nodejs_create_org)
+
+
+```bash
+$ curl -X POST "https://api.usergrid.com/management/orgs" \
+       -d '{"password":"test12345","email":"tester123@hotmail.com","name":"test","username":"test123","organization":"testorg"}'
+```
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+````ruby
+mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+management.create_organization 'testorg', 'test123', 'test', 'tester123@hotmail.com', 'test12345'
+````
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+```javascript
+var options = {
+    method:'POST',
+    endpoint:'management/orgs',
+    body:{ 
+          password:'test12345', 
+          email:'tester12345@gmail.com', 
+          name:'test', 
+          username:'tes123', 
+          organization:'testorg' 
+    }    
+};
+client.request(options, function (err, data) {
+    if (err) {
+        //error — POST failed
+    } else {
+        //success — data will contain raw results from API call        
+    }
+});
+```
+
+### Example - Response
+
+```javascript
+{
+  "action": "new organization",
+  "status": "ok",
+  "data":  {
+    "owner":  {
+      "applicationId": "00000000-0000-0000-0000-000000000001",
+      "username": "tester123",
+      "name": "test",
+      "email": "tester123@hotmail.com",
+      "activated": false,
+      "disabled": false,
+      "uuid": "48c92c73-0d7e-11e2-98b9-12313d288ee0",
+      "adminUser": true,
+      "displayEmailAddress": "tester123 <te...@hotmail.com>",
+      "htmldisplayEmailAddress": "tester123 <<a href="mailto:tester123@hotmail.com">tester123@hotmail.com</a>>"
+    },
+    "organization":  {
+      "name": "testorg",
+      "uuid": "5de0bb69-0d7f-11e2-87b9-12313d288ff0"
+    }
+  },
+  "timestamp": 1349284674173,
+  "duration": 21376
+}
+```
+
+Getting an organization
+-----------------------
+
+Use the GET method to retrieve an organization given a specified UUID or
+username.
+
+### Request URI
+
+GET /organizations|orgs/{org\_name}|{uuid}
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_org)
+-   [JavaScript (HTML5)](#javascript_get_org)
+-   [Ruby](#ruby_get_org)
+-   [Node.js](#nodejs_get_org)
+
+```bash
+curl -X GET "https://api.usergrid.com/management/orgs/testorg"
+```
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+```ruby
+mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+org = mgmt.organization 'testorg'
+```
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+```javascript
+var options = {
+    method:'GET',
+    endpoint:'management/orgs/testorg'
+};
+client.request(options, function (err, data) {
+    if (err) {
+        //error — GET failed
+    } else {
+        //success — data will contain raw results from API call        
+    }
+});
+```
+
+### Example - Response
+
+```javascript
+{
+  "timestamp": 1349286861746,
+  "duration": 18,
+  "organization":  {
+    "users":  {
+      "tester123":  {
+        "applicationId": "00000000-0000-0000-0000-000000000001",
+        "username": "tester123",
+        "name": "test",
+        "email": "tester123@hotmail.com",
+        "activated": true,
+        "disabled": false,
+        "uuid": "327b527f-cd0c-11e1-bcf7-12313d1c4491",
+        "adminUser": true,
+        "displayEmailAddress": "tester123 <te...@hotmail.com>",
+        "htmldisplayEmailAddress": "tester123 <<a href="mailto:tester123@hotmail.com">tester123@hotmail.com</a>>"
+      }
+    },
+    "name": "testorg",
+    "applications":  {
+      "tester123/sandbox": "3400ba10-cd0c-11e1-bcf7-12313d1c4491",
+      "tester123/testapp1": "be08a5f9-fdd3-11e1-beca-12313d027471",
+      "tester123/testapp2": "cede5b7e-fe90-11e1-95c8-12313b122c56"
+    },
+    "uuid": "33dd0563-cd0c-11e1-bcf7-12313d1c4491"
+  }
+```
+
+Activating an organization
+--------------------------
+
+Use the GET method to activate an organization from a link provided in
+an email notification.
+
+### Request URL
+
+GET
+/organizations|orgs/{org\_name}|{uuid}/activate?token={token}&confirm={confirm\_email}
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -------------------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+  string token                Activation token (supplied via email).
+  boolean confirm\_email      Send confirmation email (false is the default).
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_activate_org)
+-   [JavaScript (HTML5)](#javascript_activate_org)
+-   [Ruby](#ruby_activate_org)
+-   [Node.js](#nodejs_activate_org)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/activate?token=33dd0563-cd0c-11e1-bcf7-12313d1c4491"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/activate'].get params: { token: '33dd0563-cd0c-11e1-bcf7-12313d1c4491' }
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/activate',
+        qs:{token:'33dd0563-cd0c-11e1-bcf7-12313d1c4491'}
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "activate organization",
+      "timestamp": 1337928462810,              
+      "duration": 3342
+    }
+
+Reactivating an organization
+----------------------------
+
+Use the GET method to reactivate an organization.
+
+### Request URI
+
+GET /organizations|orgs/{org\_name}|{uuid}/reactivate
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_reactivate_org)
+-   [JavaScript (HTML5)](#javascript_reactivate_org)
+-   [Ruby](#ruby_reactivate_org)
+-   [Node.js](#nodejs_reactivate_org)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/reactivate"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+ 
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/reactivate']
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/reactivate'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "reactivate organization",
+      "timestamp": 1349385280891,
+      "duration": 3612
+    }
+
+Generating organization client credentials
+------------------------------------------
+
+Use the POST method to generate new credentials for an organization
+client.
+
+### Request URI
+
+POST /organizations|orgs/{org\_name}|{uuid}/credentials
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_gen_org_credentials)
+-   [JavaScript](#javascript_gen_org_credentials)
+-   [Ruby](#ruby_gen_org_credentials)
+-   [Node.js](#nodejs_gen_org_credentials)
+
+<!-- -->
+
+    curl -X POST "https://api.usergrid.com/management/orgs/credentials"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/credentials'].create
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'POST',
+        endpoint:'management/orgs/credentials'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — POST failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "generate organization client credentials",
+      "timestamp": 1349385795647,
+      "duration": 7,
+      "credentials":  {
+        "client_id": "c2V7N61DY90MCdG78xIxPRxFdQ",                  
+        "client_secret": "c2V7WEdXIutZWEkWdySLCt_lYDFVMMN"                      
+      }
+    }
+
+Retrieving organization client credentials
+------------------------------------------
+
+Use the GET method to retrieve the credentials for an organization
+client.
+
+### Request URL
+
+GET /organizations|orgs/{org\_name}|{uuid}/credentials
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_org_credentials)
+-   [JavaScript (HTML5)](#javascript_get_org_credentials)
+-   [Ruby](#ruby_get_org_credentials)
+-   [Node.js](#nodejs_get_org_credentials)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/credentials"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/credentials']
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/credentials'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "get organization client credentials",
+      "timestamp": 1349386672984,
+      "duration": 690,
+      "credentials":  {
+        "client_id": "c2V7N61DY90MCdG78xIxPRxFdQ",                  
+        "client_secret": "c2V7WEdXIutZWEkWdySLCt_lYDFVMMN"                      
+      }
+    }
+
+Getting an organization's activity feed
+---------------------------------------
+
+Use the GET method to get an organization's activity feed.
+
+### Request URI
+
+GET /organizations|orgs/{org\_name}|{uuid}/feed
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_org_feed)
+-   [JavaScript (HTML5)](#javascript_get_org_feed)
+-   [Ruby](#ruby_get_org_feed)
+-   [Node.js](#nodejs_get_org_feed)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/feed"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    activities = mgmt['orgs/testorg/feed'].collection
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/feed'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+     {
+      "action": "get organization feed",
+      "status": "ok",
+      "entities":  [
+         {
+          "uuid": "cf4d981c-fe90-11e1-95c8-12313b122c56",
+          "type": "activity",
+          "created": 1347643370454,
+          "modified": 1347643370454,
+          "actor":  {
+            "displayName": "tester123",
+            "objectType": "person",
+            "uuid": "327b527f-cd0c-11e1-bcf7-12313d1c4491",
+            "entityType": "user"
+          },
+          "category": "admin",
+          "metadata":  {
+            "cursor": "gGkAAQMAgGkABgE5xc3r1gCAdQAQz02YHP6QEeGVyBIxOxIsVgCAdQAQz3SoH_6QEeGVyBIxOxIsVgA",
+            "path": "/groups/33dd0563-cd0c-11e1-bcf7-12313d1c4491/feed/cf4d981c-fe90-11e1-95c8-12313b122c56"
+          },
+    "object":  {
+            "displayName": "testapp2",
+            "objectType": "Application",
+            "uuid": "cede5b7e-fe90-11e1-95c8-12313b122c56",
+            "entityType": "application_info"
+          },
+          "published": 1347643370454,
+          "title": "<a mailto="mailto:tester123@hotmail.com">tester123 (tester123@hotmail.com)</a> created a new application named testapp2",
+          "verb": "create"
+        },...
+    ,
+      "timestamp": 1349387253811,
+
+Creating an organization application
+------------------------------------
+
+Use the POST method to create an application for an organization through
+a form post.
+
+### Request URI
+
+POST /organizations|orgs/{org\_name}|{org\_uuid}/apps {request body}
+
+### Parameters
+
+Parameter
+
+Description
+
+request body
+
+The following set of organization properties supplied through a form:.
+
+Property
+
+Description
+
+access token (string)
+
+The OAuth2 access token.
+
+name (string)
+
+The name of the application.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_create_org_app)
+-   [JavaScript (HTML5)](#javascript_create_org_app)
+-   [Ruby](#ruby_create_org_app)
+-   [Node.js](#nodejs_create_org_app)
+
+<!-- -->
+
+    curl -X -i POST "https://api.usergrid.com/management/orgs/testorg/apps" -d '{"access_token":"YWMtmNIFFBI6EeKvXSIACowF7QAAATpL0bVQtGOWe8PMwLfQ9kD_VKQa7IH4UBQ","name":"testapp1"}'
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+ 
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mynewapp = mgmt['orgs/testorg/apps'].create name: 'testapp1', access_token: 'YWMtmNIFFBI6EeKvXSIACowF7QAAATpL0bVQtGOWe8PMwLfQ9kD_VKQa7IH4UBQ'
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'POST',
+        endpoint:'management/orgs/testorg/apps',
+        body:{ 
+              access_token:'YWMtmNIFFBI6EeKvXSIACowF7QAAATpL0bVQtGOWe8PMwLfQ9kD_VKQa7IH4UBQ', 
+              name:'testapp1' 
+        }    
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — POST failed
+        } else {
+            //success — data will contain raw results from API call        
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "new application for organization",
+      "timestamp": 1338914698135,
+      "duration": 701
+    }
+
+Deleting an organization application
+------------------------------------
+
+Use the DELETE method to delete an application from an organization.
+
+### Request URI
+
+DELETE
+/organizations|orgs/{org\_name}|{org\_uuid}/apps/{app\_name}|{app\_uuid}
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+  string app\_name|arg uuid   Application name or application UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_delete_org_app)
+-   [JavaScript (HTML5)](#javascript_delete_org_app)
+-   [Ruby](#ruby_delete_org_app)
+-   [Node.js](#nodejs_delete_org_app)
+
+<!-- -->
+
+    curl -X DELETE "https://api.usergrid.com/management/orgs/testorg/apps/testapp1"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+ 
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/apps/testapp1'].delete
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'DELETE',
+        endpoint:'management/orgs/testorg/apps/testapp1'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — DELETE failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "delete application from organization",
+      "timestamp": 1349817715666,
+      "duration": 0
+    }
+
+Generating application credentials
+----------------------------------
+
+Use the POST method to generate the client ID and client secret
+credentials for an application in an organization.
+
+### Request URI
+
+POST
+/organizations|orgs/{org\_name}|{uuid}/applications|apps/{app\_name}|{uuid}/credentials
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+  string app\_name|arg uuid   Application name or application UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_gen_app_credentials)
+-   [JavaScript (HTML5)](#javascript_gen_app_credentials)
+-   [Ruby](#ruby_gen_app_credentials)
+-   [Node.js](#nodejs_gen_app_credentials)
+
+<!-- -->
+
+    curl -X POST "https://api.usergrid.com/management/orgs/testorg/apps/testapp1/credentials"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/apps/testapp1/credentials'].create
+
+The example assumes use of the [Node.js
+module](https://github.com/scottganyo/usergrid_iron).
+
+    var options = {
+        method:'POST',
+        endpoint:'management/orgs/testorg/apps/testapp1/credentials'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — POST failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "generate application client credentials",
+      "timestamp": 1349815979529,
+      "duration": 535,
+      "credentials":  {
+        "client_id": "YXA7ygil-f3TEeG-yhIxPQK1cQ",
+        "client_secret": "YXA65gYlqja8aYYSAy8Ox3Vg5aRZp48"
+      }
+    }
+
+Getting application credentials
+-------------------------------
+
+Use the GET method to retrieve the client ID and client secret
+credentials for an application in an organization.
+
+### Request URI
+
+GET
+/organizations|orgs/{org\_name}|{uuid}/applications|apps/{app\_name}|{uuid}/credentials
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+  string app\_name|arg uuid   Application name or application UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_app_credentials)
+-   [JavaScript (HTML5)](#javascript_get_app_credentials)
+-   [Ruby](#ruby_get_app_credentials)
+-   [Node.js](#nodejs_get_app_credentials)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/apps/testapp1/credentials"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/apps/testapp1/credentials']
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/apps/testapp1/credentials'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "get application client credentials",
+      "timestamp": 1349816819545,
+      "duration": 7,
+      "credentials":  {
+        "client_id": "YXA7ygil-f3TEeG-yhIxPQK1cQ",
+        "client_secret": "YXA65gYlqja8aYYSAy8Ox3Vg5aRZp48"
+      }
+    }
+
+Getting the applications in an organization
+-------------------------------------------
+
+Use the GET method to retrieve the applications in an organization.
+
+### Request URI
+
+GET /organizations|orgs/{org\_name}|{uuid}/applications|apps
+
+Parameters
+
+  Parameter                   Description
+  --------------------------- -----------------------------------------
+  string org\_name|arg uuid   Organization name or organization UUID.
+
+**Note:** You also need to provide a valid access token with the API
+call. See [Authenticating users and application
+clients](/authenticating-users-and-application-clients) for details.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_apps_org)
+-   [JavaScript (HTML5)](#javascript_get_apps_org)
+-   [Ruby](#ruby_get_apps_org)
+-   [Node.js](#nodejs_get_apps_org)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/apps"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+ 
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    apps = mgmt['orgs/testorg/apps'].collection
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/apps'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+ 
+
+### Example - Response
+
+    {
+      "action": "get organization application",
+      "data":  {
+        "testorg/sandbox": "3500ba10-cd0c-11e1-bcf8-12313d1c5591",
+        "testorg/testapp1": "be09a5f9-fdd3-11e1-beca-12313d027361",
+        "testorg/testapp2": "cede5b8e-fe90-11e1-65c8-12313b111c56"    
+      },
+      "timestamp": 1349815338635,
+      "duration": 22
+    }
+
+Adding an admin user to an organization
+---------------------------------------
+
+Use the PUT method to add an existing admin user to an organization.
+
+### Request URI
+
+PUT
+/organizations|orgs/{org\_name}|{org\_uuid}/users/{username|email|uuid}
+
+### Parameters
+
+  Parameter                               Description
+  --------------------------------------- ----------------------------------------------
+  string org\_name|arg org\_uuid          Organization name or organization UUID.
+  string username|string email|arg uuid   User name, user email address, or user UUID.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_add_admin_user)
+-   [JavaScript (HTML5)](#javascript_add_admin_user)
+-   [Ruby](#ruby_add_admin_user)
+-   [Node.js](#nodejs_add_admin_user)
+
+<!-- -->
+
+    curl -X PUT "https://api.usergrid.com/management/orgs/testorg/users/test123"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/users/test123'].put nil
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'PUT',
+        endpoint:'management/orgs/testorg/users/test123'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — PUT failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "add user to organization",
+      "status": "ok",
+      "data":  {
+        "user":  {
+          "applicationId": "00000000-0000-0000-0000-000000000001",
+          "username": "tester123",
+          "name": "test",
+          "email": "tester123@hotmail.com",
+          "activated": true,
+          "disabled": false,
+          "uuid": "335b527f-cd0d-11e1-bef8-12331d1c5591",
+          "adminUser": true,
+          "displayEmailAddress": "tester123 <te...@hotmail.com>",
+          "htmldisplayEmailAddress": "tester123 <<a href="mailto:tester123@hotmail.com">tester123@hotmail.com</a>>"
+        }
+      },
+      "timestamp": 1349390189106,
+      "duration": 11808
+    }
+
+Getting the admin users in an organization
+------------------------------------------
+
+Use the GET method to retrieve details about the admin users in an
+organization.
+
+### Request URI
+
+GET /organizations|orgs/{org\_name}|{org\_uuid}/users
+
+### Parameters
+
+  Parameter                        Description
+  -------------------------------- -----------------------------------------
+  string org\_name|arg org\_uuid   Organization name or organization UUID.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_get_admin_users)
+-   [JavaScript (HTML5)](#javascript_get_admin_users)
+-   [Ruby](#ruby_get_admin_users)
+-   [Node.js](#nodejs_get_admin_users)
+
+<!-- -->
+
+    curl -X GET "https://api.usergrid.com/management/orgs/testorg/users"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    admins = mgmt['orgs/testorg/users']
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'GET',
+        endpoint:'management/orgs/testorg/users'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — GET failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "get organization users",
+      "data":  {
+        "user":  {
+          "applicationId": "00000000-0000-0000-0000-000000000001",
+          "username": "tester123",
+          "name": "test",
+          "email": "tester123@hotmail.com",
+          "activated": true,
+          "disabled": false,
+          "uuid": "335b527f-cd0d-11e1-bef8-12331d1c5591",
+          "adminUser": true,
+          "displayEmailAddress": "tester123 <te...@hotmail.com>",
+          "htmldisplayEmailAddress": "tester123 <<a href="mailto:tester123@hotmail.com">tester123@hotmail.com</a>>"
+        }
+      },
+      "timestamp": 13494542201685,
+      "duration": 10
+    }
+
+Removing an admin user from an organization
+-------------------------------------------
+
+Use the DELETE method to remove an admin user from an organization.
+
+### Request URI
+
+DELETE
+/organizations|orgs/{org\_name}|{org\_uuid}/users/{username|email|uuid}
+
+### Parameters
+
+  Parameter                               Description
+  --------------------------------------- ----------------------------------------------
+  string org\_name|arg org\_uuid          Organization name or organization UUID.
+  string username|string email|arg uuid   User name, user email address, or user UUID.
+
+ 
+
+### Example - Request
+
+-   [cURL](#curl_delete_admin_user)
+-   [JavaScript (HTML5)](#javascript_delete_admin_user)
+-   [Ruby](#ruby_delete_admin_user)
+-   [Node.js](#nodejs_delete_admin_user)
+
+<!-- -->
+
+    curl -X DELETE "https://api.usergrid.com/management/orgs/testorg/users/test123"
+
+It is recommended that you use the [Admin
+Portal](http://apigee.com/usergrid) for administrative activities
+instead of using JavaScript to do them programmatically in your app.
+
+**Note:**You can see the response below in the Admin Portal by using the
+[JavaScript
+Console](/docs/usergrid/content/displaying-app-services-api-calls-curl-commands).
+
+The example assumes use of the [Ruby
+SDK](https://github.com/scottganyo/usergrid_iron).
+
+    mgmt = Usergrid::Management.new 'https://api.usergrid.com/'
+    mgmt['orgs/testorg/users/test123'].delete
+
+The example assumes use of the [Node.js
+module](https://github.com/apigee/usergrid-node-module).
+
+    var options = {
+        method:'DELETE',
+        endpoint:'management/orgs/testorg/users/test123'
+    };
+    client.request(options, function (err, data) {
+        if (err) {
+            //error — DELETE failed
+        } else {
+            //success — data will contain raw results from API call       
+        }
+    });
+
+### Example - Response
+
+    {
+      "action": "remove user from organization",
+      "status": "ok",
+      "data":  {
+        "user":  {
+          "applicationId": "00000000-0000-0000-0000-000000000001",
+          "username": "tester123",
+          "name": "test",
+          "email": "tester123@hotmail.com",
+          "activated": true,
+          "disabled": false,
+          "uuid": "335b527f-cd0d-11e1-bef8-12331d1c5591",
+          "adminUser": true,
+          "displayEmailAddress": "tester123 <te...@hotmail.com>",
+          "htmldisplayEmailAddress": "tester123 <<a href="mailto:tester123@hotmail.com">tester123@hotmail.com</a>>"
+        }
+      },
+      "timestamp": 1349453590005,
+      "duration": 727
+    }
+
+