<commit_before>##Quickstart
Detailed instructions follow but if you just want a quick example of how to get started with this SDK, here’s a minimal HTML5 file that shows you how to include & initialize the SDK, as well as how to read & write data from Usergrid with it.

```html
<!DOCTYPE html>
<html>
	<head>
		<!-- Don't forget to include the SDK -->
		<script src="https://apigee.com/usergrid/sdk/usergrid.0.10.5.js"></script>
		<!-- If you prefer a local copy, you can find the file at the root the SDK’s github repo
		     github.com/apigee/usergrid-javascript-sdk -->

		<script type="text/javascript">

		
			// Initializing the SDK
			var client = new Usergrid.Client({
				orgName:'yourorgname', // Your Usergrid organization name (or apigee.com username for App Services)
				appName:'sandbox' // Your Usergrid app name
			});

			// Make a new "book" collection and read data
			var options = {
				type:'books',
				qs:{ql:'order by created DESC'}
			}

			var books;

			client.createCollection(options, function (err, books) {
    			if (err) {
    				alert("Couldn't get the list of books.");
    			} else {
    				while(books.hasNextEntity()) {
    					var book = books.getNextEntity();
    					alert(book.get("title")); // Output the title of the book
    				}
    			}
    		});

			// Uncomment the next 4 lines if you want to write data

			// book = { "title": "the old man and the sea" };
			// books.addEntity(book, function (error, response) {
			// 	if (error) { alert("Couldn't add the book.");
			// 	} else { alert("The book was added."); } });
		</script>
	</head>
	<body></body>
</html>
```

##Version

Current Version: **0.10.7**

See change log:

<https://github.com/apigee/usergrid-javascript-sdk/blob/master/changelog.md>

##Comments / questions
For help using this SDK, reach out on the Usergrid google group:

https://groups.google.com/forum/?hl=en#!forum/usergrid

Or just open github issues. 



##Overview
This open source SDK simplifies writing JavaScript / HTML5 applications that connect to App Services. The repo is located here:

<https://github.com/apigee/usergrid-javascript-sdk>

You can download this package here:

* Download as a zip file: <https://github.com/apigee/usergrid-javascript-sdk/archive/master.zip>
* Download as a tar.gz file: <https://github.com/apigee/usergrid-javascript-sdk/archive/master.tar.gz>


To find out more about Apigee App Services, see:

<http://developers.apigee.com>

To view the Apigee App Services documentation, see:

<http://apigee.com/docs/app_services>


##Node.js
Want to use Node.js? No problem - use the Usergrid Node Module:

<https://npmjs.org/package/usergrid>

or on github:

<https://github.com/apigee/usergrid-node-module>

The syntax for this Javascript SDK and the Usergrid Node module are almost exactly the same so you can easily transition between them.


##About the samples
This SDK comes with a variety of samples that you can use to learn how to connect your project to App Services (Usergrid). See these examples running live now:

<http://apigee.github.com/usergrid-javascript-sdk/>

**Note:** All the sample code in this file is pulled directly from the "test" example, so you can rest-assured that it will work! You can run them yourself here:

<http://apigee.github.com/usergrid-javascript-sdk/examples/test/test.html>


##Installing
Once you have downloaded the SDK, add the usergrid.js file to your project. This file is located in the root of the SDK. Include it in the top of your HTML file (in between the head tags):

	<script src="path/to/usergrid.js" type="text/javascript"></script>

##Getting started
You are now ready to create a new `Client` object, which is the main entry point in the SDK:

	var client = new Usergrid.Client({
		orgName:'yourorgname',
		appName:'sandbox',
		logging: true, // Optional - turn on logging, off by default
		buildCurl: true // Optional - turn on curl commands, off by default
	});

The last two items are optional. The `logging` option will enable console.log output from the client, and will output various bits of information (calls that are being made, errors that happen).  The `buildCurl` option will cause cURL equivalent commands of all calls to the API to be displayed in the console.log output (see more about this below).

**Note:** You can find your organization name and application in the [Admin Portal](http://apigee.com/usergrid).<commit_msg>updated gh-pages links<commit_after>##Quickstart
Detailed instructions follow but if you just want a quick example of how to get started with this SDK, here’s a minimal HTML5 file that shows you how to include & initialize the SDK, as well as how to read & write data from Usergrid with it.

```html
<!DOCTYPE html>
<html>
	<head>
		<!-- Don't forget to include the SDK -->
		<script src="https://apigee.com/usergrid/sdk/usergrid.0.10.5.js"></script>
		<!-- If you prefer a local copy, you can find the file at the root the SDK’s github repo
		     github.com/apigee/usergrid-javascript-sdk -->

		<script type="text/javascript">

		
			// Initializing the SDK
			var client = new Usergrid.Client({
				orgName:'yourorgname', // Your Usergrid organization name (or apigee.com username for App Services)
				appName:'sandbox' // Your Usergrid app name
			});

			// Make a new "book" collection and read data
			var options = {
				type:'books',
				qs:{ql:'order by created DESC'}
			}

			var books;

			client.createCollection(options, function (err, books) {
    			if (err) {
    				alert("Couldn't get the list of books.");
    			} else {
    				while(books.hasNextEntity()) {
    					var book = books.getNextEntity();
    					alert(book.get("title")); // Output the title of the book
    				}
    			}
    		});

			// Uncomment the next 4 lines if you want to write data

			// book = { "title": "the old man and the sea" };
			// books.addEntity(book, function (error, response) {
			// 	if (error) { alert("Couldn't add the book.");
			// 	} else { alert("The book was added."); } });
		</script>
	</head>
	<body></body>
</html>
```

##Version

Current Version: **0.10.7**

See change log:

<https://github.com/apigee/usergrid-javascript-sdk/blob/master/changelog.md>

##Comments / questions
For help using this SDK, reach out on the Usergrid google group:

https://groups.google.com/forum/?hl=en#!forum/usergrid

Or just open github issues. 



##Overview
This open source SDK simplifies writing JavaScript / HTML5 applications that connect to App Services. The repo is located here:

<https://github.com/apigee/usergrid-javascript-sdk>

You can download this package here:

* Download as a zip file: <https://github.com/apigee/usergrid-javascript-sdk/archive/master.zip>
* Download as a tar.gz file: <https://github.com/apigee/usergrid-javascript-sdk/archive/master.tar.gz>


To find out more about Apigee App Services, see:

<http://developers.apigee.com>

To view the Apigee App Services documentation, see:

<http://apigee.com/docs/app_services>


##Node.js
Want to use Node.js? No problem - use the Usergrid Node Module:

<https://npmjs.org/package/usergrid>

or on github:

<https://github.com/apigee/usergrid-node-module>

The syntax for this Javascript SDK and the Usergrid Node module are almost exactly the same so you can easily transition between them.


##About the samples
This SDK comes with a variety of samples that you can use to learn how to connect your project to App Services (Usergrid). See these examples running live now:

<http://apigee.github.io/usergrid-javascript-sdk>

**Note:** All the sample code in this file is pulled directly from the "test" example, so you can rest-assured that it will work! You can run them yourself here:

<http://apigee.github.io/usergrid-javascript-sdk/examples/test/test.html>


##Installing
Once you have downloaded the SDK, add the usergrid.js file to your project. This file is located in the root of the SDK. Include it in the top of your HTML file (in between the head tags):

	<script src="path/to/usergrid.js" type="text/javascript"></script>

##Getting started
You are now ready to create a new `Client` object, which is the main entry point in the SDK:

	var client = new Usergrid.Client({
		orgName:'yourorgname',
		appName:'sandbox',
		logging: true, // Optional - turn on logging, off by default
		buildCurl: true // Optional - turn on curl commands, off by default
	});

The last two items are optional. The `logging` option will enable console.log output from the client, and will output various bits of information (calls that are being made, errors that happen).  The `buildCurl` option will cause cURL equivalent commands of all calls to the API to be displayed in the console.log output (see more about this below).

**Note:** You can find your organization name and application in the [Admin Portal](http://apigee.com/usergrid).
{'fraction_non_alphanumeric': 0.10930074677528853, 'fraction_numerical': 0.0024892509617560534, 'mean_word_length': 3.558535327488396, 'pattern_counts': {'":': 2, '<': 53, '<?xml version=': 0, '>': 53, 'https://': 16, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 8, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '795435', 'n_tokens_mistral': 2834, 'n_tokens_neox': 2586, 'n_words': 1057}