You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by mr...@apache.org on 2016/09/02 17:39:42 UTC

[01/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Repository: usergrid
Updated Branches:
  refs/heads/master 9943e4bcb -> 867060fa7


http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/collection.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/collection.rb b/sdks/ruby/lib/usergrid/core/collection.rb
deleted file mode 100644
index 02ac9fd..0000000
--- a/sdks/ruby/lib/usergrid/core/collection.rb
+++ /dev/null
@@ -1,121 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-module Usergrid
-  class Collection < Entity
-    include Enumerable
-
-    attr_accessor :iterator_follows_cursor
-
-    def initialize(url, api_url, options={}, response=nil)
-      super url, api_url, options, response
-      @iterator_follows_cursor = false
-    end
-
-    def collection
-      self
-    end
-
-    def entities
-      get unless response
-      response.entities
-    end
-
-    def [](k)
-      entities[k]
-    end
-
-    def []=(k,v)
-      raise "unsupported operation"
-    end
-
-    # does not save entities! just fields (eg. 'name')
-    def save
-      super save
-    end
-
-    def each(&block)
-      entities.each &block
-      while cursor
-        next_page
-        entities.each &block
-      end if iterator_follows_cursor
-    end
-
-    # use in conjunction with each() like: collection.follow_cursor.each {|e| }
-    def follow_cursor
-      my_clone = self.clone
-      my_clone.iterator_follows_cursor = true
-      my_clone
-    end
-
-    def create_entity(data)
-      self.post data
-    end
-    alias_method :create_entities, :create_entity
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def update_query(updates, query=nil, options={})
-      options = options.symbolize_keys
-      query_params = query ? options.merge({ql: query}) : options
-      self.put(updates, {params: query_params })
-      self
-    end
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def delete_query(query=nil, options={})
-      options = options.symbolize_keys
-      query_params = query ? options.merge({ql: query}) : options
-      self.delete({params: query_params })
-      self
-    end
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def query(query=nil, options={})
-      options = options.symbolize_keys
-      query_params = query ? options.merge({ql: query}) : options
-      self.get({params: query_params })
-      self
-    end
-
-    def size
-      entities.size
-    end
-
-    def empty?
-      entities.empty?
-    end
-
-    def cursor
-      response.data['cursor']
-    end
-
-    def next_page
-      query(nil, query_params.merge({cursor: cursor}))
-    end
-
-    protected
-
-    def query_params
-      params = {}
-      if response.data['params']
-        response.data['params'].each do |k,v|
-          params[k] = v[0]
-        end
-      end
-      params
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/entity.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/entity.rb b/sdks/ruby/lib/usergrid/core/entity.rb
deleted file mode 100644
index 1539b58..0000000
--- a/sdks/ruby/lib/usergrid/core/entity.rb
+++ /dev/null
@@ -1,80 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# also allows hash or dot notation for entity properties
-module Usergrid
-  class Entity < Resource
-
-    def initialize(url, api_url, options={}, response=nil, index=nil)
-      super url, api_url, options, response
-      @index = index
-    end
-
-    def data
-      get unless response
-      @index ? response.entities_data[@index] : response.entity_data
-    end
-
-    def data?
-      !!response
-    end
-
-    def resource
-      Resource.new url, api_url, options
-    end
-
-    def [](k)
-      data[k]
-    end
-
-    def []=(k,v)
-      data[k] = v
-    end
-
-    def collection
-      Collection.new url[0..url[0..-2].rindex('/')-1], api_url, options
-    end
-
-    def save
-      self.put data
-    end
-
-    def to_s
-      "resource: #{url}\ndata: #{data}"
-    end
-
-    def to_json(*args)
-      data.except(RESERVED).to_json *args
-    end
-    alias :encode :to_json
-    alias :dump :to_json
-
-    private
-
-    def method_missing(method, *args, &block)
-      if data.respond_to?(method)
-        data.send(method, *args, &block)
-      elsif method[-1] == '=' && args.size == 1
-        data[method[0..-2]] = args[0]
-      else
-        super method, args, block
-      end
-    end
-
-    def respond_to?(method)
-      super.respond_to?(method) || data.respond_to?(method)
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/management.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/management.rb b/sdks/ruby/lib/usergrid/core/management.rb
deleted file mode 100644
index b8f3e06..0000000
--- a/sdks/ruby/lib/usergrid/core/management.rb
+++ /dev/null
@@ -1,57 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-module Usergrid
-  class Management < Resource
-
-    def initialize(url, options={})
-      management = url.split('/')[-1]
-      if management == 'management'
-        api_url = url[0..url.index(management)-2]
-      else
-        api_url = url
-        url = concat_urls(api_url, 'management')
-      end
-      super url, api_url, options
-    end
-
-    def create_organization(organization, username, name, email, password)
-      data = { organization: organization,
-               username: username,
-               name: name,
-               email: email,
-               password: password }
-      self['organizations'].post data
-    end
-
-    def organizations
-      self[__method__].get
-    end
-
-    def organization(organization)
-      url = self["organizations/#{organization}"].url
-      Organization.new url, options
-    end
-
-    def users
-      self['users'].get
-    end
-
-    def user(name_or_uuid)
-      self["users/#{name_or_uuid}"].get
-    end
-
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/organization.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/organization.rb b/sdks/ruby/lib/usergrid/core/organization.rb
deleted file mode 100644
index 9df485a..0000000
--- a/sdks/ruby/lib/usergrid/core/organization.rb
+++ /dev/null
@@ -1,74 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'uri'
-module Usergrid
-  class Organization < Resource
-
-    def initialize(url, options={})
-      org_name = url.split('/')[-1]
-      api_url = url[0..url.index('management')-2]
-      super url, api_url, options
-    end
-
-    def name
-      URI(url).path.split('/').last
-    end
-
-    def create_application(name)
-      self['applications'].post({ name: name })
-      application name
-    end
-
-    def applications(query=nil)
-      resource = self[__method__]
-      response = query ? resource.query(query) : resource.get
-      response.data['data'].collect do |k|
-        application concat_urls(api_url, k)
-      end
-    end
-
-    def application(name_or_uuid)
-      Usergrid::Application.new concat_urls(api_url, "#{name}/#{name_or_uuid}"), options
-    end
-
-    def users(query=nil)
-      self[__method__].query(query)
-    end
-
-    def user(user)
-      management.user(user)
-    end
-
-    def feed(query=nil)
-      self[__method__].query(query)
-    end
-
-    def credentials
-      self[__method__].get
-    end
-
-    def generate_credentials
-      self['credentials'].post nil
-    end
-
-    def login_credentials(client_id, client_secret)
-      resource = api_resource 'management'
-      response = resource['token'].post grant_type: 'client_credentials', client_id: client_id, client_secret: client_secret
-      self.auth_token = response.data['access_token']
-    end
-
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/resource.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/resource.rb b/sdks/ruby/lib/usergrid/core/resource.rb
deleted file mode 100644
index 1f96f90..0000000
--- a/sdks/ruby/lib/usergrid/core/resource.rb
+++ /dev/null
@@ -1,157 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'rest_client'
-
-module Usergrid
-  class Resource < RestClient::Resource
-
-    RESERVED = %w( created modified metadata uri )
-    DEFAULT_API_URL = 'https://api.usergrid.com'
-    TYPE_HEADERS = { content_type: :json, accept: :json }
-
-    attr_reader :current_user, :api_url, :response
-
-    def initialize(resource_url=DEFAULT_API_URL, api_url=nil, options={}, response=nil)
-      options[:headers] = TYPE_HEADERS.merge options[:headers] || {}
-      @api_url = api_url || resource_url
-      self.response = response
-      super resource_url, options, &method(:handle_response)
-    end
-
-    # gets user token and automatically set auth header for future requests
-    # precondition: resource must already be set to the correct context (application or management)
-    def login(username, password)
-      response = self['token'].post grant_type: 'password', username: username, password: password
-      self.auth_token = response.data['access_token']
-      user_uuid = response.data['user']['uuid']
-      @current_user = self["/users/#{user_uuid}"].get.entity
-      response
-    end
-
-    # remove auth header for future requests
-    # only affects self and derivative resources
-    def logout
-      self.auth_token = nil
-      @current_user = nil
-    end
-
-    def logged_in?
-      !!auth_token
-    end
-
-    def management
-      Usergrid::Management.new api_url, options
-    end
-
-    # application defaults to sandbox if none provided
-    def application(organization, application='sandbox')
-      Usergrid::Application.new concat_urls(api_url, "#{organization}/#{application}"), options
-    end
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def query(query=nil, options={})
-      options = options.merge({ql: query}) if query
-      get({params: options})
-    end
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def update_query(updates, query=nil, options={})
-      options = options.merge({ql: query}) if query
-      put(updates, {params: options})
-    end
-
-    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
-    def delete_query(query=nil, options={})
-      options = options.merge({ql: query}) if query
-      delete({params: options})
-    end
-
-    def entity
-      get unless response
-      response.entity
-    end
-
-    def entities
-      get unless response
-      response.entities
-    end
-
-    def collection
-      get unless response
-      Collection.new url, api_url, options, response
-    end
-
-    # overridden to ensure sub resources are instances of this class
-    def [](suburl, &new_block)
-      case
-        when block_given? then Resource.new(concat_urls(url, suburl), api_url, options, &new_block)
-        when block        then Resource.new(concat_urls(url, suburl), api_url, options, &block)
-        else
-          Resource.new(concat_urls(url, suburl), api_url, options)
-      end
-    end
-
-    def api_resource(suburl)
-      Resource.new(concat_urls(api_url, suburl), api_url, options)
-    end
-
-    def get(additional_headers={}, &block)
-      self.response = super additional_headers, &block
-    end
-
-    def post(payload, additional_headers={}, &block)
-      payload = MultiJson.dump(payload) unless payload.is_a? String
-      self.response = super payload, additional_headers, &block
-    end
-
-    def put(payload, additional_headers={}, &block)
-      payload = MultiJson.dump(payload) unless payload.is_a? String
-      self.response = super payload, additional_headers, &block
-    end
-
-    def auth_token=(auth_token)
-      if auth_token
-        @options[:headers].merge!({ Authorization: "Bearer #{auth_token}" })
-      else
-        @options[:headers].delete :Authorization if @options
-      end
-    end
-
-    def auth_token
-      begin
-        @options[:headers][:Authorization].gsub 'Bearer ', ''
-      rescue
-        nil
-      end
-    end
-
-    protected
-
-    def response=(response)
-      @response = response
-    end
-
-    # add verbose debugging of response body
-    def handle_response(response, request, result, &block)
-      LOG.debug "response.body = #{response}"
-      response = response.return!(request, result, &block)
-      response.resource = self
-      self.response = response
-      response
-    end
-
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/extensions/hash.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/extensions/hash.rb b/sdks/ruby/lib/usergrid/extensions/hash.rb
deleted file mode 100644
index 5a1cd30..0000000
--- a/sdks/ruby/lib/usergrid/extensions/hash.rb
+++ /dev/null
@@ -1,45 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-class Hash
-
-  # not recursive
-  def symbolize_keys
-    inject({}) do |options, (key, value)|
-      options[(key.to_sym rescue key) || key] = value
-      options
-    end
-  end
-
-  def except(*keys)
-    dup.except! *keys
-  end
-
-  def except!(*keys)
-    keys.each { |key| key.is_a?(Array) ? except!(*key) : delete(key) }
-    self
-  end
-
-  # recursive
-  def add_dot_notation!(_hash=self)
-    _hash.each do |k,v|
-      getter = k.to_sym; setter = "#{k}=".to_sym
-      _hash.define_singleton_method getter, lambda { _hash[k] } unless _hash.respond_to? getter
-      _hash.define_singleton_method setter, lambda { |v| _hash[k] = v } unless _hash.respond_to? setter
-      add_dot_notation!(v) if v.is_a? Hash
-      v.each { |e| add_dot_notation!(e) if e.is_a? Hash } if v.is_a? Array
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/extensions/response.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/extensions/response.rb b/sdks/ruby/lib/usergrid/extensions/response.rb
deleted file mode 100644
index ee2ffbf..0000000
--- a/sdks/ruby/lib/usergrid/extensions/response.rb
+++ /dev/null
@@ -1,96 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-module RestClient
-  module Response
-
-    def resource=(resource)
-      @resource = resource
-    end
-
-    def resource
-      @resource
-    end
-
-    def data
-      @data = MultiJson.load(self).add_dot_notation! unless @data
-      @data
-    end
-
-    def collection
-      resource.collection
-    end
-
-    def multiple_entities?
-      entities_data = data['entities'] || data['data'] || data['messages'] || data['list']
-      entities_data.is_a? Array
-    end
-
-    def entities_data
-      return @entities_data if @entities_data
-      entities_data = data['entities'] || data['data'] || data['messages'] || data['list']
-      raise "unable to determine entities from: #{data}" unless entities_data.is_a?(Array)
-      entities_data.each do |e|
-        e['uri'] = concat_urls(data['uri'], e['uuid']) if e.is_a?(Hash) && e['uuid']
-      end
-      @entities_data = entities_data
-    end
-
-    def entities
-      return @entities if @entities
-      index = -1
-      @entities = entities_data.collect do |e|
-        if e.is_a? Array
-          e
-        else
-          Usergrid::Entity.new e['uri'], resource.api_url, resource.options, self, index+=1
-        end
-      end
-    end
-
-    def entity_data
-      if multiple_entities?
-        entities_data.first
-      elsif data['data']
-        d = data['data']
-        d['uri'] = @resource.url
-        d
-      elsif data['organization']
-        d = data['organization']
-        d['uri'] = @resource.url
-        d
-      else
-        entities_data.first
-      end
-    end
-
-    def entity
-      Usergrid::Entity.new(entity_data['uri'], resource.api_url, resource.options, self) if entity_data
-    end
-
-    protected
-
-    def concat_urls(url, suburl) # :nodoc:
-      url = url.to_s
-      suburl = suburl.to_s
-      if url.slice(-1, 1) == '/' or suburl.slice(0, 1) == '/'
-        url + suburl
-      else
-        "#{url}/#{suburl}"
-      end
-    end
-
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/version.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/version.rb b/sdks/ruby/lib/usergrid/version.rb
deleted file mode 100644
index 951b017..0000000
--- a/sdks/ruby/lib/usergrid/version.rb
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-module Usergrid
-  VERSION = '0.9.2'
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid_iron.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid_iron.rb b/sdks/ruby/lib/usergrid_iron.rb
deleted file mode 100644
index 7bd209c..0000000
--- a/sdks/ruby/lib/usergrid_iron.rb
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'logger'
-require 'multi_json'
-
-
-module Usergrid
-
-  LOG = Logger.new(STDOUT)
-
-  USERGRID_PATH = File.join File.dirname(__FILE__), 'usergrid'
-
-  def self.usergrid_path *path
-    File.join USERGRID_PATH, *path
-  end
-
-  require usergrid_path('version')
-
-  require usergrid_path('extensions', 'hash')
-  require usergrid_path('extensions', 'response')
-
-  require usergrid_path('core', 'resource')
-  require usergrid_path('core', 'management')
-  require usergrid_path('core', 'organization')
-  require usergrid_path('core', 'application')
-  require usergrid_path('core', 'entity')
-  require usergrid_path('core', 'collection')
-
-  #autoload :Management, usergrid_path('core', 'management')
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/spec_helper.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/spec_helper.rb b/sdks/ruby/spec/spec_helper.rb
deleted file mode 100644
index 88f5b43..0000000
--- a/sdks/ruby/spec/spec_helper.rb
+++ /dev/null
@@ -1,89 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'simplecov'
-
-require 'rspec'
-require 'yaml'
-require 'securerandom'
-require_relative '../lib/usergrid_iron'
-
-LOG = Logger.new(STDOUT)
-RestClient.log=LOG
-
-SimpleCov.at_exit do
-  SimpleCov.result.format!
-  #index = File.join(SimpleCov.coverage_path, 'index.html')
-  #`open #{index}` if File.exists?(index)
-end
-SimpleCov.start
-
-SPEC_SETTINGS = YAML::load_file(File.join File.dirname(__FILE__), 'spec_settings.yaml')
-
-def login_management
-  management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
-  management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
-  management
-end
-
-# ensure we are correctly setup (management login & organization)
-management = login_management
-
-begin
-  management.create_organization(SPEC_SETTINGS[:organization][:name],
-                                 SPEC_SETTINGS[:organization][:username],
-                                 SPEC_SETTINGS[:organization][:username],
-                                 "#{SPEC_SETTINGS[:organization][:username]}@email.com",
-                                 SPEC_SETTINGS[:organization][:password])
-  LOG.info "created organization with user #{SPEC_SETTINGS[:organization][:username]}@email.com"
-rescue
-  if MultiJson.load($!.response)['error'] == "duplicate_unique_property_exists"
-    LOG.debug "test organization exists"
-  else
-    raise $!
-  end
-end
-
-def create_random_application
-  management = login_management
-  organization = management.organization SPEC_SETTINGS[:organization][:name]
-
-  app_name = "_test_app_#{SecureRandom.hex}"
-  organization.create_application app_name
-  management.application SPEC_SETTINGS[:organization][:name], app_name
-end
-
-def delete_application(application)
-  management = login_management
-  application.auth_token = management.auth_token
-  # application.delete rescue nil  # not implemented on server yet
-end
-
-def create_random_user(application, login=false)
-  random = SecureRandom.hex
-  user_hash = {username: "username_#{random}",
-               password: random,
-               email:    "#{random}@email.com",
-               name:     "#{random} name" }
-  entity = application['users'].post(user_hash).entity
-  application.login user_hash[:username], user_hash[:password] if login
-  entity
-end
-
-RSpec.configure do |config|
-  config.filter_run focus: true
-  config.run_all_when_everything_filtered = true
-  config.treat_symbols_as_metadata_keys_with_true_values = true
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/spec_settings.yaml
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/spec_settings.yaml b/sdks/ruby/spec/spec_settings.yaml
deleted file mode 100644
index 7f82f40..0000000
--- a/sdks/ruby/spec/spec_settings.yaml
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-:api_url: http://localhost:8080
-:management:
-  :username: test
-  :password: test
-:organization:
-  :name: test-organization
-  :username: test
-  :password: test
-:application:
-  :name: test-app
-  :username: test-app-user
-  :password: test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/application_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/application_spec.rb b/sdks/ruby/spec/usergrid/core/application_spec.rb
deleted file mode 100644
index f2b479e..0000000
--- a/sdks/ruby/spec/usergrid/core/application_spec.rb
+++ /dev/null
@@ -1,342 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Application do
-
-  before :all do
-    @application = create_random_application
-    @user = create_random_user @application, true
-  end
-
-  after :all do
-    @user.delete
-    delete_application @application
-  end
-
-  it "should be able to create a user using deprecated syntax" do
-    random = SecureRandom.hex
-    response = @application.create_user "username_#{random}", 'password'
-    response.entity.uuid.should_not be_nil
-  end
-
-  it "should be able to create, login, and delete a user" do
-    random = SecureRandom.hex
-    application = Usergrid::Application.new @application.url # create application resource that's not logged in
-    response = application.create_user username: "username_#{random}", password: 'password'
-    entity = response.entity
-    application.login "username_#{random}", 'password'
-    begin
-      response.code.should eq 200
-      response.entities.size.should eq 1
-      entity.uuid.should_not be_nil
-      response = application["users/#{entity.uuid}"].get
-      response.code.should eq 200
-    ensure
-      entity.delete
-      # deleted user shouldn't be able to access anything now
-      expect { application["users/#{entity.uuid}"].get }.to raise_error(RestClient::Unauthorized)
-      # use original application - logged in under existing user
-      expect { @application["users/#{entity.uuid}"].get }.to raise_error(RestClient::ResourceNotFound)
-    end
-  end
-
-  it "should be able to retrieve users" do
-    entity1 = create_random_user @application
-    entity2 = create_random_user @application
-    begin
-      response = @application.users
-      response.entities.size.should be >= 2
-      match1 = match2 = false
-      response.entities.each do |e|
-        match1 ||= e.username == entity1.username
-        match2 ||= e.username == entity2.username
-      end
-      match1.should be_true
-      match2.should be_true
-    ensure
-      entity1.delete
-      entity2.delete
-    end
-    response = @application.users
-    response.code.should eq 200
-    response.entities.should be_an Array
-  end
-
-  it "should be able to query users" do
-    entity1 = create_random_user @application
-    entity2 = create_random_user @application
-    begin
-      response = @application.users "select * where username = \'#{entity1.username}\'"
-      response.entities.size.should eq 1
-      response.entity.username.should eq entity1.username
-    ensure
-      entity1.delete
-      entity2.delete
-    end
-  end
-
-  it "should be able to update a user" do
-    entity = create_random_user @application
-    begin
-      updates = { email: 'testuser6@email.com', city: 'santa clarita' }
-      response = @application.put updates
-      updates.each {|k,v| response.entity[k.to_s].should eq v }
-    ensure
-      entity.delete
-    end
-  end
-
-  it "should be able to retrieve the logged in user" do
-    user = @application.current_user
-    user.uuid.should_not be_nil
-  end
-
-  it "should be able to add and retrieve activities" do
-    user = @application.current_user
-    activity = {
-        verb: "post",
-        content: "testy, testy",
-        actor: {
-          uuid: user.uuid,
-          email: user.email,
-          username: user.username,
-          displayName: user.username,
-          image: {
-            height: 80,
-            width: 80,
-            url: user.picture
-          }}}
-    response = @application['activities'].post activity
-    activity_path = response.entity['metadata']['path']
-    response.code.should eq 200
-
-    begin
-      entity = @application.activities.entity
-      activity.add_dot_notation!
-      entity.verb.should eq activity.verb
-      entity.content.should eq activity.content
-      entity.actor.uuid.should eq activity.actor.uuid
-    ensure
-      @application[activity_path].delete
-    end
-  end
-
-  it "should be able to retrieve a user's feed" do
-    response = @application.current_user.resource['feed'].get
-    response.code.should eq 200
-    response.entities.should be_an Array
-  end
-
-  it "should be able to follow a user" do
-    follower = create_random_user @application
-    begin
-      me = @application.current_user
-      @application["users/#{follower.uuid}/following/users/#{me.uuid}"].post "{}"
-
-      response = @application["users/#{follower.uuid}/following"].get
-      response.entities.size.should == 1
-      response.entity.uuid.should eq me.uuid
-
-      response = @application.current_user.resource['followers'].get
-      response.entities.size.should be > 0
-    ensure
-      follower.delete
-    end
-  end
-
-  it "should be able to create and retrieve groups" do
-    response = @application.groups
-    size = response.entities.size
-    random = SecureRandom.hex
-    @application.create_entity :groups, path: "test-#{random}"
-    response = @application.groups
-    response.entities.size.should eq size+1
-  end
-
-  it "should be able to create and retrieve devices" do
-    response = @application.devices
-    size = response.entities.size
-    random = SecureRandom.hex
-    @application.create_entity :devices, path: "test-#{random}"
-    response = @application.devices
-    response.entities.size.should eq size+1
-  end
-
-  it "should be able to create and retrieve assets" do
-    response = @application.assets
-    size = response.entities.size
-    random = SecureRandom.hex
-    @application.create_entity :assets, path: "test-#{random}", owner: @application.current_user.uuid
-    response = @application.assets
-    response.entities.size.should eq size+1
-  end
-
-  it "should be able to create and retrieve folders" do
-    response = @application.folders
-    size = response.entities.size
-    random = SecureRandom.hex
-    @application.create_entity :folders, path: "test-#{random}", owner: @application.current_user.uuid
-    response = @application.folders
-    response.entities.size.should eq size+1
-  end
-
-  # can't reliably test this - counters are batched on server
-  #it "should be able to create and retrieve events and retrieve counters" do
-  #  # clear events
-  #  {} while @application.events.entities.size > 0
-  #
-  #  events_in = []
-  #  events_in  << {timestamp: 0, category: 'test', counters: { test: 1 }}
-  #  events_in  << {timestamp: 0, category: 'testme', counters: { testme: 1 }}
-  #  events_in  << {timestamp: 0, counters: { test: 1 }}
-  #  events_in.each {|e| @application.create_entity :events, e }
-  #
-  #  events_out = []
-  #  events_out << @application.events.entity
-  #  events_out << @application.events.entity
-  #  events_out << @application.events.entity
-  #
-  #  (0..2).each do |i|
-  #    events_in[i][:category].should eq events_out[i]['category']
-  #  end
-  #
-  #  response = @application.events
-  #  response.entities.size.should eq 0
-  #
-  #  # get and test counters
-  #  counter_names = @application.counter_names
-  #  counter_names.should include 'test'
-  #  counter_names.should include 'testme'
-  #
-  #  response = @application.counter 'test'
-  #  counter = response.data.counters.first
-  #  counter.name.should eq 'test'
-  #  counter.values.last.first.value.should be > 0
-  #end
-
-  it "should be able to create, retrieve, and delete roles" do
-    size = @application.roles.collection.size
-
-    role_name = "test-#{SecureRandom.hex}"
-    @application.create_entity :role, name: role_name, title: 'title', inactivity: 0
-    roles = @application.roles.collection
-    roles.size.should eq size+1
-    role = roles.detect {|r| r.name == role_name }
-    role.should_not be_nil
-
-    role.delete
-    @application.roles.collection.size.should eq size
-  end
-
-  it "should be able to add/remove permissions from a user" do
-    user = create_random_user @application
-    permission = 'post:/users/*'
-    user.resource['permissions'].post permission: permission
-
-    permissions = user.resource['permissions'].get.data.data
-    permissions.size.should eq 1
-    permissions.first.should eq permission
-
-    user.resource['permissions'].delete({params: { permission: permission }})
-
-    permissions = user.resource['permissions'].get.collection.entities
-    permissions.size.should eq 0
-  end
-
-  it "should be able to add/remove a user from a roles" do
-    user = create_random_user @application
-
-    roles = user.resource['roles'].get.entities
-    size = roles.size
-
-    @application["roles/admin/users/#{user.uuid}"].post nil
-
-    roles = user.resource['roles'].get.entities
-    roles.size.should == size+1
-
-    @application["roles/admin/users/#{user.uuid}"].delete
-
-    roles = user.resource['roles'].get.entities
-    roles.size.should == size
-  end
-
-  it "should be able to create a new collection and access it" do
-    entities = (1..4).collect { |i| { name: "test_#{i}" } }
-    @application.create_entities 'tests', entities
-    response = @application['tests'].get
-    collection = response.collection
-    collection.size.should eq 4
-  end
-
-  it "should be able to create a new collection via create_ method and access it" do
-    entities = (1..4).collect { |i| { name: "test_#{i}" } }
-    @application.create_moretests entities
-    response = @application['tests'].get
-    collection = response.collection
-    collection.size.should eq 4
-  end
-
-  it "should be able to access a collection without calling get" do
-    entities = (1..4).collect { |i| { name: "test_#{i}" } }
-    @application.create_entities 'tests', entities
-    collection = @application['tests'].collection
-    collection.size.should eq 4
-  end
-
-  it "should be able to access entities without calling get" do
-    entities = (1..4).collect { |i| { name: "test_#{i}" } }
-    @application.create_entities 'tests', entities
-    entities = @application['tests'].entities
-    entities.size.should eq 4
-  end
-
-  it "should be able to query using dot notation" do
-    entities = (1..4).collect { |i| { name: "test_#{i}" } }
-    @application.create_btests entities
-    entities = @application.btests("name = 'test_1'").entities
-    entities.size.should eq 1
-  end
-
-  describe "grant_type: client_credentials" do
-
-    before(:each) do
-      @app = create_random_application
-    end
-
-    context "invalid credentials" do
-      it "should not be able to get access token with invalid credentials" do
-        expect { @app.login_credentials "invalid_client_id", "invalid_client_secret" }.to raise_exception RestClient::BadRequest
-      end
-
-      it "should not be able to get access token with empty credentials" do
-        expect { @app.login_credentials "", "" }.to raise_exception RestClient::BadRequest
-      end
-    end
-
-    context "valid credentials" do
-      it "should be able to get access token with valid credentials" do
-        app_info = JSON.parse @app.get
-
-        management = login_management
-        app = management.application app_info["organization"], app_info["applicationName"]
-        app_credentials = JSON.parse app.credentials
-        app.login_credentials app_credentials["credentials"]["client_id"], app_credentials["credentials"]["client_secret"]
-
-        expect(app.auth_token).to_not be_empty
-        expect(app.auth_token).to be_instance_of String
-      end
-    end
-  end
-end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/collection_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/collection_spec.rb b/sdks/ruby/spec/usergrid/core/collection_spec.rb
deleted file mode 100644
index 9ab07c3..0000000
--- a/sdks/ruby/spec/usergrid/core/collection_spec.rb
+++ /dev/null
@@ -1,125 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Collection do
-
-  before :all do
-    @application = create_random_application
-    @user = create_random_user @application, true
-
-    @collection = @application['tests'].collection
-    @entity_data = (1..25).collect do |i|
-      { name: "name_#{i}", value: "value_#{i+1}" }
-    end
-    (1..3).each {|i| @entity_data[i]['three'] = 3}
-    @collection.create_entities @entity_data
-  end
-
-  after :all do
-    @user.delete
-    delete_application @application
-  end
-
-  it "should be able to do a simple query" do
-    @collection.query "select * where name = \'#{@entity_data[0][:name]}\'"
-    @collection.size.should eq 1
-  end
-
-  it "should be able to select data elements" do
-    @collection.query "select name, value where name = \'#{@entity_data[0][:name]}\'"
-    @collection.size.should eq 1
-    # note: not Usergrid::Entity objects: it is an Array for this kind of query
-    values = @collection.entities.first
-    values[0].should eq @entity_data[0][:name]
-    values[1].should eq @entity_data[0][:value]
-  end
-
-  it "should be able to select redefined data elements" do
-    @collection.query "select { test1: name, test2 : value } where name = \'#{@entity_data[0][:name]}\'"
-    @collection.size.should eq 1
-    # note: not Usergrid::Entity objects: it is a Hash for this kind of query
-    values = @collection.entities.first
-    values.test1.should eq @entity_data[0][:name]
-    values.test2.should eq @entity_data[0][:value]
-  end
-
-  it "should be able to find an entity" do
-    @collection.query
-    entity = @collection.detect { |e| e.name == @entity_data[5][:name] }
-    entity.should_not be_nil
-    entity.name.should eq @entity_data[5][:name]
-  end
-
-  it "should be able to respect query reversal and limits" do
-    @collection.query nil, reversed: true, start: 5, cursor: nil, limit: 2, permission: nil
-    @collection.size.should eq 2
-    @collection[0].name.should eq @entity_data[@entity_data.size-1][:name]
-    @collection[1].name.should eq @entity_data[@entity_data.size-2][:name]
-  end
-
-  it "should be able to select the start by uuid" do
-    @collection.query
-    uuid = @collection[4].uuid
-    @collection.query nil, reversed: false, start: uuid, cursor: nil, limit: 3, permission: nil
-    @collection.size.should eq 3
-    @collection.first.uuid.should eq uuid
-    @collection[2].name.should eq @entity_data[6][:name]
-  end
-
-  it "should be able to page forward by cursor" do
-    @collection.query 'select * where three = 3', limit: 2
-    @collection.next_page
-    @collection.size.should eq 1
-    @collection[0].name.should eq @entity_data[3][:name]
-  end
-
-  it "should be able to update based on a query" do
-    @collection.update_query({new_field: 'new_value'}, "select * where name = \'#{@entity_data[4][:name]}\'")
-    @collection.query
-    entity = @collection.detect { |e| e['new_field'] == 'new_value' }
-    entity.should_not be_nil
-    entity.name.should eq @entity_data[4][:name]
-  end
-
-  it "should be able to delete based on a query" do
-    @collection.delete_query "select * where name = \'#{@entity_data[5][:name]}\'"
-    @collection.query
-    entity = @collection.detect { |e| e['name'] == "#{@entity_data[5][:name]}" }
-    entity.should be_nil
-    @entity_data.delete @entity_data[5]
-  end
-
-  it "should be able to iterate within the page" do
-    @collection.query
-    @collection.cursor.should_not be_nil
-    count = 0
-    page_size = @collection.count
-    @collection.each {|e| count += 1 }
-    count.should eq page_size
-  end
-
-  it "should be able to iterate over pages" do
-    @collection.query
-    @collection.cursor.should_not be_nil
-    count = 0
-    seen = Set.new
-    @collection.follow_cursor.each do |e|
-      seen.add?(e.uuid).should_not be_nil
-      count += 1
-    end
-    count.should eq @entity_data.size
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/entity_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/entity_spec.rb b/sdks/ruby/spec/usergrid/core/entity_spec.rb
deleted file mode 100644
index 887fa91..0000000
--- a/sdks/ruby/spec/usergrid/core/entity_spec.rb
+++ /dev/null
@@ -1,91 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Entity do
-
-  before :all do
-    @application = create_random_application
-    @user = create_random_user @application, true
-  end
-
-  after :all do
-    @user.delete
-    delete_application @application
-  end
-
-  it "should be able to retrieve its collection" do
-    collection = @user.collection
-    collection.should_not be_nil
-    u = collection.detect {|u| u.uuid == @user.uuid }
-    u.uuid.should eq @user.uuid
-  end
-
-  it "should be able to reload its data" do
-    old_name = @user.name
-    @user.name = 'new name'
-    @user.name.should eq 'new name'
-    @user.get
-    @user.name.should eq old_name
-  end
-
-  it "should be able to save" do
-    @user.name = 'new name'
-    @user.save
-    @user.name.should eq 'new name'
-  end
-
-  it "should be able to print itself" do
-    p = @user.to_s
-    p.start_with?('resource').should be_true
-  end
-
-  it "should know if it has data" do
-    @user.data?.should be_true
-    empty = Usergrid::Entity.new 'url', 'url'
-    empty.data?.should be_false
-  end
-
-  it "should return nil if empty result" do
-    @application['foobars'].get.entity.should be_nil
-  end
-
-  it "should not serialize reserved attributes" do
-    dump = MultiJson.dump @user
-    hash = MultiJson.load dump
-    Usergrid::Resource::RESERVED.each { |a| hash.should_not have_key(a) }
-  end
-
-  it "should be able to delete itself" do
-    user = create_random_user @application
-    name = user.name
-    user.delete
-    u = @application['users'].entities.detect {|e| e.name == "#{name}"}
-    u.should be_nil
-  end
-
-  it "should be able to update and delete by query" do
-    dog = (@application.create_dog name: 'Vex').entity
-
-    @application['dogs'].update_query({foo: 'bar'}, "select * where name = \'#{dog.name}\'")
-    dog.get
-    dog.foo.should eq('bar')
-
-    @application['dogs'].delete_query "select * where name = \'#{dog.name}\'"
-
-    dog = @application['dogs'].entities.detect {|e| e.name == "#{dog.name}"}
-    dog.should be_nil
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/management_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/management_spec.rb b/sdks/ruby/spec/usergrid/core/management_spec.rb
deleted file mode 100644
index f53d572..0000000
--- a/sdks/ruby/spec/usergrid/core/management_spec.rb
+++ /dev/null
@@ -1,51 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Management do
-
-  before :all do
-    @base_resource = Usergrid::Resource.new(SPEC_SETTINGS[:api_url])
-    @management = @base_resource.management
-    @management.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
-  end
-
-  it "should be able to create an organization" do
-    # can't delete an org or a user, so we create new random ones and leave them
-    random = SecureRandom.hex
-    org_name = "test_org_#{random}"
-    user_name = "test_admin_#{random}"
-    response = @management.create_organization("#{org_name}",
-                                               "#{user_name}",
-                                               "#{user_name}",
-                                               "#{user_name}@email.com",
-                                               "#{random}")
-    response.code.should eq 200
-    #@base_resource["users/#{user_name}"].delete
-  end
-
-  # this is broken on the server
-  #it "should be able to get organizations" do
-  #  response = @management.organizations
-  #end
-
-  it "should be able to get an organization" do
-    organization = @management.organization SPEC_SETTINGS[:organization][:name]
-    organization.should be_a Usergrid::Organization
-    org_ent = organization.get.entity
-    org_ent.uuid.should_not be_nil
-    org_ent.name.should eq SPEC_SETTINGS[:organization][:name]
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/organization_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/organization_spec.rb b/sdks/ruby/spec/usergrid/core/organization_spec.rb
deleted file mode 100644
index 93092fc..0000000
--- a/sdks/ruby/spec/usergrid/core/organization_spec.rb
+++ /dev/null
@@ -1,113 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Organization do
-
-  before :each do
-    @management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
-    @management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
-    @organization = @management.organization SPEC_SETTINGS[:organization][:name]
-  end
-
-  it "should be able to create (and delete) an application" do
-    app_name = "test_app_#{SecureRandom.hex}"
-    app = @organization.create_application app_name
-    app.should be_an Usergrid::Application
-
-    response = @organization["applications/#{app_name}"].delete
-    response.code.should eq 200
-  end
-
-  it "should be able to get applications" do
-    response = @organization.applications
-    response.should be_an Array
-    if response.size > 0
-      app = response.first
-      app.should be_an Usergrid::Application
-    end
-  end
-
-  it "should be able to get users" do
-    response = @organization.users
-    response.code.should eq 200
-    response.entities.should be_an Array
-    response.entities[0].uuid.should_not be_nil
-  end
-
-  it "should be able to get a user" do
-    response = @organization.user(SPEC_SETTINGS[:organization][:username])
-    response.code.should eq 200
-    response.entity.uuid.should_not be_nil
-  end
-
-  it "should be able to get an application" do
-    app_name = "test_app_#{SecureRandom.hex}"
-    @organization.create_application app_name
-    begin
-      app = @organization.application app_name
-      app.should be_an Usergrid::Application
-    ensure
-      @organization["applications/#{app_name}"].delete
-    end
-  end
-
-  it "should be able to get feed" do
-    response = @organization.feed
-    entities = response.entities
-    entities.size.should be > 0
-    entities.first.uuid.should_not be_nil
-  end
-
-  it "should be able to get credentials" do
-    response = @organization.credentials
-    response.code.should eq 200
-    response.data.credentials.client_id.should_not be_nil
-    response.data.credentials.client_secret.should_not be_nil
-  end
-
-  it "should be able to generate credentials" do
-    response = @organization.generate_credentials
-    response.code.should eq 200
-    response.data.credentials.client_id.should_not be_nil
-    response.data.credentials.client_secret.should_not be_nil
-  end
-
-  describe "grant_type: client_credentials" do
-    context "invalid credentials" do
-      before :each do
-        @organization.logout
-      end
-
-      it "should not be able to get access token with invalid credentials" do
-        expect { @organization.login_credentials "invalid_client_id", "invalid_client_secret" }.to raise_exception RestClient::BadRequest
-      end
-
-      it "should not be able to get access token with empty credentials" do
-        expect { @organization.login_credentials "", "" }.to raise_exception RestClient::BadRequest
-      end
-    end
-
-    context "valid crendentials" do
-      it "should be able to get access token with valid credentials" do
-        org_credentials = JSON.parse @organization.credentials
-        @organization.logout
-        @organization.login_credentials org_credentials["credentials"]["client_id"], org_credentials["credentials"]["client_secret"]
-
-        expect(@organization.auth_token).to_not be_empty
-        expect(@organization.auth_token).to be_instance_of String
-      end
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/core/resource_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/core/resource_spec.rb b/sdks/ruby/spec/usergrid/core/resource_spec.rb
deleted file mode 100644
index 82a1ace..0000000
--- a/sdks/ruby/spec/usergrid/core/resource_spec.rb
+++ /dev/null
@@ -1,63 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-describe Usergrid::Resource do
-
-  before :all do
-    @resource = Usergrid::Resource.new SPEC_SETTINGS[:api_url]
-  end
-
-  it "should succeed on status check" do
-    response = @resource['/status'].get
-
-    response.code.should eq 200
-    response.data.should be_a Hash
-  end
-
-  it "should fail with a 400 when no auth given" do
-    expect { @resource['management'].get }.to raise_error(RestClient::BadRequest) { |exception|
-      exception.response.code.should eq 400
-    }
-  end
-
-  it "should fail with a 401 when lacking auth" do
-    app_endpoint = "#{SPEC_SETTINGS[:organization][:name]}/#{SPEC_SETTINGS[:application][:name]}"
-    expect { @resource[app_endpoint].get }.to raise_error(RestClient::Unauthorized) { |exception|
-      exception.response.code.should eq 401
-    }
-  end
-
-  it "should be able to login" do
-    resource = @resource['management']
-    response = resource.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
-
-    response.code.should eq 200
-    resource.auth_token.should_not be_nil
-    response.data['access_token'].should eq resource.auth_token
-    resource.options[:headers][:Authorization].should eq "Bearer #{resource.auth_token}"
-    resource.logged_in?.should be_true
-  end
-
-  it "should be able to log out" do
-    resource = @resource['management']
-    resource.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
-    resource.logged_in?.should be_true
-
-    resource.logout
-    resource.options[:headers][:Authorization].should be_nil
-    resource.logged_in?.should be_false
-  end
-
-end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/spec/usergrid/extensions/hash_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/spec/usergrid/extensions/hash_spec.rb b/sdks/ruby/spec/usergrid/extensions/hash_spec.rb
deleted file mode 100644
index 9dbecdb..0000000
--- a/sdks/ruby/spec/usergrid/extensions/hash_spec.rb
+++ /dev/null
@@ -1,40 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require_relative '../../../lib/usergrid/extensions/hash'
-
-describe Hash do
-
-  it "should add dot notation recursively" do
-    h = { test1: 'test1', test2: { test2a: 'test2a' }, test3: [ { test3a: 'test3a' }] }
-    expect { h.test1 }.to raise_error
-    h.add_dot_notation!
-    h.test1.should eq 'test1'
-    h.test2.test2a.should eq 'test2a'
-    h.test3.first.test3a.should eq 'test3a'
-    h.test1 = 'testx'
-    h.test1.should eq 'testx'
-  end
-
-  it "should symbolize keys at top level" do
-    h = { 'test1' => 'test1', 'test2' => { 'test2a' => 'test2a' }, 'test3' => [ { 'test3a' => 'test3a' }] }
-    h['test1'].should eq 'test1'
-    h = h.symbolize_keys
-    h['test1'].should be_nil
-    h[:test1].should eq 'test1'
-    h[:test2][:test2a].should be_nil
-    h[:test3].first['test3a'].should eq 'test3a'
-  end
-end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/usergrid_iron.gemspec
----------------------------------------------------------------------
diff --git a/sdks/ruby/usergrid_iron.gemspec b/sdks/ruby/usergrid_iron.gemspec
deleted file mode 100644
index f9bc46e..0000000
--- a/sdks/ruby/usergrid_iron.gemspec
+++ /dev/null
@@ -1,41 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-# -*- encoding: utf-8 -*-
-require File.expand_path('../lib/usergrid/version', __FILE__)
-
-Gem::Specification.new do |gem|
-  gem.authors       = ["Scott Ganyo"]
-  gem.email         = ["scott@ganyo.com"]
-  gem.description   = %q{Low-level gem to access Usergrid / Apigee App Services}
-  gem.summary       = %q{Usergrid_iron enables simple, low-level Ruby access to Apigee's App Services
-                        (aka Usergrid) REST API with minimal dependencies.}
-  gem.homepage      = "https://github.com/scottganyo/usergrid_iron"
-
-  gem.files         = `git ls-files`.split($\)
-  gem.executables   = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
-  gem.test_files    = gem.files.grep(%r{^(spec|spec|features)/})
-  gem.name          = "usergrid_iron"
-  gem.require_paths = ["lib"]
-  gem.version       = Usergrid::VERSION
-
-  gem.add_dependency 'rest-client'
-  gem.add_dependency 'multi_json'
-
-  gem.add_development_dependency 'rake'
-  gem.add_development_dependency 'rspec'
-  gem.add_development_dependency 'simplecov'
-end


[39/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/AddBookViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/AddBookViewController.m b/sdks/ios/samples/Books/books/AddBookViewController.m
deleted file mode 100644
index 85afa77..0000000
--- a/sdks/ios/samples/Books/books/AddBookViewController.m
+++ /dev/null
@@ -1,169 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  AddBookViewController.m
-//  books
-//
-
-#import "AddBookViewController.h"
-#import "UGConnection.h"
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-
-@interface FormTableViewCell : UITableViewCell <UITextFieldDelegate>
-@property (nonatomic, strong) UILabel *label;
-@property (nonatomic, strong) UITextField *textField;
-@property (nonatomic, strong) NSString *key;
-@property (nonatomic, weak) id binding;
-@end
-
-@implementation FormTableViewCell
-
-- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
-{
-    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
-        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
-        self.label.backgroundColor = [UIColor clearColor];
-        self.label.font = [UIFont systemFontOfSize:10];
-        self.label.textColor = [UIColor grayColor];
-        self.label.textAlignment = NSTextAlignmentLeft;
-        [self.contentView addSubview:self.label];
-        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
-        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
-        self.textField.font = [UIFont systemFontOfSize:18];
-        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
-        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
-        self.textField.delegate = self;
-        if ([key isEqualToString:@"password"]) {
-            self.textField.secureTextEntry = YES;
-        }
-        [self.contentView addSubview:self.textField];
-        self.selectionStyle = UITableViewCellSelectionStyleNone;
-        // individual cell properties
-        self.label.text = title;
-        self.key = key;
-        self.binding = binding;
-    }
-    return self;
-}
-
-- (void) layoutSubviews
-{
-    [super layoutSubviews];
-    CGRect textFieldFrame = self.textField.frame;
-    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
-    self.textField.frame = textFieldFrame;
-}
-
-- (void) textFieldDidEndEditing:(UITextField *)textField
-{
-    [self.binding setObject:textField.text forKey:self.key];
-}
-
-@end
-
-@interface AddBookViewController ()
-@property (nonatomic, strong) NSMutableDictionary *values;
-@property (nonatomic, strong) NSArray *cells;
-@end
-
-@implementation AddBookViewController
-
-- (id)init {
-    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
-        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
-        if (!self.values) {
-            self.values = [NSMutableDictionary dictionary];
-        }
-        self.cells =
-        @[[[FormTableViewCell alloc] initWithTitle:@"Title" key:@"title" binding:self.values],
-          [[FormTableViewCell alloc] initWithTitle:@"Author" key:@"author" binding:self.values]];
-    }
-    return self;
-}
-
-- (void) loadView
-{
-    [super loadView];
-    self.title = @"Connection";
-    self.tableView.backgroundView = nil;
-    self.tableView.backgroundColor = [UIColor darkGrayColor];
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithTitle:@"Cancel"
-                                             style:UIBarButtonItemStyleBordered
-                                             target:self
-                                             action:@selector(cancel:)];
-    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
-                                              initWithTitle:@"Save"
-                                              style:UIBarButtonItemStyleBordered
-                                              target:self
-                                              action:@selector(save:)];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    return [self.cells count];
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    return [self.cells objectAtIndex:[indexPath row]];
-}
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    FormTableViewCell *formCell = (FormTableViewCell *) cell;
-    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    FormTableViewCell *formCell = (FormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
-    [formCell.textField becomeFirstResponder];
-}
-
-#pragma mark - Sign In
-
-- (void) cancel:(id) sender
-{
-    [self dismissViewControllerAnimated:YES completion:nil];
-}
-
-- (void) save:(id) sender
-{
-    for (FormTableViewCell *cell in self.cells) {
-        [cell.textField resignFirstResponder];
-    }    
-    UGConnection *connection = [UGConnection sharedConnection];
-    [[[UGHTTPClient alloc] initWithRequest:
-      [connection createEntityInCollection:@"books" withValues:self.values]]
-     connectWithCompletionHandler:^(UGHTTPResult *result) {
-         [self dismissViewControllerAnimated:YES completion:nil];
-     }];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/AppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/AppDelegate.h b/sdks/ios/samples/Books/books/AppDelegate.h
deleted file mode 100644
index 185592e..0000000
--- a/sdks/ios/samples/Books/books/AppDelegate.h
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  AppDelegate.h
-//  books
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface AppDelegate : UIResponder <UIApplicationDelegate>
-
-@property (strong, nonatomic) UIWindow *window;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/AppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/AppDelegate.m b/sdks/ios/samples/Books/books/AppDelegate.m
deleted file mode 100644
index f1082ef..0000000
--- a/sdks/ios/samples/Books/books/AppDelegate.m
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  AppDelegate.m
-//  books
-//
-
-#import "AppDelegate.h"
-#import "BooksViewController.h"
-
-@implementation AppDelegate
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
-    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
-    UINavigationController *navigationController = [[UINavigationController alloc]
-                                                    initWithRootViewController:[[BooksViewController alloc] init]];
-    navigationController.navigationBar.tintColor = [UIColor colorWithRed:100.0/255.0
-                                                                   green:150.0/255.0
-                                                                    blue:200.0/255.0
-                                                                   alpha:1];
-    self.window.rootViewController = navigationController;
-    self.window.backgroundColor = [UIColor whiteColor];
-    [self.window makeKeyAndVisible];
-    return YES;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/BooksViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/BooksViewController.h b/sdks/ios/samples/Books/books/BooksViewController.h
deleted file mode 100644
index b286c29..0000000
--- a/sdks/ios/samples/Books/books/BooksViewController.h
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  BooksViewController.h
-//  books
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface BooksViewController : UITableViewController
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/BooksViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/BooksViewController.m b/sdks/ios/samples/Books/books/BooksViewController.m
deleted file mode 100644
index 44be61c..0000000
--- a/sdks/ios/samples/Books/books/BooksViewController.m
+++ /dev/null
@@ -1,154 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  BooksViewController.m
-//  books
-//
-
-#import "BooksViewController.h"
-#import "UGSignInViewController.h"
-#import "UGConnection.h"
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-#import "AddBookViewController.h"
-
-@interface BooksViewController ()
-@property (nonatomic, strong) NSDictionary *content;
-@end
-
-@implementation BooksViewController
-
-- (id)initWithStyle:(UITableViewStyle)style
-{
-    self = [super initWithStyle:style];
-    if (self) {
-        // Custom initialization
-    }
-    return self;
-}
-
-- (void)loadView
-{
-    [super loadView];
-    self.navigationItem.title = @"My Books";
-    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Add Book"
-                                                                              style:UIBarButtonItemStyleBordered target:self action:@selector(addbook:)];
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithTitle:@"Connection"
-                                             style:UIBarButtonItemStyleBordered
-                                             target:self
-                                             action:@selector(connect:)];                                              
-}
-
-- (void) connect:(id) sender
-{
-    UGSignInViewController *signinViewController = [[UGSignInViewController alloc] init];
-    UINavigationController *signinNavigationController =
-    [[UINavigationController alloc] initWithRootViewController:signinViewController];
-    signinNavigationController.modalPresentationStyle = UIModalPresentationFormSheet;
-    signinNavigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
-    [self presentViewController:signinNavigationController animated:YES completion:nil];
-}
-
-- (void) addbook:(id) sender
-{
-    AddBookViewController *addBookViewController = [[AddBookViewController alloc] init];
-    UINavigationController *navigationController =
-    [[UINavigationController alloc] initWithRootViewController:addBookViewController];
-    navigationController.modalPresentationStyle = UIModalPresentationFormSheet;
-    navigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
-    [self presentViewController:navigationController animated:YES completion:nil];
-}
-
-- (void) viewWillAppear:(BOOL)animated
-{
-    [self reload];
-}
-
-- (void) reload {
-    UGConnection *usergrid = [UGConnection sharedConnection];
-    if ([usergrid isAuthenticated]) {
-        NSLog(@"loading...");
-        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
-                                [usergrid getEntitiesInCollection:@"books" limit:100]];
-        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
-            NSLog(@"%@", result.object);
-            self.content = result.object;
-            [self.tableView reloadData];
-        }];
-    }
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    // Return the number of sections.
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    // Return the number of rows in the section.
-    return self.content ? [self.content[@"entities"] count] : 1;
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    return [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
-}
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (!self.content) {
-        cell.textLabel.text = @"Please sign in.";
-    } else {
-        id entity = self.content[@"entities"][[indexPath row]];
-        cell.textLabel.text = entity[@"title"];
-        cell.detailTextLabel.text = entity[@"author"];
-        UIButton *deleteButton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
-        cell.accessoryView = deleteButton;
-        [deleteButton setTitle:@"X" forState:UIControlStateNormal];
-        deleteButton.tag = [indexPath row];
-        [deleteButton addTarget:self action:@selector(deleteItem:) forControlEvents:UIControlEventTouchUpInside];
-        [deleteButton sizeToFit];
-    }
-    cell.selectionStyle = UITableViewCellSelectionStyleNone;
-}
-
-- (void) deleteItem:(UIButton *) sender {
-    int row = [sender tag];
-    id entity = self.content[@"entities"][row];
-    NSString *uuid = [entity objectForKey:@"uuid"];
-    UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
-                            [[UGConnection sharedConnection] deleteEntity:uuid inCollection:@"books"]];
-    [client connectWithCompletionHandler:^(UGHTTPResult *result) {
-        [self reload];
-    }];
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (!self.content) {
-        [self connect:nil];
-    }
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/Default-568h@2x.png b/sdks/ios/samples/Books/books/Default-568h@2x.png
deleted file mode 100644
index 0891b7a..0000000
Binary files a/sdks/ios/samples/Books/books/Default-568h@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/Default.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/Default.png b/sdks/ios/samples/Books/books/Default.png
deleted file mode 100644
index 4c8ca6f..0000000
Binary files a/sdks/ios/samples/Books/books/Default.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/Default@2x.png b/sdks/ios/samples/Books/books/Default@2x.png
deleted file mode 100644
index 35b84cf..0000000
Binary files a/sdks/ios/samples/Books/books/Default@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/UGSignInViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/UGSignInViewController.h b/sdks/ios/samples/Books/books/UGSignInViewController.h
deleted file mode 100644
index b831869..0000000
--- a/sdks/ios/samples/Books/books/UGSignInViewController.h
+++ /dev/null
@@ -1,23 +0,0 @@
-//
-//  UGSignInViewController.h
-//  books
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@class UGAppViewController;
-
-@interface UGSignInViewController : UITableViewController
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/UGSignInViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/UGSignInViewController.m b/sdks/ios/samples/Books/books/UGSignInViewController.m
deleted file mode 100644
index 6cccb77..0000000
--- a/sdks/ios/samples/Books/books/UGSignInViewController.m
+++ /dev/null
@@ -1,184 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGSignInViewController.m
-//  books
-//
-
-
-#import "UGHTTPClient.h"
-#import "UGConnection.h"
-#import "UGSignInViewController.h"
-
-#define SERVER @"http://api.usergrid.com"
-
-@interface UGFormTableViewCell : UITableViewCell <UITextFieldDelegate>
-@property (nonatomic, strong) UILabel *label;
-@property (nonatomic, strong) UITextField *textField;
-@property (nonatomic, strong) NSString *key;
-@property (nonatomic, weak) id binding;
-@end
-
-@implementation UGFormTableViewCell
-
-- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
-{
-    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
-        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
-        self.label.backgroundColor = [UIColor clearColor];
-        self.label.font = [UIFont systemFontOfSize:10];
-        self.label.textColor = [UIColor grayColor];
-        self.label.textAlignment = NSTextAlignmentLeft;
-        [self.contentView addSubview:self.label];
-        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
-        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
-        self.textField.font = [UIFont systemFontOfSize:18];
-        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
-        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
-        self.textField.delegate = self;
-        if ([key isEqualToString:@"password"]) {
-            self.textField.secureTextEntry = YES;
-        }
-        [self.contentView addSubview:self.textField];
-        self.selectionStyle = UITableViewCellSelectionStyleNone;
-        // individual cell properties
-        self.label.text = title;
-        self.key = key;
-        self.binding = binding;
-    }
-    return self;
-}
-
-- (void) layoutSubviews
-{
-    [super layoutSubviews];
-    CGRect textFieldFrame = self.textField.frame;
-    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
-    self.textField.frame = textFieldFrame;
-}
-
-- (void) textFieldDidEndEditing:(UITextField *)textField
-{
-    [self.binding setObject:textField.text forKey:self.key];
-}
-
-@end
-
-@interface UGSignInViewController ()
-@property (nonatomic, strong) NSMutableDictionary *values;
-@property (nonatomic, strong) NSArray *cells;
-@end
-
-@implementation UGSignInViewController
-
-- (id)init {
-    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
-        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
-        if (!self.values) {
-            self.values = [NSMutableDictionary dictionary];
-            [self.values setObject:SERVER forKey:@"server"];
-        }
-        self.cells =
-        @[[[UGFormTableViewCell alloc] initWithTitle:@"Server" key:@"server" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Organization" key:@"organization" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Application" key:@"application" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Username" key:@"username" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Password" key:@"password" binding:self.values]];
-    }
-    return self;
-}
-
-- (void) loadView
-{
-    [super loadView];
-    self.title = @"Connection";
-    self.tableView.backgroundView = nil;
-    self.tableView.backgroundColor = [UIColor darkGrayColor];
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithTitle:@"Cancel"
-                                             style:UIBarButtonItemStyleBordered
-                                             target:self
-                                             action:@selector(cancel:)];
-    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
-                                              initWithTitle:@"Sign In"
-                                              style:UIBarButtonItemStyleBordered
-                                              target:self
-                                              action:@selector(signin:)];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    return [self.cells count];
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    return [self.cells objectAtIndex:[indexPath row]];
-}
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UGFormTableViewCell *formCell = (UGFormTableViewCell *) cell;
-    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UGFormTableViewCell *formCell = (UGFormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
-    [formCell.textField becomeFirstResponder];
-}
-
-#pragma mark - Sign In
-
-- (void) cancel:(id) sender
-{
-    [self dismissViewControllerAnimated:YES completion:nil];
-}
-
-- (void) signin:(id) sender
-{
-    for (UGFormTableViewCell *cell in self.cells) {
-        [cell.textField resignFirstResponder];
-    }
-    [[NSUserDefaults standardUserDefaults] setObject:self.values forKey:@"usergrid"];
-    [[NSUserDefaults standardUserDefaults] synchronize];
-    
-    UGConnection *connection = [UGConnection sharedConnection];
-    connection.server = [self.values objectForKey:@"server"];
-    connection.organization = [self.values objectForKey:@"organization"];
-    connection.application = [self.values objectForKey:@"application"];
-    
-    [[[UGHTTPClient alloc] initWithRequest:
-      [connection getAccessTokenForApplicationWithUsername:[self.values objectForKey:@"username"]
-                                                  password:[self.values objectForKey:@"password"]]]
-     connectWithCompletionHandler:^(UGHTTPResult *result) {
-         [connection authenticateWithResult:result];
-         [self dismissViewControllerAnimated:YES completion:nil];
-     }];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/books-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/books-Info.plist b/sdks/ios/samples/Books/books/books-Info.plist
deleted file mode 100644
index f394f12..0000000
--- a/sdks/ios/samples/Books/books/books-Info.plist
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- 
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
--->
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>en</string>
-	<key>CFBundleDisplayName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleShortVersionString</key>
-	<string>1.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>LSRequiresIPhoneOS</key>
-	<true/>
-	<key>UIRequiredDeviceCapabilities</key>
-	<array>
-		<string>armv7</string>
-	</array>
-	<key>UISupportedInterfaceOrientations</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-	<key>UISupportedInterfaceOrientations~ipad</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationPortraitUpsideDown</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-</dict>
-</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/books-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/books-Prefix.pch b/sdks/ios/samples/Books/books/books-Prefix.pch
deleted file mode 100644
index 42d6379..0000000
--- a/sdks/ios/samples/Books/books/books-Prefix.pch
+++ /dev/null
@@ -1,31 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-// Prefix header for all source files of the 'books' target in the 'books' project
-//
-
-#import <Availability.h>
-
-#ifndef __IPHONE_3_0
-#warning "This project uses features only available in iOS SDK 3.0 and later."
-#endif
-
-#ifdef __OBJC__
-    #import <UIKit/UIKit.h>
-    #import <Foundation/Foundation.h>
-#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/en.lproj/InfoPlist.strings b/sdks/ios/samples/Books/books/en.lproj/InfoPlist.strings
deleted file mode 100644
index 7004264..0000000
--- a/sdks/ios/samples/Books/books/en.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-*/
-
-/* Localized versions of Info.plist keys */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/main.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/main.m b/sdks/ios/samples/Books/books/main.m
deleted file mode 100644
index a3b2f01..0000000
--- a/sdks/ios/samples/Books/books/main.m
+++ /dev/null
@@ -1,32 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  main.m
-//  books
-//
-
-#import <UIKit/UIKit.h>
-
-#import "AppDelegate.h"
-
-int main(int argc, char *argv[])
-{
-    @autoreleasepool {
-        return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser.xcodeproj/project.pbxproj b/sdks/ios/samples/Browser/browser.xcodeproj/project.pbxproj
deleted file mode 100644
index 63320fd..0000000
--- a/sdks/ios/samples/Browser/browser.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,487 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 46;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		22FC709C1730595C00153630 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709B1730595C00153630 /* UIKit.framework */; };
-		22FC709E1730595C00153630 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709D1730595C00153630 /* Foundation.framework */; };
-		22FC70A01730595C00153630 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709F1730595C00153630 /* CoreGraphics.framework */; };
-		22FC70A61730595C00153630 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70A41730595C00153630 /* InfoPlist.strings */; };
-		22FC70A81730595C00153630 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70A71730595C00153630 /* main.m */; };
-		22FC70AE1730595C00153630 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70AD1730595C00153630 /* Default.png */; };
-		22FC70B01730595C00153630 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70AF1730595C00153630 /* Default@2x.png */; };
-		22FC70B21730595C00153630 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70B11730595C00153630 /* Default-568h@2x.png */; };
-		22FC70C41730639600153630 /* UGAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70B91730639600153630 /* UGAppDelegate.m */; };
-		22FC70C51730639600153630 /* UGAppViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BB1730639600153630 /* UGAppViewController.m */; };
-		22FC70C61730639600153630 /* UGCollectionViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BD1730639600153630 /* UGCollectionViewController.m */; };
-		22FC70C71730639600153630 /* UGEntityViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BF1730639600153630 /* UGEntityViewController.m */; };
-		22FC70C81730639600153630 /* UGSignInViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70C11730639600153630 /* UGSignInViewController.m */; };
-		22FC70C91730639600153630 /* UGTextViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70C31730639600153630 /* UGTextViewController.m */; };
-		22FC70FD173063AF00153630 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70CD173063AF00153630 /* NSObject+SBJson.m */; };
-		22FC70FE173063AF00153630 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D0173063AF00153630 /* SBJsonParser.m */; };
-		22FC70FF173063AF00153630 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D2173063AF00153630 /* SBJsonStreamParser.m */; };
-		22FC7100173063AF00153630 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */; };
-		22FC7101173063AF00153630 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */; };
-		22FC7102173063AF00153630 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */; };
-		22FC7103173063AF00153630 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */; };
-		22FC7104173063AF00153630 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */; };
-		22FC7105173063AF00153630 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */; };
-		22FC7106173063AF00153630 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E0173063AF00153630 /* SBJsonTokeniser.m */; };
-		22FC7107173063AF00153630 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */; };
-		22FC7108173063AF00153630 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E4173063AF00153630 /* SBJsonWriter.m */; };
-		22FC7109173063AF00153630 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E6173063AF00153630 /* UGActivity.m */; };
-		22FC710A173063AF00153630 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E8173063AF00153630 /* UGClient.m */; };
-		22FC710B173063AF00153630 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70EB173063AF00153630 /* UGClientResponse.m */; };
-		22FC710C173063AF00153630 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70ED173063AF00153630 /* UGHTTPManager.m */; };
-		22FC710D173063AF00153630 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70EF173063AF00153630 /* UGMultiStepAction.m */; };
-		22FC710E173063AF00153630 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F1173063AF00153630 /* UGQuery.m */; };
-		22FC710F173063AF00153630 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F3173063AF00153630 /* UGUser.m */; };
-		22FC7110173063AF00153630 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F6173063AF00153630 /* UGConnection.m */; };
-		22FC7111173063AF00153630 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F8173063AF00153630 /* UGHTTPClient.m */; };
-		22FC7112173063AF00153630 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70FA173063AF00153630 /* UGHTTPHelpers.m */; };
-		22FC7113173063AF00153630 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70FC173063AF00153630 /* UGHTTPResult.m */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		22FC70981730595C00153630 /* browser.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = browser.app; sourceTree = BUILT_PRODUCTS_DIR; };
-		22FC709B1730595C00153630 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
-		22FC709D1730595C00153630 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
-		22FC709F1730595C00153630 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
-		22FC70A31730595C00153630 /* browser-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "browser-Info.plist"; sourceTree = "<group>"; };
-		22FC70A51730595C00153630 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		22FC70A71730595C00153630 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
-		22FC70A91730595C00153630 /* browser-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "browser-Prefix.pch"; sourceTree = "<group>"; };
-		22FC70AD1730595C00153630 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
-		22FC70AF1730595C00153630 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
-		22FC70B11730595C00153630 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
-		22FC70B81730639600153630 /* UGAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGAppDelegate.h; sourceTree = "<group>"; };
-		22FC70B91730639600153630 /* UGAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGAppDelegate.m; sourceTree = "<group>"; };
-		22FC70BA1730639600153630 /* UGAppViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGAppViewController.h; sourceTree = "<group>"; };
-		22FC70BB1730639600153630 /* UGAppViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGAppViewController.m; sourceTree = "<group>"; };
-		22FC70BC1730639600153630 /* UGCollectionViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGCollectionViewController.h; sourceTree = "<group>"; };
-		22FC70BD1730639600153630 /* UGCollectionViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGCollectionViewController.m; sourceTree = "<group>"; };
-		22FC70BE1730639600153630 /* UGEntityViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGEntityViewController.h; sourceTree = "<group>"; };
-		22FC70BF1730639600153630 /* UGEntityViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGEntityViewController.m; sourceTree = "<group>"; };
-		22FC70C01730639600153630 /* UGSignInViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGSignInViewController.h; sourceTree = "<group>"; };
-		22FC70C11730639600153630 /* UGSignInViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGSignInViewController.m; sourceTree = "<group>"; };
-		22FC70C21730639600153630 /* UGTextViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGTextViewController.h; sourceTree = "<group>"; };
-		22FC70C31730639600153630 /* UGTextViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGTextViewController.m; sourceTree = "<group>"; };
-		22FC70CC173063AF00153630 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
-		22FC70CD173063AF00153630 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
-		22FC70CE173063AF00153630 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
-		22FC70CF173063AF00153630 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
-		22FC70D0173063AF00153630 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
-		22FC70D1173063AF00153630 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
-		22FC70D2173063AF00153630 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
-		22FC70D3173063AF00153630 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
-		22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
-		22FC70D5173063AF00153630 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
-		22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
-		22FC70D7173063AF00153630 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
-		22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
-		22FC70D9173063AF00153630 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
-		22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
-		22FC70DB173063AF00153630 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
-		22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
-		22FC70DD173063AF00153630 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
-		22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
-		22FC70DF173063AF00153630 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
-		22FC70E0173063AF00153630 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
-		22FC70E1173063AF00153630 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
-		22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
-		22FC70E3173063AF00153630 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
-		22FC70E4173063AF00153630 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
-		22FC70E5173063AF00153630 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
-		22FC70E6173063AF00153630 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
-		22FC70E7173063AF00153630 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
-		22FC70E8173063AF00153630 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
-		22FC70E9173063AF00153630 /* UGClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
-		22FC70EA173063AF00153630 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
-		22FC70EB173063AF00153630 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
-		22FC70EC173063AF00153630 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
-		22FC70ED173063AF00153630 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
-		22FC70EE173063AF00153630 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
-		22FC70EF173063AF00153630 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
-		22FC70F0173063AF00153630 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
-		22FC70F1173063AF00153630 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
-		22FC70F2173063AF00153630 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
-		22FC70F3173063AF00153630 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
-		22FC70F5173063AF00153630 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
-		22FC70F6173063AF00153630 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
-		22FC70F7173063AF00153630 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
-		22FC70F8173063AF00153630 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
-		22FC70F9173063AF00153630 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
-		22FC70FA173063AF00153630 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
-		22FC70FB173063AF00153630 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
-		22FC70FC173063AF00153630 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		22FC70951730595C00153630 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22FC709C1730595C00153630 /* UIKit.framework in Frameworks */,
-				22FC709E1730595C00153630 /* Foundation.framework in Frameworks */,
-				22FC70A01730595C00153630 /* CoreGraphics.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		22FC708F1730595C00153630 = {
-			isa = PBXGroup;
-			children = (
-				22FC70CA173063AF00153630 /* UGAPI */,
-				22FC70A11730595C00153630 /* browser */,
-				22FC709A1730595C00153630 /* Frameworks */,
-				22FC70991730595C00153630 /* Products */,
-			);
-			sourceTree = "<group>";
-		};
-		22FC70991730595C00153630 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70981730595C00153630 /* browser.app */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		22FC709A1730595C00153630 /* Frameworks */ = {
-			isa = PBXGroup;
-			children = (
-				22FC709B1730595C00153630 /* UIKit.framework */,
-				22FC709D1730595C00153630 /* Foundation.framework */,
-				22FC709F1730595C00153630 /* CoreGraphics.framework */,
-			);
-			name = Frameworks;
-			sourceTree = "<group>";
-		};
-		22FC70A11730595C00153630 /* browser */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70B81730639600153630 /* UGAppDelegate.h */,
-				22FC70B91730639600153630 /* UGAppDelegate.m */,
-				22FC70BA1730639600153630 /* UGAppViewController.h */,
-				22FC70BB1730639600153630 /* UGAppViewController.m */,
-				22FC70BC1730639600153630 /* UGCollectionViewController.h */,
-				22FC70BD1730639600153630 /* UGCollectionViewController.m */,
-				22FC70BE1730639600153630 /* UGEntityViewController.h */,
-				22FC70BF1730639600153630 /* UGEntityViewController.m */,
-				22FC70C01730639600153630 /* UGSignInViewController.h */,
-				22FC70C11730639600153630 /* UGSignInViewController.m */,
-				22FC70C21730639600153630 /* UGTextViewController.h */,
-				22FC70C31730639600153630 /* UGTextViewController.m */,
-				22FC70A21730595C00153630 /* Supporting Files */,
-			);
-			path = browser;
-			sourceTree = "<group>";
-		};
-		22FC70A21730595C00153630 /* Supporting Files */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70A31730595C00153630 /* browser-Info.plist */,
-				22FC70A41730595C00153630 /* InfoPlist.strings */,
-				22FC70A71730595C00153630 /* main.m */,
-				22FC70A91730595C00153630 /* browser-Prefix.pch */,
-				22FC70AD1730595C00153630 /* Default.png */,
-				22FC70AF1730595C00153630 /* Default@2x.png */,
-				22FC70B11730595C00153630 /* Default-568h@2x.png */,
-			);
-			name = "Supporting Files";
-			sourceTree = "<group>";
-		};
-		22FC70CA173063AF00153630 /* UGAPI */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70CB173063AF00153630 /* SBJson */,
-				22FC70E5173063AF00153630 /* UGActivity.h */,
-				22FC70E6173063AF00153630 /* UGActivity.m */,
-				22FC70E7173063AF00153630 /* UGClient.h */,
-				22FC70E8173063AF00153630 /* UGClient.m */,
-				22FC70E9173063AF00153630 /* UGClientDelegate.h */,
-				22FC70EA173063AF00153630 /* UGClientResponse.h */,
-				22FC70EB173063AF00153630 /* UGClientResponse.m */,
-				22FC70EC173063AF00153630 /* UGHTTPManager.h */,
-				22FC70ED173063AF00153630 /* UGHTTPManager.m */,
-				22FC70EE173063AF00153630 /* UGMultiStepAction.h */,
-				22FC70EF173063AF00153630 /* UGMultiStepAction.m */,
-				22FC70F0173063AF00153630 /* UGQuery.h */,
-				22FC70F1173063AF00153630 /* UGQuery.m */,
-				22FC70F2173063AF00153630 /* UGUser.h */,
-				22FC70F3173063AF00153630 /* UGUser.m */,
-				22FC70F4173063AF00153630 /* v2 */,
-			);
-			name = UGAPI;
-			path = ../../UGAPI;
-			sourceTree = "<group>";
-		};
-		22FC70CB173063AF00153630 /* SBJson */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70CC173063AF00153630 /* NSObject+SBJson.h */,
-				22FC70CD173063AF00153630 /* NSObject+SBJson.m */,
-				22FC70CE173063AF00153630 /* SBJson.h */,
-				22FC70CF173063AF00153630 /* SBJsonParser.h */,
-				22FC70D0173063AF00153630 /* SBJsonParser.m */,
-				22FC70D1173063AF00153630 /* SBJsonStreamParser.h */,
-				22FC70D2173063AF00153630 /* SBJsonStreamParser.m */,
-				22FC70D3173063AF00153630 /* SBJsonStreamParserAccumulator.h */,
-				22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */,
-				22FC70D5173063AF00153630 /* SBJsonStreamParserAdapter.h */,
-				22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */,
-				22FC70D7173063AF00153630 /* SBJsonStreamParserState.h */,
-				22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */,
-				22FC70D9173063AF00153630 /* SBJsonStreamWriter.h */,
-				22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */,
-				22FC70DB173063AF00153630 /* SBJsonStreamWriterAccumulator.h */,
-				22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */,
-				22FC70DD173063AF00153630 /* SBJsonStreamWriterState.h */,
-				22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */,
-				22FC70DF173063AF00153630 /* SBJsonTokeniser.h */,
-				22FC70E0173063AF00153630 /* SBJsonTokeniser.m */,
-				22FC70E1173063AF00153630 /* SBJsonUTF8Stream.h */,
-				22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */,
-				22FC70E3173063AF00153630 /* SBJsonWriter.h */,
-				22FC70E4173063AF00153630 /* SBJsonWriter.m */,
-			);
-			path = SBJson;
-			sourceTree = "<group>";
-		};
-		22FC70F4173063AF00153630 /* v2 */ = {
-			isa = PBXGroup;
-			children = (
-				22FC70F5173063AF00153630 /* UGConnection.h */,
-				22FC70F6173063AF00153630 /* UGConnection.m */,
-				22FC70F7173063AF00153630 /* UGHTTPClient.h */,
-				22FC70F8173063AF00153630 /* UGHTTPClient.m */,
-				22FC70F9173063AF00153630 /* UGHTTPHelpers.h */,
-				22FC70FA173063AF00153630 /* UGHTTPHelpers.m */,
-				22FC70FB173063AF00153630 /* UGHTTPResult.h */,
-				22FC70FC173063AF00153630 /* UGHTTPResult.m */,
-			);
-			path = v2;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		22FC70971730595C00153630 /* browser */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 22FC70B51730595C00153630 /* Build configuration list for PBXNativeTarget "browser" */;
-			buildPhases = (
-				22FC70941730595C00153630 /* Sources */,
-				22FC70951730595C00153630 /* Frameworks */,
-				22FC70961730595C00153630 /* Resources */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = browser;
-			productName = browser;
-			productReference = 22FC70981730595C00153630 /* browser.app */;
-			productType = "com.apple.product-type.application";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		22FC70901730595C00153630 /* Project object */ = {
-			isa = PBXProject;
-			attributes = {
-				LastUpgradeCheck = 0460;
-				ORGANIZATIONNAME = "Radtastical Inc.";
-			};
-			buildConfigurationList = 22FC70931730595C00153630 /* Build configuration list for PBXProject "browser" */;
-			compatibilityVersion = "Xcode 3.2";
-			developmentRegion = English;
-			hasScannedForEncodings = 0;
-			knownRegions = (
-				en,
-			);
-			mainGroup = 22FC708F1730595C00153630;
-			productRefGroup = 22FC70991730595C00153630 /* Products */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				22FC70971730595C00153630 /* browser */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
-		22FC70961730595C00153630 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22FC70A61730595C00153630 /* InfoPlist.strings in Resources */,
-				22FC70AE1730595C00153630 /* Default.png in Resources */,
-				22FC70B01730595C00153630 /* Default@2x.png in Resources */,
-				22FC70B21730595C00153630 /* Default-568h@2x.png in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		22FC70941730595C00153630 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22FC70A81730595C00153630 /* main.m in Sources */,
-				22FC70C41730639600153630 /* UGAppDelegate.m in Sources */,
-				22FC70C51730639600153630 /* UGAppViewController.m in Sources */,
-				22FC70C61730639600153630 /* UGCollectionViewController.m in Sources */,
-				22FC70C71730639600153630 /* UGEntityViewController.m in Sources */,
-				22FC70C81730639600153630 /* UGSignInViewController.m in Sources */,
-				22FC70C91730639600153630 /* UGTextViewController.m in Sources */,
-				22FC70FD173063AF00153630 /* NSObject+SBJson.m in Sources */,
-				22FC70FE173063AF00153630 /* SBJsonParser.m in Sources */,
-				22FC70FF173063AF00153630 /* SBJsonStreamParser.m in Sources */,
-				22FC7100173063AF00153630 /* SBJsonStreamParserAccumulator.m in Sources */,
-				22FC7101173063AF00153630 /* SBJsonStreamParserAdapter.m in Sources */,
-				22FC7102173063AF00153630 /* SBJsonStreamParserState.m in Sources */,
-				22FC7103173063AF00153630 /* SBJsonStreamWriter.m in Sources */,
-				22FC7104173063AF00153630 /* SBJsonStreamWriterAccumulator.m in Sources */,
-				22FC7105173063AF00153630 /* SBJsonStreamWriterState.m in Sources */,
-				22FC7106173063AF00153630 /* SBJsonTokeniser.m in Sources */,
-				22FC7107173063AF00153630 /* SBJsonUTF8Stream.m in Sources */,
-				22FC7108173063AF00153630 /* SBJsonWriter.m in Sources */,
-				22FC7109173063AF00153630 /* UGActivity.m in Sources */,
-				22FC710A173063AF00153630 /* UGClient.m in Sources */,
-				22FC710B173063AF00153630 /* UGClientResponse.m in Sources */,
-				22FC710C173063AF00153630 /* UGHTTPManager.m in Sources */,
-				22FC710D173063AF00153630 /* UGMultiStepAction.m in Sources */,
-				22FC710E173063AF00153630 /* UGQuery.m in Sources */,
-				22FC710F173063AF00153630 /* UGUser.m in Sources */,
-				22FC7110173063AF00153630 /* UGConnection.m in Sources */,
-				22FC7111173063AF00153630 /* UGHTTPClient.m in Sources */,
-				22FC7112173063AF00153630 /* UGHTTPHelpers.m in Sources */,
-				22FC7113173063AF00153630 /* UGHTTPResult.m in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXVariantGroup section */
-		22FC70A41730595C00153630 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				22FC70A51730595C00153630 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		22FC70B31730595C00153630 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = NO;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					"DEBUG=1",
-					"$(inherited)",
-				);
-				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				ONLY_ACTIVE_ARCH = YES;
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-			};
-			name = Debug;
-		};
-		22FC70B41730595C00153630 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = YES;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-				VALIDATE_PRODUCT = YES;
-			};
-			name = Release;
-		};
-		22FC70B61730595C00153630 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "browser/browser-Prefix.pch";
-				INFOPLIST_FILE = "browser/browser-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Debug;
-		};
-		22FC70B71730595C00153630 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "browser/browser-Prefix.pch";
-				INFOPLIST_FILE = "browser/browser-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		22FC70931730595C00153630 /* Build configuration list for PBXProject "browser" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				22FC70B31730595C00153630 /* Debug */,
-				22FC70B41730595C00153630 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		22FC70B51730595C00153630 /* Build configuration list for PBXNativeTarget "browser" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				22FC70B61730595C00153630 /* Debug */,
-				22FC70B71730595C00153630 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 22FC70901730595C00153630 /* Project object */;
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/Default-568h@2x.png b/sdks/ios/samples/Browser/browser/Default-568h@2x.png
deleted file mode 100644
index 0891b7a..0000000
Binary files a/sdks/ios/samples/Browser/browser/Default-568h@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/Default.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/Default.png b/sdks/ios/samples/Browser/browser/Default.png
deleted file mode 100644
index 4c8ca6f..0000000
Binary files a/sdks/ios/samples/Browser/browser/Default.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/Default@2x.png b/sdks/ios/samples/Browser/browser/Default@2x.png
deleted file mode 100644
index 35b84cf..0000000
Binary files a/sdks/ios/samples/Browser/browser/Default@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGAppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGAppDelegate.h b/sdks/ios/samples/Browser/browser/UGAppDelegate.h
deleted file mode 100644
index fb1453f..0000000
--- a/sdks/ios/samples/Browser/browser/UGAppDelegate.h
+++ /dev/null
@@ -1,24 +0,0 @@
-//
-//  UGAppDelegate.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@interface UGAppDelegate : UIResponder <UIApplicationDelegate>
-
-@property (strong, nonatomic) UIWindow *window;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGAppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGAppDelegate.m b/sdks/ios/samples/Browser/browser/UGAppDelegate.m
deleted file mode 100644
index 246a860..0000000
--- a/sdks/ios/samples/Browser/browser/UGAppDelegate.m
+++ /dev/null
@@ -1,39 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGAppDelegate.m
-//  Browser
-//
-
-#import "UGAppDelegate.h"
-#import "UGAppViewController.h"
-
-@implementation UGAppDelegate
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
-    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
-    UINavigationController *navigationController = [[UINavigationController alloc]
-                                                    initWithRootViewController:[[UGAppViewController alloc] init]];
-    navigationController.navigationBar.tintColor = [UIColor darkGrayColor];
-    self.window.rootViewController = navigationController;
-    [self.window makeKeyAndVisible];
-    return YES;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGAppViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGAppViewController.h b/sdks/ios/samples/Browser/browser/UGAppViewController.h
deleted file mode 100644
index 7f26de9..0000000
--- a/sdks/ios/samples/Browser/browser/UGAppViewController.h
+++ /dev/null
@@ -1,27 +0,0 @@
-//
-//  UGAppViewController.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@interface UGAppViewController : UITableViewController
-@property (nonatomic, strong) NSDictionary *application;
-
-
-- (void) downloadApplicationDescription;
-
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGAppViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGAppViewController.m b/sdks/ios/samples/Browser/browser/UGAppViewController.m
deleted file mode 100644
index b298fe1..0000000
--- a/sdks/ios/samples/Browser/browser/UGAppViewController.m
+++ /dev/null
@@ -1,143 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGAppViewController.m
-//  Browser
-//
-
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-#import "UGConnection.h"
-#import "UGAppViewController.h"
-#import "UGSignInViewController.h"
-#import "UGCollectionViewController.h"
-
-@interface UGAppViewController ()
-
-@end
-
-@implementation UGAppViewController
-
-- (void) loadView
-{
-    [super loadView];
-    self.navigationItem.title = @"Usergrid";
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithTitle:@"Connection"
-                                             style:UIBarButtonItemStyleBordered
-                                             target:self
-                                             action:@selector(connect:)];
-}
-
-- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
-{
-    if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
-        return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
-    } else {
-        return YES;
-    }
-}
-
-- (void) connect:(id) sender
-{
-    UGSignInViewController *signinViewController = [[UGSignInViewController alloc] init];
-    signinViewController.appViewController = self;
-    UINavigationController *signinNavigationController =
-    [[UINavigationController alloc] initWithRootViewController:signinViewController];
-    signinNavigationController.modalPresentationStyle = UIModalPresentationFormSheet;
-    signinNavigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
-    [self presentModalViewController:signinNavigationController animated:YES];
-}
-
-- (void) downloadApplicationDescription
-{
-    UGConnection *usergrid = [UGConnection sharedConnection];
-    [[[UGHTTPClient alloc]
-      initWithRequest:[usergrid getApplication:usergrid.application inOrganization:usergrid.organization]]
-     connectWithCompletionHandler:^(UGHTTPResult *result) {
-         self.application = result.object[@"entities"][0];
-         [self.tableView reloadData];
-     }];
-}
-
-- (NSInteger) numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return self.application ? 2 : 0;
-}
-
-- (NSInteger) tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    if (section == 0) {
-        return self.application ? 1 : 0;
-    } else if (section == 1) {
-        return self.application ? [self.application[@"metadata"][@"collections"] count] : 0;
-    } else {
-        return 0;
-    }
-}
-
-- (UITableViewCell *) tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
-    cell.backgroundColor = [UIColor whiteColor];
-    return cell;
-}
-
-- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if ([indexPath section] == 0) {
-        cell.textLabel.text = self.application[@"name"];
-        cell.accessoryType = UITableViewCellAccessoryNone;
-    } else {
-        NSDictionary *collections = self.application[@"metadata"][@"collections"];
-        NSString *key =  [[[collections allKeys] sortedArrayUsingSelector:@selector(compare:)] objectAtIndex:[indexPath row]];
-        NSDictionary *object = collections[key];
-        cell.textLabel.text = [NSString stringWithFormat:@"%@",
-                               object[@"title"]];
-        cell.detailTextLabel.text = [NSString stringWithFormat:@"name:%@ type:%@",
-                                     object[@"name"],
-                                     object[@"type"]];
-        cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
-    }
-    cell.backgroundColor = [UIColor whiteColor];
-    cell.selectionStyle = UITableViewCellSelectionStyleGray;
-}
-
-- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
-{
-    if (section == 0) {
-        return @"Application";
-    } else {
-        return @"Collections";
-    }
-}
-
-- (void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    [tableView deselectRowAtIndexPath:indexPath animated:YES];
-    if ([indexPath section] == 1) {
-        NSDictionary *collections = self.application[@"metadata"][@"collections"];
-        NSString *key =  [[[collections allKeys] sortedArrayUsingSelector:@selector(compare:)] objectAtIndex:[indexPath row]];
-        NSDictionary *collection = collections[key];
-        UGCollectionViewController *collectionViewController = [[UGCollectionViewController alloc] init];
-        collectionViewController.collection = collection;
-        [self.navigationController pushViewController:collectionViewController animated:YES];
-    }
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGCollectionViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGCollectionViewController.h b/sdks/ios/samples/Browser/browser/UGCollectionViewController.h
deleted file mode 100644
index 1b0074b..0000000
--- a/sdks/ios/samples/Browser/browser/UGCollectionViewController.h
+++ /dev/null
@@ -1,23 +0,0 @@
-//
-//  UGCollectionViewController.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@interface UGCollectionViewController : UITableViewController
-@property (nonatomic, strong) NSDictionary *collection;
-@property (nonatomic, strong) NSDictionary *collectionDetail;
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGCollectionViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGCollectionViewController.m b/sdks/ios/samples/Browser/browser/UGCollectionViewController.m
deleted file mode 100644
index 720bd09..0000000
--- a/sdks/ios/samples/Browser/browser/UGCollectionViewController.m
+++ /dev/null
@@ -1,115 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGCollectionViewController.m
-//  Browser
-//
-
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-#import "UGConnection.h"
-#import "UGCollectionViewController.h"
-#import "UGEntityViewController.h"
-
-@interface UGCollectionViewController ()
-
-@end
-
-@implementation UGCollectionViewController
-
-- (id)initWithStyle:(UITableViewStyle)style
-{
-    self = [super initWithStyle:style];
-    if (self) {
-        // Custom initialization
-    }
-    return self;
-}
-
-- (void) loadView
-{
-    [super loadView];
-}
-
-- (void)didReceiveMemoryWarning
-{
-    [super didReceiveMemoryWarning];
-    // Dispose of any resources that can be recreated.
-}
-
-- (void) getCollection
-{
-    [[[UGHTTPClient alloc] initWithRequest:[[UGConnection sharedConnection]
-                                            getEntitiesInCollection:self.collection[@"name"]
-                                            limit:200]]
-     connectWithCompletionHandler:^(UGHTTPResult *result) {
-         self.collectionDetail = result.object;
-         [self.tableView reloadData];
-         self.navigationItem.title = result.object[@"path"];
-     }];
-}
-
-- (void) viewWillAppear:(BOOL)animated
-{
-    [self getCollection];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    if (!self.collectionDetail) {
-        return 0;
-    } else {
-        return [self.collectionDetail[@"count"] intValue];
-    }
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
-    cell.textLabel.font = [UIFont boldSystemFontOfSize:14];
-    return cell;
-}
-
-- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    int row = [indexPath row];
-    NSDictionary *entity = self.collectionDetail[@"entities"][row];
-    cell.textLabel.text = entity[@"name"];
-    cell.detailTextLabel.text = entity[@"uuid"];
-}
-
-
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UGEntityViewController *entityViewController = [[UGEntityViewController alloc] init];
-    int row = [indexPath row];
-    entityViewController.entity = self.collectionDetail[@"entities"][row];
-    [self.navigationController pushViewController:entityViewController animated:YES];
-}
-
-@end


[33/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGClient.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGClient.h b/sdks/other/ios/UGAPI/UGClient.h
new file mode 100755
index 0000000..4e6a31f
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGClient.h
@@ -0,0 +1,328 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+#import "UGClientResponse.h"
+#import "UGQuery.h"
+#import "UGActivity.h"
+#import "UGUser.h"
+
+/******************** A WORD ON NETWORK COMMUNICATION CALLS ****************
+Some calls require network communication with UserGrid. Therefore,
+they all have the option of being synchronous (blocking) or asynchronous.
+
+You may specify an asynchronous delegate with the call setDelegate. If you
+do, all calls will be asynchronous and responses will be sent to that delegate. 
+The immediate return value (a UGClientResponse *) from any call will have its
+transactionState set to kUGClientResponsePending, and the transactionID will be
+properly set (allowing you to identify the specific call in your callback if you
+wish.)
+ 
+The delegate must support the following message:
+-(void)ugClientResponse:(UGClientResponse *)response
+
+If you do not set a delegate, all functions will run synchronously, blocking 
+until a response has been received or an error detected. 
+****************************************************************************/
+
+
+/**************************** A WORD ON UGQUERY *****************************
+Some calls take a UGQuery *. These are functions that return a lot of data, as 
+opposed to a simple answer. You may use the UGQuery to control the data with filters
+and response limits. See UGQuery.h for more information.
+
+In all cases, where a UGQuery is one of the parameters, you may send nil. If you
+do, the query will be completely unfiltered, and you will receive back *all* the data
+associated with the operation, up to the response limit, which is 10. You can
+set the response limit in UGQuery as well. 
+****************************************************************************/
+
+
+@interface UGClient : NSObject
+
++(NSString *) version;
+
+/********************* INIT AND SETUP *********************/
+// init with an app ID
+-(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID;
+
+// init with an app ID and a base UserGrid URL. This is useful if you
+// are running a local UG server or your company has its own public
+// UG server. The default URL is http://api.usergrid.com. The base URL
+// must be a fully formated http link, including the "http://" at the
+// beginning.
+-(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID baseURL:(NSString *)baseURL;
+
+// set the delegate. See "A WORD ON NETWORK COMMUNICATION CALLS"
+// at the top of the file for a detailed explanation. The function
+// will return NO if the delegate is rejected. This means the delegate
+// does not support the required delegation function "ugClientResponse".
+//
+// This is the formal declaration of ugClientResponse:
+// -(void)ugClientResponse:(UGClientResponse *)response
+// 
+// You may change the delegate at any time, but be forewarned that any
+// pending transactions in progress will be abandoned. Changing the delegate
+// (especially setting it to nil) ensures that hte previous delegate will
+// receive no further messages from this instance of UGClient. 
+// 
+// Setting the delegate to nil puts the API in to synchronous mode.
+-(BOOL) setDelegate:(id)delegate;
+
+
+/********************* LOGIN / LOGOUT *********************/
+// log in with the given username and password
+-(UGClientResponse *)logInUser: (NSString *)userName password:(NSString *)password;
+
+// log in with the given username and PIN value
+-(UGClientResponse *)logInUserWithPin: (NSString *)userName pin:(NSString *)pin;
+
+// log in user with Facebook token
+//
+//  //sample usage:
+//  NSString * facebookToken = @"your-facebook-token";
+//  UGClientResponse *response = [usergridClient logInUserWithFacebook:facebookToken];
+//  user = [usergridClient getLoggedInUser];
+//  if (user.username){
+//    return true;
+//  } else {
+//    return false;
+//  }
+//
+-(UGClientResponse *)logInUserWithFacebook: (NSString *)facebookToken;
+
+// log in as the administrator of the application. Generally used for applications
+// that have an "administrator" feature. Not the sort of thing you want normal
+// users doing. 
+-(UGClientResponse *)logInAdmin: (NSString *)adminUserName secret:(NSString *)adminSecret;
+
+// log out the current user. The Client only supports one user logged in at a time.
+// You can have multiple instances of UGClient if you want multiple
+// users doing transactions simultaneously. This does not require network communication,
+// so it has no return. It doesn't actually "log out" from the server. It simply clears 
+// the locally stored auth information
+-(void)logOut;
+
+
+
+/********************* USER MANAGEMENT *********************/
+//adds a new user
+-(UGClientResponse *)addUser:(NSString *)username email:(NSString *)email name:(NSString *)name password:(NSString *)password;
+
+// updates a user's password
+-(UGClientResponse *)updateUserPassword:(NSString *)usernameOrEmail oldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword;
+
+// get all the groups this user is in
+-(UGClientResponse *)getGroupsForUser: (NSString *)userID;
+
+// get users in this app. Definitely want to consider sending a Query along
+// with this call
+-(UGClientResponse *)getUsers: (UGQuery *)query;
+
+/********************* ACTIVITY MANAGEMENT *********************/
+// create a new activity. 
+// Note that there is a class, UGActivity, which can help
+// you create and validate an Activity, and will generate the needed
+// NSDictionary for you.
+-(UGClientResponse *)createActivity: (NSDictionary *)activity;
+
+// create an activity and post it to a user in a single step. See comment
+// above createActivity for information on making Activity creation easier
+-(UGClientResponse *)postUserActivity: (NSString *)userID activity:(NSDictionary *)activity;
+
+// post an already-created activity to a user
+-(UGClientResponse *)postUserActivityByUUID: (NSString *)userID activity:(NSString *)activityUUID;
+
+// create an activity and post it to a group in a single step. See comment
+// above createActivity for information on making Activity creation easier
+-(UGClientResponse *)postGroupActivity: (NSString *)groupID activity:(NSDictionary *)activity;
+
+// post an already-created activity to a group
+-(UGClientResponse *)postGroupActivityByUUID: (NSString *)groupID activity:(NSString *)activityUUID;
+
+// get the activities this user is in
+-(UGClientResponse *)getActivitiesForUser: (NSString *)userID query:(UGQuery *)query;
+
+// get the activities this group is in
+-(UGClientResponse *)getActivitiesForGroup: (NSString *)groupID query:(UGQuery *)query;
+
+// get the activity feed for a user
+-(UGClientResponse *)getActivityFeedForUser: (NSString *)userID query:(UGQuery *)query;
+
+// get the activity feed for a group
+-(UGClientResponse *)getActivityFeedForGroup: (NSString *)groupID query:(UGQuery *)query;
+
+// remove an activity 
+-(UGClientResponse *)removeActivity:(NSString *)activityUUID;
+
+/********************* GROUP MANAGEMENT *********************/
+// create a new group. The groupPath can be a path with slashes to make for
+// a hierarchical structure of your own design (if you want). groupTitle is
+// optional, you can send nil if you don't want to provide one.
+-(UGClientResponse *)createGroup:(NSString *)groupPath groupTitle:(NSString *)groupTitle;
+
+// add a user to a group
+-(UGClientResponse *)addUserToGroup:(NSString *)userID group:(NSString *)groupID;
+
+// remove a user from a group
+-(UGClientResponse *)removeUserFromGroup:(NSString *)userID group:(NSString *)groupID;
+
+// get all the users in this group
+-(UGClientResponse *)getUsersForGroup:(NSString *)groupID query:(UGQuery *)query;
+
+
+
+/******************** ENTITY MANAGEMENT ********************/
+// adds an entity to the specified collection. 
+-(UGClientResponse *)createEntity: (NSDictionary *)newEntity;
+
+// get a list of entities that meet the specified query.
+-(UGClientResponse *)getEntities: (NSString *)type query:(UGQuery *)query;
+
+// updates an entity (it knows the type from the entity data) 
+-(UGClientResponse *)updateEntity: (NSString *)entityID entity:(NSDictionary *)updatedEntity;
+
+// removes an entity of the specified type
+-(UGClientResponse *)removeEntity: (NSString *)type entityID:(NSString *)entityID;
+
+// Directionally connect two entities. For instance, user "Bob" might like Lyons Restaurant.
+// connectorType would be "users" (because Bob is a user)
+// connectorID would be Bob's userID
+// connectionType would be "like"
+// connecteeID would be the UUID of Lyons Restaurant
+-(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID;
+
+// Directionally connect two entities. For instance, user "Bob" might follow user "Mary".
+// connectorType would be "users" (because Bob is a user)
+// connectorID would be Bob's userID
+// connectionType would be "like"
+// connecteeType would  be "users" (because Mary is a user)
+// connecteeID would be Mary's userID
+-(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType connecteeType:(NSString *)connecteeType connecteeID:(NSString *)connecteeID;
+
+// disconnect two entities. It uses the same parameters and calling rules as connectEntities
+-(UGClientResponse *)disconnectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID;
+
+// get entity connections
+-(UGClientResponse *)getEntityConnections: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType query:(UGQuery *)query;
+
+
+
+/********************* MESSAGE MANAGEMENT *********************/
+// post a message to a given queue
+-(UGClientResponse *)postMessage: (NSString *)queuePath message:(NSDictionary *)message;
+
+// get all messages from the queue path
+-(UGClientResponse *)getMessages: (NSString *)queuePath query:(UGQuery *)query;
+
+// add a subscriber to a queue
+-(UGClientResponse *)addSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath;
+
+// remove a subscriber from a queue
+-(UGClientResponse *)removeSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath;
+
+
+/********************* SERVER-SIDE STORAGE *********************/
+// these functions refer to data that can be put in a special place 
+// specific to this device. Every call to remoteStorage replaces whatever 
+// was there before
+
+// put the data in to the remote storage
+-(UGClientResponse *)setRemoteStorage: (NSDictionary *)data;
+
+// get the data from remote storage
+-(UGClientResponse *)getRemoteStorage;
+
+// a class function that returns a uuid for this
+// device. It will be globally unique, and will always
+// return the same value for the same handset.
+// NOTE - This value will change if the operating
+// system is reinstalled. This function is used internally, but
+// is also handy for clients, so it is part of the interface.
++(NSString *)getUniqueDeviceID;
+
+/***************** REMOTE PUSH NOTIFICATIONS *****************/
+
+// call from application:didRegisterForRemoteNotificationsWithDeviceToken: callback
+// will automatically register the passed deviceToken with the usergrid system
+// using the getUniqueDeviceID method to associate this device on the server
+- (UGClientResponse *)setDevicePushToken:(NSData *)newDeviceToken forNotifier:(NSString *)notifier;
+
+// push an "alert" type notification to the remote group, user, or device specified
+// in the path argument. the notifer may be a name or UUID of an apns notifier
+// that has been set up on the usergrid server.
+- (UGClientResponse *)pushAlert:(NSString *)message
+                      withSound:(NSString *)sound
+                             to:(NSString *)path
+                  usingNotifier:(NSString *)notifier;
+
+/*********************** ACCESSORS ************************/
+// if a user is logged in, this returns the OAuth token for this session. 
+// UGClient manages this internally, so you never really need it. But if you
+// want it for other reasons, this accessor gives it to you. If you have not
+// successfully logged in, this will return nil
+-(NSString *)getAccessToken;
+
+// returns information about the logged in user
+-(UGUser *)getLoggedInUser;
+
+// returns the delegate that is currently being used for asynch
+// calls. Returns nil if there is no delegate (synch mode)
+-(id) getDelegate;
+
+/*********************** OBLIQUE USAGE ************************/
+// This is a general purpose function for directly accessing the
+// UserGrid service. This is useful if the service has new features 
+// that the API has not yet supported, or if you are using an older 
+// version of the API and don't want to upgrade.
+// 
+// url: The full URL that you are accessing. You are responsible for 
+//      assembling it, including the appID and all sub-sections down the line
+//
+// op: The HttpMethod being invoked. Examples: @"POST", @"PUT", etc. You may
+//     send nil. If you do, the operation is GET. There is one specially supported
+//     method called "POSTFORM". This will post with the data type set to 
+//     application/x-www-form-urlencoded instead of the more likely needed
+//     application/json. This is necessary if you are doing authentication
+//     or if you are sending form data up. 
+//
+// opData: The data sent along with the operation. You may send nil. If the 
+//         operation is GET, this value is ignored. Usually, this would be
+//         expected to be in json format. With this oblique approach, it is
+//         your responsibility to format the data correctly for whatever you're
+//         doing. Bear in mind that this api comes with SBJson, which provides
+//         some very simple ways to assemble json formatted strings. See SBJsonWriter.
+//
+// NOTE - This function will be synchronous or asynchronous the same as any
+// other function in the API. It is based on the value sent to setDelegate.
+-(UGClientResponse *)apiRequest: (NSString *)url operation:(NSString *)op data:(NSString *)opData;
+
+/*********************** DEBUGGING ASSISTANCE ************************/
+// when logging is on, all outgoing URLs are logged via NSLog, and all
+// incoming data from the service is also logged. Additionally, any errors
+// encountered internally are logged. This can be helpful to see the actual
+// service communication in progress and help debug problems you may be having. 
+-(void)setLogging: (BOOL)loggingState;
+
+/*********************** VERSION CHECKING ************************/
+#define SYSTEM_VERSION_EQUAL_TO(v)                  ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedSame)
+#define SYSTEM_VERSION_GREATER_THAN(v)              ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedDescending)
+#define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v)  ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending)
+#define SYSTEM_VERSION_LESS_THAN(v)                 ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedAscending)
+#define SYSTEM_VERSION_LESS_THAN_OR_EQUAL_TO(v)     ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedDescending)
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGClient.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGClient.m b/sdks/other/ios/UGAPI/UGClient.m
new file mode 100755
index 0000000..9d6407a
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGClient.m
@@ -0,0 +1,1252 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGClient.h"
+#import "UGHTTPManager.h"
+#import "SBJson.h"
+#import "UGMultiStepAction.h"
+#import "SSKeychain.h"
+
+NSString *g_deviceUUID = nil;
+
+@implementation UGClient
+{
+    // the delegate for asynch callbacks
+    id m_delegate;
+    
+    // the mutex to protect the delegate variable
+    NSRecursiveLock *m_delegateLock;
+    
+    // a growing array of UGHTTPManager instances. See
+    // "HTTPMANAGER POOLING" further down in this file.
+    NSMutableArray *m_httpManagerPool;
+    
+    // the base URL for the service
+    NSString *m_baseURL;
+    
+    // the appID for the specific app
+    NSString *m_appID;
+    
+    // the appID for the specific app
+    NSString *m_orgID;
+    
+    // the cached auth token
+    UGUser *m_loggedInUser;
+    
+    // the auth code
+    NSString *m_auth;
+    
+    // the list of currently pending multi-step actions
+    NSMutableArray *m_pendingMultiStepActions;
+    
+    // logging state
+    BOOL m_bLogging;
+}
+
+/************************** ACCESSORS *******************************/
+/************************** ACCESSORS *******************************/
+/************************** ACCESSORS *******************************/
++(NSString *) version
+{
+    return @"0.1.1";
+}
+
+-(NSString *)getAccessToken
+{
+    return m_auth;
+}
+
+-(UGUser *)getLoggedInUser
+{
+    return m_loggedInUser;
+}
+
+-(id) getDelegate
+{
+    return m_delegate;
+}
+
+/******************************* INIT *************************************/
+/******************************* INIT *************************************/
+/******************************* INIT *************************************/
+-(id)init
+{
+    // you are not allowed to init without an organization id and application id
+    // you can't init with [UGClient new]. You must call
+    // [[UGClient alloc] initWithOrganizationId: <your UG org id> withApplicationId:<your UG app id>]
+    assert(0); 
+    return nil;
+}
+
+-(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID
+{
+    self = [super init];
+    if ( self )
+    {
+        m_delegate = nil;
+        m_httpManagerPool = [NSMutableArray new];
+        m_delegateLock = [NSRecursiveLock new];
+        m_appID = applicationID;
+        m_orgID = organizationID;
+        m_baseURL = @"http://api.usergrid.com";
+        m_pendingMultiStepActions = [NSMutableArray new];
+        m_loggedInUser = nil;
+        m_bLogging = NO;
+    }
+    return self;
+}
+
+-(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID baseURL:(NSString *)baseURL
+{
+    self = [super init];
+    if ( self )
+    {
+        m_delegate = nil;
+        m_httpManagerPool = [NSMutableArray new];
+        m_delegateLock = [NSRecursiveLock new];
+        m_appID = applicationID;
+        m_orgID = organizationID;
+        m_baseURL = baseURL;
+    }
+    return self;
+}
+
+-(BOOL) setDelegate:(id)delegate
+{
+    // first off, clear any pending transactions
+    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
+    {
+        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
+        
+        // it's safe to call cancel at all times.
+        [mgr cancel];
+    }
+    
+    // nil is a valid answer. It means we're synchronous now.
+    if ( delegate == nil )
+    {
+        [m_delegateLock lock];
+        m_delegate = nil;
+        [m_delegateLock unlock];
+        return YES;
+    }
+    
+    // if it's not nil, it has to have the delegation function
+    if ( ![delegate respondsToSelector:@selector(ugClientResponse:)] )
+    {
+        return NO;
+    }
+    
+    // if we're here, it means the delegate is valid
+    [m_delegateLock lock];
+    m_delegate = delegate;
+    [m_delegateLock unlock];
+    return YES;
+}
+
+/************************* HTTPMANAGER POOLING *******************************/
+/************************* HTTPMANAGER POOLING *******************************/
+/************************* HTTPMANAGER POOLING *******************************/
+
+// any given instance of UGHTTPManager can only manage one transaction at a time,
+// but we want the client to be able to have as many going at once as he likes. 
+// so we have a pool of UGHTTPManagers as needed.
+-(UGHTTPManager *)getHTTPManager;
+{
+    // find the first unused HTTPManager
+    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
+    {
+        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
+        if ( [mgr isAvailable] )
+        {
+            // tag this guy as available
+            [mgr setAvailable:NO];
+            
+            // return him
+            return mgr;
+        }
+    }
+    
+    // if we're here, we didn't find any available managers
+    // so we'll need to make a new one
+    UGHTTPManager *newMgr = [UGHTTPManager new];
+    
+    // mark it as in-use (we're about to return it)
+    [newMgr setAvailable:NO];
+    
+    // tell it the auth to use
+    [newMgr setAuth:m_auth];
+    
+    // add it to the array
+    [m_httpManagerPool addObject:newMgr];
+    
+    // return it
+    return newMgr;
+}
+
+-(void)releaseHTTPManager:(UGHTTPManager *)toRelease
+{
+    [toRelease setAvailable:YES];
+}
+
+-(void)setAuth:(NSString *)auth
+{
+    // note the auth for ourselves
+    m_auth = auth;
+    
+    // update all our managers
+    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
+    {
+        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
+        [mgr setAuth:m_auth];
+    }
+}
+
+/************************* GENERAL WORKHORSES *******************************/
+/************************* GENERAL WORKHORSES *******************************/
+/************************* GENERAL WORKHORSES *******************************/
+// url: the URL to hit
+// op: a kUGHTTP constant. Example: kUGHTTPPost
+// opData: The data to send along with the operation. Can be nil
+-(UGClientResponse *)httpTransaction:(NSString *)url op:(int)op opData:(NSString *)opData
+{
+    // get an http manager to do this transaction
+    UGHTTPManager *mgr = [self getHTTPManager];
+    
+    if ( m_delegate )
+    {
+        if ( m_bLogging )
+        {
+            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>");
+            NSLog(@"Asynch outgoing call: '%@'", url);
+        }
+        
+        // asynch transaction
+        int transactionID = [mgr asyncTransaction:url operation:op operationData:opData delegate:self];
+        
+        if ( m_bLogging )
+        {
+            NSLog(@"Transaction ID:%d", transactionID);
+            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\n\n");
+        }
+        
+        if ( transactionID == -1 )
+        {
+            if ( m_bLogging )
+            {
+                NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
+                NSLog(@"Response: ERROR: %@", [mgr getLastError]);
+                NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
+            }
+            
+            // there was an immediate failure in the transaction
+            UGClientResponse *response = [UGClientResponse new];
+            [response setTransactionID:-1];
+            [response setTransactionState:kUGClientResponseFailure];
+            [response setResponse:[mgr getLastError]];
+            [response setRawResponse:nil];
+            return response;
+        }
+        else 
+        {
+            // the transaction is in progress and pending
+            UGClientResponse *response = [UGClientResponse new];
+            [response setTransactionID:transactionID];
+            [response setTransactionState:kUGClientResponsePending];
+            [response setResponse:nil];
+            [response setRawResponse:nil];
+            return response;
+        }
+    }
+    else 
+    {
+        if ( m_bLogging )
+        {
+            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>");
+            NSLog(@"Synch outgoing call: '%@'", url);
+            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\n\n");
+        }
+        
+        // synch transaction
+        NSString *result = [mgr syncTransaction:url operation:op operationData:opData];
+        
+        if ( m_bLogging )
+        {
+            NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
+            if ( result )
+            {
+                NSLog(@"Response:\n%@", result);
+            }
+            else
+            {
+                NSLog(@"Response: ERROR: %@", [mgr getLastError]);
+            }
+            NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
+        }
+        
+        // since we're doing a synch transaction, we are now done with this manager.
+        [self releaseHTTPManager:mgr];
+        
+        if ( result )
+        {
+            // got a valid result
+            UGClientResponse *response = [self createResponse:-1 jsonStr:result];
+            return response;
+        }
+        else 
+        {
+            // there was an error. Note the failure state, set the response to 
+            // be the error string
+            UGClientResponse *response = [UGClientResponse new];
+            [response setTransactionID:-1];
+            [response setTransactionState:kUGClientResponseFailure];
+            [response setResponse:[mgr getLastError]];
+            [response setRawResponse:nil];
+            return response;
+        }
+    }
+}
+
+-(UGClientResponse *)createResponse:(int)transactionID jsonStr:(NSString *)jsonStr
+{
+    UGClientResponse *response = [UGClientResponse new];
+    
+    // set the raw response and transaction id
+    [response setRawResponse:jsonStr];
+    [response setTransactionID:transactionID];
+    
+    // parse the json
+    SBJsonParser *parser = [SBJsonParser new];
+    NSError *error;
+    id result = [parser objectWithString:jsonStr error:&error];
+    
+    if ( result )
+    {
+        // first off, if the result is NOT an NSDictionary, something went wrong.
+        // there should never be an array response
+        if ( ![result isKindOfClass:[NSDictionary class]] )
+        {
+            [response setTransactionState:kUGClientResponseFailure];
+            [response setResponse:@"Internal error: Response parsed to something other than NSDictionary"];
+            return response;
+        }
+        
+        // it successfully parsed. Though the result might still be an error.
+        // it could be the server returning an error in perfectly formated json.
+        NSString *err = [result valueForKey:@"error"];
+        if ( err )
+        {
+            // there was an error. See if there's a more detailed description.
+            // if there is, we'll use that. If not, we'll use the error value
+            // itself.
+            NSString *errDesc = [result valueForKey:@"error_description"];
+            NSString *toReport = errDesc;
+            if ( !toReport ) toReport = err;
+            
+            [response setTransactionState:kUGClientResponseFailure];
+            [response setResponse:toReport];
+            return response;
+        }
+        
+        // if we're here we have a good auth. make note of it
+        NSString *auth = [result valueForKey:@"access_token"];
+        if ( auth )
+        {
+            [self setAuth: auth];
+            
+            // if there's an access token, there might be a user
+            NSDictionary *dict = [result objectForKey:@"user"];
+            if ( dict )
+            {
+                // get the fields for the user
+                m_loggedInUser = [UGUser new];
+                [m_loggedInUser setUsername:[dict valueForKey:@"username"]];
+                [m_loggedInUser setUuid:[dict valueForKey:@"uuid"]];
+                [m_loggedInUser setEmail:[dict valueForKey:@"email"]];
+                [m_loggedInUser setPicture:[dict valueForKey:@"picture"]];
+            }
+        }
+        
+        [response setTransactionState:kUGClientResponseSuccess];
+        [response setResponse:result];
+        return response;
+    }
+    else
+    {
+        // there was an error during json parsing. 
+        [response setTransactionState:kUGClientResponseFailure];
+        [response setResponse:[error localizedDescription]];
+        return response;
+    }
+}
+
+// basic URL assembly functions. For convenience
+-(NSMutableString *)createURL:(NSString *)append1
+{
+    NSMutableString *ret = [NSMutableString new];
+    [ret appendFormat:@"%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1];
+    return ret;
+}
+
+-(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2
+{
+    NSMutableString *ret = [NSMutableString new];
+    [ret appendFormat:@"%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2];
+    return ret;
+}
+
+-(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3
+{
+    NSMutableString *ret = [NSMutableString new];
+    [ret appendFormat:@"%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3];
+    return ret;
+}
+
+-(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3 append4:(NSString *)append4
+{
+    NSMutableString *ret = [NSMutableString new];
+    [ret appendFormat:@"%@/%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3, append4];
+    return ret;
+}
+
+-(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3 append4:(NSString *)append4 append5:(NSString *)append5
+{
+    NSMutableString *ret = [NSMutableString new];
+    [ret appendFormat:@"%@/%@/%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3, append4, append5];
+    return ret;
+}
+
+-(void)appendQueryToURL:(NSMutableString *)url query:(UGQuery *)query
+{
+    if ( query )
+    {
+        [url appendFormat:@"%@", [query getURLAppend]];
+    }
+}
+
+-(NSString *)createJSON:(NSDictionary *)data
+{
+    NSString *ret = [self createJSON:data error:nil];
+
+    // the only way for ret to be nil here is for an internal
+    // function to have a bug.
+    assert(ret);
+    return ret;
+}
+
+-(NSString *)createJSON:(NSDictionary *)data error:(NSString **)error
+{
+    SBJsonWriter *writer = [SBJsonWriter new];
+    NSError *jsonError;
+    NSString *jsonStr = [writer stringWithObject:data error:&jsonError];
+
+    if ( jsonStr )
+    {
+        return jsonStr;
+    }
+    
+    // if we're here, there was an assembly error
+    if ( error )
+    {
+        *error = [jsonError localizedDescription];
+    }
+    return nil;
+}
+
+/************************** UGHTTPMANAGER DELEGATES *******************************/
+/************************** UGHTTPMANAGER DELEGATES *******************************/
+/************************** UGHTTPMANAGER DELEGATES *******************************/
+-(void)httpManagerError:(UGHTTPManager *)manager error:(NSString *)error
+{
+    // prep an error response
+    UGClientResponse *response = [UGClientResponse new];
+    [response setTransactionID:[manager getTransactionID]];
+    [response setTransactionState:kUGClientResponseFailure];
+    [response setResponse:error];
+    [response setRawResponse:nil];
+
+    if ( m_bLogging )
+    {
+        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
+        NSLog(@"Response: ERROR: %@", error);
+        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
+    }
+    
+    // fire it off. Wrap in mutex locks to ensure we don't get 
+    // race conditions that cause us to fire it off to Mr. Nil.
+    [m_delegateLock lock];
+    if ( m_delegate )
+    {
+        [m_delegate performSelector:@selector(ugClientResponse:) withObject:response];
+    }
+    [m_delegateLock unlock];
+    
+    // now that the callback is complete, it's safe to release this manager
+    [self releaseHTTPManager:manager];
+}
+
+-(void)httpManagerResponse:(UGHTTPManager *)manager response:(NSString *)response
+{
+    if ( m_bLogging )
+    {
+        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
+        NSLog(@"Response (Transaction ID %d):\n%@", [manager getTransactionID], response);
+        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
+    }
+    
+    // form up the response
+    UGClientResponse *ugResponse = [self createResponse:[manager getTransactionID] jsonStr:response];
+    
+    // if this is part of a multi-step call, we press on.
+    for ( int i=0 ; i<[m_pendingMultiStepActions count] ; i++ )
+    {
+        UGMultiStepAction *action = [m_pendingMultiStepActions objectAtIndex:i];
+        if ( [action transactionID] == [ugResponse transactionID] )
+        {
+            // multi-step call. Fire off the action.
+            ugResponse = [self doMultiStepAction:action mostRecentResponse:ugResponse];
+            if ( ![action reportToClient] )
+            {
+                // the action is still pending. We do not report this
+                // to the user. We're done with the httpmanager we were using,
+                // though. 
+                [self releaseHTTPManager:manager];
+                return;
+            }
+            
+            // when the action is complete, we want to immediately break
+            // from this loop, then fall through to the normal reporting
+            // to the user. 
+            break;
+        }
+    }
+        
+    // fire it off
+    [m_delegateLock lock];
+    if ( m_delegate )
+    {
+        [m_delegate performSelector:@selector(ugClientResponse:) withObject:ugResponse];
+    }
+    [m_delegateLock unlock];   
+    
+    // now that the callback is complete, it's safe to release this manager
+    [self releaseHTTPManager:manager];
+}
+
+// multi-step follow-up function
+-(UGClientResponse *)multiStepAction: (UGMultiStepAction *)action
+{
+    // different behavior if synch or asynch
+    if ( m_delegate )
+    {
+        // asynch. Fire it off and we're done
+        return [self doMultiStepAction:action mostRecentResponse:nil];
+    }
+    else 
+    {
+        // synchronous. keep calling until it finished or fails
+        UGClientResponse *response = nil;
+        do 
+        {
+            response = [self doMultiStepAction:action mostRecentResponse:response];
+            if ( [action reportToClient] )
+            {
+                // done
+                return response;
+            }
+        } while ([response transactionState] == kUGClientResponseSuccess);
+        
+        // if we're here, there was an error
+        return response;
+    }
+}
+
+-(UGClientResponse *)doMultiStepAction: (UGMultiStepAction *)action mostRecentResponse:(UGClientResponse *)mostRecentResponse
+{
+    // clear the pending array of this object
+    [m_pendingMultiStepActions removeObject:action];
+
+    // assume we aren't reporting to the client
+    [action setReportToClient:NO];
+    
+    if ( mostRecentResponse )
+    {
+        // we don't care about pending responses
+        if ( [mostRecentResponse transactionState] == kUGClientResponsePending )
+        {
+            // put ourselves back in the list
+            [m_pendingMultiStepActions addObject:action];
+            return mostRecentResponse;
+        }
+        
+        // any failure is an immediate game ender
+        if ( [mostRecentResponse transactionState] == kUGClientResponseFailure )
+        {
+            [mostRecentResponse setTransactionID:[action transactionID]];
+            return mostRecentResponse;
+        }
+    }
+    
+    // if mostRecentRespons is nil, that means it's the first call to initiate 
+    // the chain. So we continue on with processing.
+
+    // so either we are reacting to a success or we are starting off the chain
+    UGClientResponse *result = nil; 
+    if ( [action nextAction] == kMultiStepCreateActivity )
+    {
+        // create the activity
+        result = [self createActivity:[action activity]];
+        
+        // advance ourselves to the next step
+        [action setNextAction:kMultiStepPostActivity];
+    }
+    else if ( [action nextAction] == kMultiStepCreateGroupActivity )
+    {
+        // create the activity
+        result = [self createActivity:[action activity]];
+        
+        // advance ourselves to the next step
+        [action setNextAction:kMultiStepPostGroupActivity];
+    }
+    else if ( [action nextAction] == kMultiStepPostActivity )
+    {
+        // we just created an activity, now we need to associate it with a user.
+        // first, we'll need the activity's uuid
+        NSDictionary *dict = [mostRecentResponse response]; // dictionary for the response
+        NSArray *entities = [dict objectForKey:@"entities"]; // array for the entities
+        NSDictionary *activity = [entities objectAtIndex:0]; // dict for the activity
+        NSString *activityUUID = [activity valueForKey:@"uuid"]; // and finally the uuid string
+        
+        // fire off the next step
+        result = [self postUserActivityByUUID:[action userID] activity:activityUUID];
+        
+        // advance the action
+        [action setNextAction:kMultiStepCleanup];
+    }
+    else if ( [action nextAction] == kMultiStepPostGroupActivity )
+    {
+        // we just created an activity, now we need to associate it with a user.
+        // first, we'll need the activity's uuid
+        NSDictionary *dict = [mostRecentResponse response]; // dictionary for the response
+        NSArray *entities = [dict objectForKey:@"entities"]; // array for the entities
+        NSDictionary *activity = [entities objectAtIndex:0]; // dict for the activity
+        NSString *activityUUID = [activity valueForKey:@"uuid"]; // and finally the uuid string
+        
+        // fire off the next step
+        result = [self postGroupActivityByUUID:[action groupID] activity:activityUUID];
+        
+        // advance the action
+        [action setNextAction:kMultiStepCleanup];
+    }
+    else if ( [action nextAction] == kMultiStepCleanup )
+    {
+        // all we do in cleanup is update the transaction ID of the 
+        // response that was sent in. We do this to ensure that the transaction
+        // id is constant across the entire transaction
+        result = mostRecentResponse;
+        [result setTransactionID:[action outwardTransactionID]];
+        [action setReportToClient:YES];
+    }
+    
+    if ( !mostRecentResponse )
+    {
+        // if mostRecentResponse is nil, it means we're on the first step. That means
+        // we need to adopt a unique outward transaction ID. We'll simply use
+        // the ID given back by the first transaction in the chain. This also means
+        // we can simply return the first transaction pending response without modification. 
+        [action setOutwardTransactionID:[result transactionID]];
+    }
+
+    // wherever we landed, if it's a pending transaction, the action needs to
+    // know that transaction ID. Also, we need to go in to the pending array
+    if ( [result transactionState] == kUGClientResponsePending )
+    {
+        [action setTransactionID:[result transactionID]];
+        [m_pendingMultiStepActions addObject:action];
+    }
+    
+    // result is now properly set up and ready to be handed to the user. 
+    return result;
+}
+
+/*************************** LOGIN / LOGOUT ****************************/
+/*************************** LOGIN / LOGOUT ****************************/
+/*************************** LOGIN / LOGOUT ****************************/
+-(UGClientResponse *)logInUser: (NSString *)userName password:(NSString *)password
+{
+    return [self logIn:@"password" userKey:@"username" userValue:userName pwdKey:@"password" pwdValue:password];
+}
+
+-(UGClientResponse *)logInUserWithPin: (NSString *)userName pin:(NSString *)pin
+{
+    return [self logIn:@"pin" userKey:@"username" userValue:userName pwdKey:@"pin" pwdValue:pin];
+}
+
+-(UGClientResponse *)logInUserWithFacebook: (NSString *)facebookToken
+{
+    NSMutableString *url = [self createURL:@"auth/facebook"];
+    UGQuery *query = [[UGQuery alloc] init];
+    [query addURLTerm:@"fb_access_token" equals:facebookToken];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+-(UGClientResponse *)logInAdmin: (NSString *)adminUserName secret:(NSString *)adminSecret
+{
+    return [self logIn:@"client_credentials" userKey:@"client_id" userValue:adminUserName pwdKey:@"client_secret" pwdValue:adminSecret];
+}
+
+-(void)logOut
+{
+    // clear out auth
+    [self setAuth: nil];
+}
+
+// general workhorse for auth logins
+-(UGClientResponse *)logIn:(NSString *)grantType userKey:(NSString *)userKey userValue:(NSString *)userValue pwdKey:(NSString *)pwdKey pwdValue:(NSString *)pwdValue
+{
+    // create the URL
+    NSString *url = [self createURL:@"token"];
+    
+    // because it's read as form data, we need to escape special characters.
+    NSString *escapedUserValue = [UGHTTPManager escapeSpecials:userValue];
+    NSString *escapedPwdValue = [UGHTTPManager escapeSpecials:pwdValue];
+    
+    // create the post data. For auth functions, we don't use json,
+    // but instead use web form style data
+    NSMutableString *postData = [NSMutableString new];
+    [postData appendFormat:@"grant_type=%@&%@=%@&%@=%@", grantType, userKey, escapedUserValue, pwdKey, escapedPwdValue];
+    
+    // fire off the request
+    return [self httpTransaction:url op:kUGHTTPPostAuth opData:postData];    
+}
+/*************************** USER MANAGEMENT ***************************/
+/*************************** USER MANAGEMENT ***************************/
+/*************************** USER MANAGEMENT ***************************/
+-(UGClientResponse *)addUser:(NSString *)username email:(NSString *)email name:(NSString *)name password:(NSString *)password
+{
+    // make the URL we'll be posting to
+    NSString *url = [self createURL:@"users"];
+    
+    // make the post data we'll be sending along with it.
+    NSMutableDictionary *toPost = [NSMutableDictionary new];
+    [toPost setObject:username forKey:@"username"];
+    [toPost setObject:name forKey:@"name"];
+    [toPost setObject:email forKey:@"email"];
+    [toPost setObject:password forKey:@"password"];
+    NSString *toPostStr = [self createJSON:toPost];
+    
+    // fire it off
+    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
+}
+
+// updates a user's password
+-(UGClientResponse *)updateUserPassword:(NSString *)usernameOrEmail oldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword
+{
+    // make the URL we'll be posting to
+    NSString *url = [self createURL:@"users" append2:usernameOrEmail append3:@"password"];
+    
+    // make the post data we'll be sending along with it.
+    NSMutableDictionary *toPost = [NSMutableDictionary new];
+    [toPost setObject:oldPassword forKey:@"oldpassword"];
+    [toPost setObject:newPassword forKey:@"newpassword"];
+    NSString *toPostStr = [self createJSON:toPost];
+    
+    // fire it off
+    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
+}
+
+-(UGClientResponse *)getGroupsForUser: (NSString *)userID;
+{
+    // make the URL, and fire off the get
+    NSString *url = [self createURL:@"users" append2:userID append3:@"groups"];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+-(UGClientResponse *)getUsers: (UGQuery *)query
+{
+    // create the URL
+    NSMutableString *url = [self createURL:@"users"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+/************************** ACTIVITY MANAGEMENT **************************/
+/************************** ACTIVITY MANAGEMENT **************************/
+/************************** ACTIVITY MANAGEMENT **************************/
+-(UGClientResponse *)createActivity: (NSDictionary *)activity
+{
+    // make the URL
+    NSString *url = [self createURL:@"activity"];
+    
+    // get the json to send.
+    // we have to json-ify a dictionary that was sent
+    // in by the client. So naturally, we can't just trust it 
+    // to work. Therefore we can't use our internal convenience 
+    // function for making the json. We go straight to SBJson, so
+    // we can identify and report any errors.
+    SBJsonWriter *writer = [SBJsonWriter new];
+    NSError *jsonError;
+    NSString *toPostStr = [writer stringWithObject:activity error:&jsonError];
+
+    if ( !toPostStr )
+    {
+        // error during json assembly
+        UGClientResponse *ret = [UGClientResponse new];
+        [ret setTransactionState:kUGClientResponseFailure];
+        [ret setTransactionID:-1];
+        [ret setResponse:[jsonError localizedDescription]];
+        [ret setRawResponse:nil];
+        return ret;
+    }
+    
+    // fire it off
+    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
+}
+
+// create an activity and post it to a user in a single step
+-(UGClientResponse *)postUserActivity: (NSString *)userID activity:(NSDictionary *)activity
+{
+    // prep a multi-step action
+    UGMultiStepAction *action = [UGMultiStepAction new];
+    
+    // set it up to start the create activity / post to user chain
+    [action setNextAction:kMultiStepCreateActivity];
+    [action setUserID:userID];
+    [action setActivity:activity];
+    
+    // fire it off
+    return [self multiStepAction:action];
+}
+
+-(UGClientResponse *)postUserActivityByUUID: (NSString *)userID activity:(NSString *)activityUUID
+{
+    // make the URL and fire off the post. there is no data
+    NSString *url = [self createURL:@"users" append2:userID append3:@"activities" append4:activityUUID];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+-(UGClientResponse *)postGroupActivity:(NSString *)groupID activity:(NSDictionary *)activity
+{
+    // prep a multi-step action
+    UGMultiStepAction *action = [UGMultiStepAction new];
+    
+    // set it up to start the create activity / post to user chain
+    [action setNextAction:kMultiStepCreateGroupActivity];
+    [action setGroupID:groupID];
+    [action setActivity:activity];
+    
+    // fire it off
+    return [self multiStepAction:action];    
+}
+
+-(UGClientResponse *)postGroupActivityByUUID: (NSString *)groupID activity:(NSString *)activityUUID
+{
+    // make the URL and fire off the post. there is no data
+    NSString *url = [self createURL:@"groups" append2:groupID append3:@"activities" append4:activityUUID];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];    
+}
+
+-(UGClientResponse *)getActivitiesForUser: (NSString *)userID query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:@"users" append2:userID append3:@"activities"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
+}
+
+-(UGClientResponse *)getActivityFeedForUser: (NSString *)userID query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:@"users" append2:userID append3:@"feed"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
+}
+
+-(UGClientResponse *)getActivitiesForGroup: (NSString *)groupID query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"activities"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil]; 
+}
+
+-(UGClientResponse *)getActivityFeedForGroup: (NSString *)groupID query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"feed"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil]; 
+}
+
+-(UGClientResponse *)removeActivity:(NSString *)activityUUID
+{
+    NSString *url = [self createURL:@"activities" append2:activityUUID];
+    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
+}
+
+/************************** GROUP MANAGEMENT **************************/
+/************************** GROUP MANAGEMENT **************************/
+/************************** GROUP MANAGEMENT **************************/
+-(UGClientResponse *)createGroup:(NSString *)groupPath groupTitle:(NSString *)groupTitle
+{
+    // make the URL
+    NSString *url = [self createURL:@"groups"];
+    
+    // make the post data we'll be sending along with it.
+    NSMutableDictionary *toPost = [NSMutableDictionary new];
+    [toPost setObject:groupPath forKey:@"path"];
+    if ( groupTitle )
+    {
+        [toPost setObject:groupTitle forKey:@"title"];
+    }
+    NSString *toPostStr = [self createJSON:toPost];
+    
+    // fire it off
+    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
+}
+
+-(UGClientResponse *)addUserToGroup:(NSString *)userID group:(NSString *)groupID
+{
+    // make the URL
+    NSString *url = [self createURL:@"groups" append2:groupID append3:@"users" append4:userID];
+    
+    // fire it off. This is a data-less POST
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+-(UGClientResponse *)removeUserFromGroup:(NSString *)userID group:(NSString *)groupID
+{
+    // this is identical to addUserToGroup, except we use the DELETE method instead of POST
+    // make the URL
+    NSString *url = [self createURL:@"groups" append2:groupID append3:@"users" append4:userID];
+    
+    // fire it off. This is a data-less POST
+    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];}
+
+-(UGClientResponse *)getUsersForGroup:(NSString *)groupID query:(UGQuery *)query
+{
+    // create the URL
+    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"users"];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+/************************** ENTITY MANAGEMENT **************************/
+/************************** ENTITY MANAGEMENT **************************/
+/************************** ENTITY MANAGEMENT **************************/
+// jsonify the entity. If there's an error, it creates a UGClientResponse and 
+// returns it. If there's no error, it returns nil, and the outJson field and
+// the type field will be set correctly.
+// yes, it's odd to have a function return nil on success, but it's internal.
+-(UGClientResponse *)validateEntity:(NSDictionary *)newEntity outJson:(NSString **)jsonStr outType:(NSString **)type
+{
+    // validation
+    NSString *error = nil;
+    
+    // the entity must exist
+    if ( !newEntity )
+    {
+        error =@"entity is nil";
+    }
+    
+    // the entity must have a "type" field
+    *type = [newEntity valueForKey:@"type"];
+    if ( !*type )
+    {
+        error = @"entity is missing a type field";
+    }
+    
+    // make sure it can parse to a json
+    SBJsonWriter *writer = [SBJsonWriter new];
+    NSError *jsonError;
+    *jsonStr = [writer stringWithObject:newEntity error:&jsonError];
+    if ( !*jsonStr )
+    {
+        error = [jsonError localizedDescription];
+    }
+    
+    // if error got set to anything, it means we failed
+    if ( error )
+    {
+        UGClientResponse *ret = [UGClientResponse new];
+        [ret setTransactionState:kUGClientResponseFailure];
+        [ret setTransactionID:-1];
+        [ret setResponse:error];
+        [ret setRawResponse:nil]; 
+        return ret;
+    }
+    
+    // if we're here, it's a good json and we're done
+    return nil;
+}
+
+-(UGClientResponse *)createEntity:(NSDictionary *)newEntity
+{
+    NSString *jsonStr;
+    NSString *type;
+    UGClientResponse *errorRet = [self validateEntity:newEntity outJson:&jsonStr outType:&type];
+    if ( errorRet ) return errorRet;
+    
+    // we have a valid entity, ready to post. Make the URL
+    NSString *url = [self createURL:type];
+    
+    // post it
+    return [self httpTransaction:url op:kUGHTTPPost opData:jsonStr];
+}
+
+-(UGClientResponse *)getEntities: (NSString *)type query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:type];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
+}
+
+-(UGClientResponse *)updateEntity: (NSString *)entityID entity:(NSDictionary *)updatedEntity
+{
+    NSString *jsonStr;
+    NSString *type;
+    UGClientResponse *errorRet = [self validateEntity:updatedEntity outJson:&jsonStr outType:&type];
+    if ( errorRet ) return errorRet;
+    
+    // we have a valid entity, ready to post. Make the URL
+    NSString *url = [self createURL:type append2:entityID];
+    
+    // post it
+    return [self httpTransaction:url op:kUGHTTPPut opData:jsonStr];
+}
+
+-(UGClientResponse *)removeEntity: (NSString *)type entityID:(NSString *)entityID
+{
+    // Make the URL, then fire off the delete
+    NSString *url = [self createURL:type append2:entityID];
+    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
+}
+
+
+-(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType connecteeType:(NSString *)connecteeType connecteeID:(NSString *)connecteeID
+{
+    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeType append5:connecteeID];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+-(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID
+{
+    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeID];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+-(UGClientResponse *)disconnectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID
+{
+    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeID];
+    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
+}
+
+-(UGClientResponse *)getEntityConnections: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType query:(UGQuery *)query
+{
+    NSMutableString *url = [self createURL:connectorType append2:connectorID append3:connectionType];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+/************************** MESSAGE MANAGEMENT **************************/
+/************************** MESSAGE MANAGEMENT **************************/
+/************************** MESSAGE MANAGEMENT **************************/
+-(UGClientResponse *)postMessage: (NSString *)queuePath message:(NSDictionary *)message
+{
+    // because the NSDictionary is from the client, we can't trust it. We need 
+    // to go through full error checking
+    NSString *error;
+    NSString *jsonStr = [self createJSON:message error:&error];
+    
+    if ( !jsonStr )
+    {
+        // report the error
+        UGClientResponse *ret = [UGClientResponse new];
+        [ret setTransactionID:-1];
+        [ret setTransactionState:kUGClientResponseFailure];
+        [ret setResponse:error];
+        [ret setRawResponse:nil];
+        return ret;
+    }
+    
+    // make the path and fire it off
+    NSString *url = [self createURL:@"queues" append2:queuePath];
+    return [self httpTransaction:url op:kUGHTTPPost opData:jsonStr];
+}
+
+-(UGClientResponse *)getMessages: (NSString *)queuePath query:(UGQuery *)query;
+{
+    NSMutableString *url = [self createURL:@"queues" append2:queuePath];
+    [self appendQueryToURL:url query:query];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+-(UGClientResponse *)addSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath
+{
+    NSString *url = [self createURL:@"queues" append2:queuePath append3:@"subscribers" append4:subscriberPath];
+    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
+}
+
+-(UGClientResponse *)removeSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath
+{
+    NSString *url = [self createURL:@"queues" append2:queuePath append3:@"subscribers" append4:subscriberPath];
+    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
+}
+
+/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
+/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
+/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
+
+- (UGClientResponse *)setDevicePushToken:(NSData *)newDeviceToken forNotifier:(NSString *)notifier
+{
+    // Pull the push token string out of the device token data
+    NSString *tokenString = [[[newDeviceToken description]
+                              stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<>"]]
+                             stringByReplacingOccurrencesOfString:@" " withString:@""];
+    
+    // Register device and push token to App Services
+    NSString *deviceId = [UGClient getUniqueDeviceID];
+    
+    // create/update device - use deviceId for App Services entity UUID
+    NSMutableDictionary *entity = [[NSMutableDictionary alloc] init];
+    [entity setObject: @"device"   forKey: @"type"];
+    [entity setObject: deviceId    forKey: @"uuid"];
+    
+    NSString *notifierKey = [notifier stringByAppendingString: @".notifier.id"];
+    [entity setObject: tokenString forKey: notifierKey];
+    
+    return [self updateEntity: deviceId entity: entity];
+}
+
+- (UGClientResponse *)pushAlert:(NSString *)message
+                      withSound:(NSString *)sound
+                             to:(NSString *)path
+                  usingNotifier:(NSString *)notifier
+{
+    NSDictionary *apsDict = [NSDictionary dictionaryWithObjectsAndKeys:
+                             message, @"alert",
+                             sound, @"sound",
+                             nil];
+    
+    NSDictionary *notifierDict = [NSDictionary dictionaryWithObjectsAndKeys:
+                                  apsDict, @"aps",
+                                  nil];
+    
+    NSDictionary *payloadsDict = [NSDictionary dictionaryWithObjectsAndKeys:
+                                  notifierDict, notifier,
+                                  nil];
+    
+    NSString *notificationsPath = [path stringByAppendingString: @"/notifications"];
+    
+    NSMutableDictionary *entity = [[NSMutableDictionary alloc] init];
+    [entity setObject: notificationsPath forKey: @"type"];
+    [entity setObject: payloadsDict      forKey: @"payloads"];
+    
+    return [self createEntity: entity];
+}
+
+
+/*************************** SERVER-SIDE STORAGE ***************************/
+/*************************** SERVER-SIDE STORAGE ***************************/
+/*************************** SERVER-SIDE STORAGE ***************************/
++(NSString *)getUniqueDeviceID
+{
+    // cached?
+    if (g_deviceUUID) return g_deviceUUID;
+    
+    // in our keychain?
+    g_deviceUUID = [SSKeychain passwordForService:@"Usergrid" account:@"DeviceUUID"];
+    if (g_deviceUUID) return g_deviceUUID;
+
+    // in the (legacy) app defaults?
+    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
+    g_deviceUUID = [defaults valueForKey:@"UGClientDeviceUUID"];
+    
+    // if none found in storage, generate one
+    if (!g_deviceUUID) {
+    
+        if (SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"6.0")) {
+            // use identifierForVendor where possible
+            g_deviceUUID = [[[UIDevice currentDevice] identifierForVendor] UUIDString];
+        }
+        else {
+            // otherwise, create a UUID (legacy method)
+            CFUUIDRef uuidRef = CFUUIDCreate(nil);
+            CFStringRef uuidStringRef = CFUUIDCreateString(nil, uuidRef);
+            CFRelease(uuidRef);
+            g_deviceUUID = [NSString stringWithString:(__bridge NSString *)uuidStringRef];
+        }
+    }
+    
+    // store in keychain for future reference
+    [SSKeychain setPassword:g_deviceUUID forService:@"Usergrid" account:@"DeviceUUID"];
+    
+    return g_deviceUUID;
+}
+
+-(UGClientResponse *)setRemoteStorage: (NSDictionary *)data
+{
+    // prep and validate the sent-in dict
+    NSString *error;
+    NSString *jsonStr = [self createJSON:data error:&error];
+    if ( !jsonStr )
+    {
+        // report the error
+        UGClientResponse *ret = [UGClientResponse new];
+        [ret setTransactionID:-1];
+        [ret setTransactionState:kUGClientResponseFailure];
+        [ret setResponse:error];
+        [ret setRawResponse:nil];
+        return ret;
+    }
+    
+    NSString *handsetUUID = [UGClient getUniqueDeviceID];
+    NSString *url = [self createURL:@"devices" append2:handsetUUID];
+    
+    // this is a put. We replace whatever was there before
+    return [self httpTransaction:url op:kUGHTTPPut opData:jsonStr];
+}
+
+-(UGClientResponse *)getRemoteStorage
+{
+    NSString *handsetUUID = [UGClient getUniqueDeviceID];
+    NSString *url = [self createURL:@"devices" append2:handsetUUID];
+    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
+}
+
+/***************************** OBLIQUE USAGE ******************************/
+-(UGClientResponse *)apiRequest: (NSString *)url operation:(NSString *)op data:(NSString *)opData
+{
+    // work out the op to use
+    int opID = kUGHTTPGet;
+    if ( [op isEqualToString:@"GET"] ) opID = kUGHTTPGet;
+    if ( [op isEqualToString:@"POST"] ) opID = kUGHTTPPost;
+    if ( [op isEqualToString:@"POSTFORM"] ) opID = kUGHTTPPostAuth;
+    if ( [op isEqualToString:@"PUT"] ) opID = kUGHTTPPut;
+    if ( [op isEqualToString:@"DELETE"] ) opID = kUGHTTPDelete;
+    
+    // fire it off. The data, formatting, etc. is all the client's problem. 
+    // That's the way oblique functionality is. 
+    return [self httpTransaction:url op:opID opData:opData];
+}
+
+/**************************** LOGGING ************************************/
+-(void)setLogging: (BOOL)loggingState
+{
+    m_bLogging = loggingState;
+}
+
+@end
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGClientDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGClientDelegate.h b/sdks/other/ios/UGAPI/UGClientDelegate.h
new file mode 100644
index 0000000..28bc996
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGClientDelegate.h
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+#import "UGClientResponse.h"
+
+/******************************A NOTE ON THIS DELEGATE********************************
+Objects conform to this protocol to take advantage of the Asynchronus SDK functionality.
+The setDelegate method needs to be called on the current UGClient for this function to
+be called on an implemented delegate.
+ 
+If you do not set a delegate, all functions will run synchronously, blocking
+until a response has been received or an error detected.
+*************************************************************************************/
+@protocol UGClientDelegate <NSObject>
+
+//This method is called after every request to the UserGrid API.
+//It passes in the response to the API request, and returns nothing.
+-(void)ugClientResponse:(UGClientResponse *)response;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGClientResponse.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGClientResponse.h b/sdks/other/ios/UGAPI/UGClientResponse.h
new file mode 100755
index 0000000..01bc5a1
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGClientResponse.h
@@ -0,0 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+
+
+// response states
+enum
+{
+    kUGClientResponseSuccess = 0,
+    kUGClientResponseFailure = 1,
+    kUGClientResponsePending = 2
+};
+
+
+@interface UGClientResponse : NSObject
+
+// this will be a unique ID for this transaction. If you have
+// multiple transactions in progress, you can keep track of them
+// with this value. Note: The transaction ID of a synchronous
+// call response is always -1.
+@property int transactionID;
+
+// this will be one of three possible valuse:
+// kUGClientResponseSuccess: The operation is complete and was successful. response will 
+//                          be valid, as will rawResponse
+//
+// kUGClientResponseFailure: There was an error with the operation. No further 
+//                          processing will be done. response will be an NSString with
+//                          a plain-text description of what went wrong. rawResponse
+//                          will be valid if the error occurred after receiving data from
+//                          the service. If it occurred before, rawResponse will be nil.
+//
+// kUGClientResponsePending: The call is being handled asynchronously and not yet complete. 
+//                          response will be nil. rawResponse will also be nil
+@property int transactionState;
+
+// This is the response. The type of this variable is dependant on the call that caused
+// this response. 
+@property id response;
+
+// This is the raw text that was returned by the server. 
+@property NSString *rawResponse;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGClientResponse.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGClientResponse.m b/sdks/other/ios/UGAPI/UGClientResponse.m
new file mode 100755
index 0000000..dc49fb4
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGClientResponse.m
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGClientResponse.h"
+
+@implementation UGClientResponse
+
+@synthesize transactionID;
+@synthesize transactionState;
+@synthesize response;
+@synthesize rawResponse;
+
+-(id)init
+{
+    self = [super init];
+    if ( self )
+    {
+        transactionID = -1;
+        transactionState = -1;
+        response = nil;
+        rawResponse = nil;
+    }
+    return self;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGHTTPManager.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGHTTPManager.h b/sdks/other/ios/UGAPI/UGHTTPManager.h
new file mode 100755
index 0000000..d6c1822
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGHTTPManager.h
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+
+enum
+{
+    kUGHTTPGet = 0,
+    kUGHTTPPost = 1,
+    kUGHTTPPostAuth = 2,
+    kUGHTTPPut = 3,
+    kUGHTTPDelete = 4
+};
+
+@interface UGHTTPManager : NSObject
+
+// blocks until a response is received, or until there's an error.
+// in the event of a response, it's returned. If there's an error, 
+// the funciton returns nil and you can call getLastError to see what
+// went wrong.
+-(NSString *)syncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData;
+
+// sets up the transaction asynchronously. The delegate that's sent in
+// must have the following functions: 
+//
+// -(void)httpManagerError:(UGHTTPManager *)manager error:(NSString *)error
+// -(void)httpManagerResponse:(UGHTTPManager *)manager response:(NSString *)response
+//
+// In all cases, it returns a transaction ID. A return value
+// of -1 means there was an error.
+// You can call getLastError to find out what went wrong. 
+-(int)asyncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData delegate:(id)delegate;
+
+// get the current transactionID
+-(int)getTransactionID;
+
+// sets the auth key
+-(void)setAuth: (NSString *)auth;
+
+// cancel a pending transaction. The delegate will not be called and the results
+// will be ignored. Though the server side will still have happened.
+-(void)cancel;
+
+// returns YES if this instance is available. NO if this instance is currently
+// in use as part of an asynchronous transaction.
+-(BOOL)isAvailable;
+
+// sets the availability flag of this instance. This is done by UGClient
+-(void)setAvailable:(BOOL)available;
+
+// a helpful utility function to make a string comform to URL
+// rules. It will escape all the special characters.
++(NSString *)escapeSpecials:(NSString *)raw;
+
+// At all times, this will return the plain-text explanation of the last
+// thing that went wrong. It is cleared to "No Error" at the beginnign of 
+// each new transaction.
+-(NSString *)getLastError;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGHTTPManager.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGHTTPManager.m b/sdks/other/ios/UGAPI/UGHTTPManager.m
new file mode 100755
index 0000000..5d62fe9
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGHTTPManager.m
@@ -0,0 +1,328 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGHTTPManager.h"
+
+// all transaction IDs are unique across all UGHTTPManagers. 
+// this global increases every time there's an asynchronous 
+// transaction. 
+static int g_nextTransactionID = 1;  
+
+// a mutex to protect against multiple threads getting
+// IDs at the same time, and possibly getting the same ID
+// because of it
+NSRecursiveLock *g_transactionIDLock = nil;
+
+@implementation UGHTTPManager
+{
+    // data management for collecting incoming HTTP data
+    // during asynch transactions
+    NSMutableData *m_receivedData;
+    
+    // a general error string
+    NSString *m_lastError;
+    
+    // the delegate sent in to the asynch method
+    id m_delegate;
+    
+    // the transaction ID of the current (or most recent) transaction
+    int m_transactionID;
+    
+    // availability of this instance. Managed by UGClient
+    BOOL m_bAvailable;
+    
+    // mutex used to ensure the delegate is not changed
+    // in a way that would cause a race condition.
+    NSRecursiveLock *m_delegateLock;        
+    
+    // the auth key to send along to requests
+    NSString *m_auth;
+}
+
+-(id)init
+{
+    self = [super init];
+    if ( self )
+    {
+        m_lastError = @"No error";
+        m_receivedData = [NSMutableData data];
+        m_bAvailable = YES;
+        m_delegateLock = [NSRecursiveLock new];
+        m_transactionID = -1;
+        m_auth = nil;
+        
+        // lazy-init the transaction lock
+        if ( !g_transactionIDLock )
+        {
+            g_transactionIDLock = [NSRecursiveLock new];
+        }
+    }
+    return self;
+}
+
+-(void)setAuth: (NSString *)auth
+{
+    m_auth = auth;
+}
+
+-(NSString *)getLastError
+{
+    return m_lastError;
+}
+
+-(int)getNextTransactionID
+{
+    // make sure we can use this lock
+    assert(g_transactionIDLock);
+    
+    [g_transactionIDLock lock];
+    int ret = g_nextTransactionID++;
+    [g_transactionIDLock unlock];
+    
+    return ret;
+}
+
+-(int)getTransactionID
+{
+    return m_transactionID;
+}
+
+
+//----------------------- SYNCHRONOUS CALLING ------------------------
+-(NSString *)syncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData;
+{
+    // clear the transaction ID
+    m_transactionID = -1;
+    
+    // use the synchronous funcitonality of NSURLConnection
+    // clear the error
+    m_lastError = @"No error";
+    
+    // formulate the request
+    NSURLRequest *req = [self getRequest:url operation:op operationData:opData];
+    
+    NSURLResponse *response;
+    NSError *error;
+    NSData *resultData = [NSURLConnection sendSynchronousRequest:req returningResponse:&response error:&error];
+    
+    if ( resultData )
+    {
+        // we got results
+        NSString *resultString = [[NSString alloc] initWithData:resultData encoding:NSUTF8StringEncoding];        
+        return resultString;
+    }
+    
+    // if we're here, it means we got nil as the result
+    m_lastError = [error localizedDescription];
+    return nil;
+}
+
+//----------------------- ASYNCHRONOUS CALLING ------------------------
+-(int)asyncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData delegate:(id)delegate;
+{
+    // clear the transaction ID
+    m_transactionID = -1;
+    
+    // clear the error
+    m_lastError = @"No error";
+    
+    if ( !delegate )
+    {
+        // an asynch transaction with no delegate has no meaning
+        m_lastError = @"Delegate was nil";
+        return -1;
+    }
+    
+    // make sure the delegate responds to the various messages that
+    // are required
+    if ( ![delegate respondsToSelector:@selector(httpManagerError:error:)] )
+    {
+        m_lastError = @"Delegate does not have httpManagerError:error: method";
+        return -1;
+    }
+    if ( ![delegate respondsToSelector:@selector(httpManagerResponse:response:)] )
+    {
+        m_lastError = @"Delegate does not have httpManagerResponse:response: method";
+        return -1;
+    }
+    
+    // only once we're assured everything is right do we set the internal value
+    [m_delegateLock lock];
+    m_delegate = delegate;
+    [m_delegateLock unlock];
+    
+    // prep a transaction ID for this transaction
+    m_transactionID = [self getNextTransactionID];
+   
+    // formulate the request
+    NSURLRequest *req = [self getRequest:url operation:op operationData:opData];
+        
+    // fire it off
+    NSURLConnection *conn = [[NSURLConnection alloc] initWithRequest:req delegate:self];
+    
+    // Note failure
+    if ( !conn )
+    {
+        // failed to connect
+        m_lastError = @"Unable to initiate connection.";
+        return -1;       
+    }
+    
+    // success
+    return m_transactionID;
+}
+
+-(BOOL)isAvailable
+{
+    return m_bAvailable;
+}
+
+-(void)setAvailable:(BOOL)available
+{
+    m_bAvailable = available;
+}
+
+-(void)cancel
+{
+    // we wrap this in a lock to ensure that the client can
+    // call it at any time. It will not cause a race condition in 
+    // any callback thread.
+    [m_delegateLock lock];
+    m_delegate = nil;
+    [m_delegateLock unlock];
+    
+    // note that we do not modify the "in use" flag. If we werei n use,
+    // we remain in use until we receive a response or error. This ensures 
+    // no confusion on any subsequent transaction. We don't want the case 
+    // where a transaction is started, then cancelled, then a new transaction begun
+    // before the first transaction's result comes in. That would lead to the second 
+    // transaction being answered with the first's reply. We avoid that possibility by
+    // simply remaining "in use" until we get the reply or error.
+}
+
+// general helper function form aking escaped-strings
++(NSString *)escapeSpecials:(NSString *)raw;
+{
+    NSString *converted = (__bridge NSString *)CFURLCreateStringByAddingPercentEscapes(kCFAllocatorDefault, (__bridge CFStringRef)raw, nil, CFSTR(";/?:@&=$+{}<>"), kCFStringEncodingUTF8);
+    return converted;
+}
+
+// INTERNAL function for forming the request
+-(NSURLRequest *)getRequest:(NSString *)url operation:(int)op operationData:(NSString *)opStr;
+{
+    // make the url
+    NSURL *nsurl = [NSURL URLWithString:url];
+        
+    NSMutableURLRequest *req = [NSMutableURLRequest new];
+    [req setURL:nsurl];
+    
+    switch ( op ) 
+    {
+        case kUGHTTPGet: [req setHTTPMethod:@"GET"]; break;
+        case kUGHTTPPost: [req setHTTPMethod:@"POST"]; break;
+        case kUGHTTPPostAuth: [req setHTTPMethod:@"POST"]; break;
+        case kUGHTTPPut: [req setHTTPMethod:@"PUT"]; break;
+        case kUGHTTPDelete: [req setHTTPMethod:@"DELETE"]; break;
+    }
+
+    // set the auth, if any is available
+    if ( m_auth )
+    {
+        NSMutableString *authStr = [NSMutableString new];
+        [authStr appendFormat:@"Bearer %@", m_auth];
+        [req setValue:authStr forHTTPHeaderField:@"Authorization"];
+    }
+
+    // if they sent an opStr, we make that the content
+    if ( opStr )
+    {
+        // prep the post data
+        NSData *opData = [opStr dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES];
+        
+        // make a string that tells the length of the post data. We'll need that for the HTTP header setup
+        NSString *opLength = [NSString stringWithFormat:@"%d", [opData length]];
+        
+        [req setValue:opLength forHTTPHeaderField:@"Content-Length"];
+        
+        // PostAuth uses form encoding. All other operations use json
+        if ( op == kUGHTTPPostAuth )
+        {
+            [req setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
+        }
+        else
+        {
+            [req setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];
+        }
+        
+        [req setHTTPBody:opData];
+    }
+    
+    // all set up and ready for use
+    return req;
+    
+}
+
+//------------------------------------------------------------------------------------------
+//-------------------------- NSURLCONNECTION DELEGATE METHODS ------------------------------
+//------------------------------------------------------------------------------------------
+-(void)connection:(NSURLConnection *)connection didReceiveResponse:(NSURLResponse *)response
+{
+    // got a response. clear out the data
+    [m_receivedData setLength:0];
+}
+
+-(void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data
+{
+    // got some data. Append it.
+    [m_receivedData appendData:data];
+}
+
+-(void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
+{
+     // connection failed. Note the error
+    m_lastError = [error localizedDescription];
+    
+    // send the error to the delegate. We wrap this in 
+    // send the result to the delegate.
+    // wrap this in mutex locks, then check for validity of m_delegate inside.
+    // this ensures no race conditions and allows arbitrary cancellation of callbacks
+    [m_delegateLock lock];
+    if ( m_delegate )
+    {
+        [m_delegate performSelector:@selector(httpManagerError:error:) withObject:self withObject:m_lastError];
+    }
+    m_delegate = nil;
+    [m_delegateLock unlock];
+}
+
+-(void)connectionDidFinishLoading:(NSURLConnection*)connection
+{
+    // all done. Let's turn it in to a string
+    NSString *resultString = [[NSString alloc] initWithData:m_receivedData encoding:NSUTF8StringEncoding];
+    
+    // send it to the delegate. See connection:didFailWithError: for an explanation
+    // of the mutex locks
+    [m_delegateLock lock];
+    if ( m_delegate )
+    {
+        [m_delegate performSelector:@selector(httpManagerResponse:response:) withObject:self withObject:resultString];   
+    }
+    m_delegate = nil;
+    [m_delegateLock unlock];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGMultiStepAction.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGMultiStepAction.h b/sdks/other/ios/UGAPI/UGMultiStepAction.h
new file mode 100755
index 0000000..fbc1259
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGMultiStepAction.h
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+
+// an enumeration for multi-step processes. 
+enum
+{
+    kMultiStepNone = 0,
+    kMultiStepCreateActivity = 1, // create an activity
+    kMultiStepPostActivity = 2,   // after creating an activity, post it to the user
+    kMultiStepCreateGroupActivity = 3, // create an activity
+    kMultiStepPostGroupActivity = 4,   // after creating an activity, post it to the user
+    kMultiStepCleanup = 5         // the final step of all multi-step transactions
+};
+
+// UGMultiStepAction is used internally for client actions that
+// require multiple transactions with the service. It is simple data
+// storage, used by UGClient in abstracting out multi-step transactions
+@interface UGMultiStepAction : NSObject
+
+// the transaction ID that this multistep is associated
+// with. When a transaction of this ID is complete, this is the
+// UGMultiStepAction instance ot ask what to do next
+@property int transactionID;
+
+// the next action this transaction should take
+@property int nextAction;
+
+// data necessary for subsequent steps
+@property NSString *userID; 
+@property NSString *groupID; 
+@property NSDictionary *activity; 
+
+// the transactionID that will be sent to the user.
+// This is distinct from normal transaction IDs,
+// which we use internally at each step. 
+@property int outwardTransactionID;
+
+// YES if this action should be reported to the
+// caller .No if not.
+@property BOOL reportToClient;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGMultiStepAction.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGMultiStepAction.m b/sdks/other/ios/UGAPI/UGMultiStepAction.m
new file mode 100755
index 0000000..6a1b7c7
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGMultiStepAction.m
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGMultiStepAction.h"
+
+@implementation UGMultiStepAction
+
+@synthesize transactionID;
+@synthesize nextAction;
+@synthesize userID;
+@synthesize groupID;
+@synthesize activity;
+@synthesize outwardTransactionID;
+@synthesize reportToClient;
+
+
+-(id)init
+{
+    self = [super init];
+    if ( self )
+    {
+        reportToClient = NO;
+    }
+    return self;
+}
+@end


[10/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/composer.lock
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/composer.lock b/sdks/php5/apache-usergrid/composer.lock
deleted file mode 100644
index 3060421..0000000
--- a/sdks/php5/apache-usergrid/composer.lock
+++ /dev/null
@@ -1,1225 +0,0 @@
-{
-    "_readme": [
-        "This file locks the dependencies of your project to a known state",
-        "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
-        "This file is @generated automatically"
-    ],
-    "hash": "f77c404fc8b03f21424d391e5451af8a",
-    "packages": [
-        {
-            "name": "guzzle/guzzle",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/guzzle/guzzle3.git",
-                "reference": "5e6fb7097efac7180bd75006079144025255eb63"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/guzzle/guzzle3/zipball/5e6fb7097efac7180bd75006079144025255eb63",
-                "reference": "5e6fb7097efac7180bd75006079144025255eb63",
-                "shasum": ""
-            },
-            "require": {
-                "ext-curl": "*",
-                "php": ">=5.3.3",
-                "symfony/event-dispatcher": "~2.1"
-            },
-            "replace": {
-                "guzzle/batch": "self.version",
-                "guzzle/cache": "self.version",
-                "guzzle/common": "self.version",
-                "guzzle/http": "self.version",
-                "guzzle/inflection": "self.version",
-                "guzzle/iterator": "self.version",
-                "guzzle/log": "self.version",
-                "guzzle/parser": "self.version",
-                "guzzle/plugin": "self.version",
-                "guzzle/plugin-async": "self.version",
-                "guzzle/plugin-backoff": "self.version",
-                "guzzle/plugin-cache": "self.version",
-                "guzzle/plugin-cookie": "self.version",
-                "guzzle/plugin-curlauth": "self.version",
-                "guzzle/plugin-error-response": "self.version",
-                "guzzle/plugin-history": "self.version",
-                "guzzle/plugin-log": "self.version",
-                "guzzle/plugin-md5": "self.version",
-                "guzzle/plugin-mock": "self.version",
-                "guzzle/plugin-oauth": "self.version",
-                "guzzle/service": "self.version",
-                "guzzle/stream": "self.version"
-            },
-            "require-dev": {
-                "doctrine/cache": "~1.3",
-                "monolog/monolog": "~1.0",
-                "phpunit/phpunit": "3.7.*",
-                "psr/log": "~1.0",
-                "symfony/class-loader": "~2.1",
-                "zendframework/zend-cache": "2.*,<2.3",
-                "zendframework/zend-log": "2.*,<2.3"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "3.9-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Guzzle": "src/",
-                    "Guzzle\\Tests": "tests/"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Michael Dowling",
-                    "email": "mtdowling@gmail.com",
-                    "homepage": "https://github.com/mtdowling"
-                },
-                {
-                    "name": "Guzzle Community",
-                    "homepage": "https://github.com/guzzle/guzzle/contributors"
-                }
-            ],
-            "description": "Guzzle is a PHP HTTP client library and framework for building RESTful web service clients",
-            "homepage": "http://guzzlephp.org/",
-            "keywords": [
-                "client",
-                "curl",
-                "framework",
-                "http",
-                "http client",
-                "rest",
-                "web service"
-            ],
-            "time": "2014-10-29 23:08:23"
-        },
-        {
-            "name": "illuminate/support",
-            "version": "4.2.x-dev",
-            "target-dir": "Illuminate/Support",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/illuminate/support.git",
-                "reference": "4831699d6bcddd766e3cebbd8279976854d37027"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/illuminate/support/zipball/4831699d6bcddd766e3cebbd8279976854d37027",
-                "reference": "4831699d6bcddd766e3cebbd8279976854d37027",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.4.0"
-            },
-            "require-dev": {
-                "jeremeamia/superclosure": "~1.0.1",
-                "patchwork/utf8": "1.1.*"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "4.2-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Illuminate\\Support": ""
-                },
-                "files": [
-                    "Illuminate/Support/helpers.php"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Taylor Otwell",
-                    "email": "taylorotwell@gmail.com"
-                }
-            ],
-            "time": "2014-09-27 01:17:10"
-        },
-        {
-            "name": "nesbot/carbon",
-            "version": "1.13.0",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/briannesbitt/Carbon.git",
-                "reference": "5cb6e71055f7b0b57956b73d324cc4de31278f42"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/5cb6e71055f7b0b57956b73d324cc4de31278f42",
-                "reference": "5cb6e71055f7b0b57956b73d324cc4de31278f42",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.0"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.0"
-            },
-            "type": "library",
-            "autoload": {
-                "psr-0": {
-                    "Carbon": "src"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Brian Nesbitt",
-                    "email": "brian@nesbot.com",
-                    "homepage": "http://nesbot.com"
-                }
-            ],
-            "description": "A simple API extension for DateTime.",
-            "homepage": "https://github.com/briannesbitt/Carbon",
-            "keywords": [
-                "date",
-                "datetime",
-                "time"
-            ],
-            "time": "2014-09-26 02:52:02"
-        },
-        {
-            "name": "symfony/event-dispatcher",
-            "version": "2.7.x-dev",
-            "target-dir": "Symfony/Component/EventDispatcher",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/symfony/EventDispatcher.git",
-                "reference": "8e5829263631e686bf4d1254b02411263b8fa228"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/8e5829263631e686bf4d1254b02411263b8fa228",
-                "reference": "8e5829263631e686bf4d1254b02411263b8fa228",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "psr/log": "~1.0",
-                "symfony/config": "~2.0",
-                "symfony/dependency-injection": "~2.6",
-                "symfony/expression-language": "~2.6",
-                "symfony/stopwatch": "~2.2"
-            },
-            "suggest": {
-                "symfony/dependency-injection": "",
-                "symfony/http-kernel": ""
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "2.7-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Symfony\\Component\\EventDispatcher\\": ""
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Symfony Community",
-                    "homepage": "http://symfony.com/contributors"
-                },
-                {
-                    "name": "Fabien Potencier",
-                    "email": "fabien@symfony.com"
-                }
-            ],
-            "description": "Symfony EventDispatcher Component",
-            "homepage": "http://symfony.com",
-            "time": "2014-11-10 18:00:54"
-        }
-    ],
-    "packages-dev": [
-        {
-            "name": "doctrine/instantiator",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/doctrine/instantiator.git",
-                "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f976e5de371104877ebc89bd8fecb0019ed9c119",
-                "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3,<8.0-DEV"
-            },
-            "require-dev": {
-                "athletic/athletic": "~0.1.8",
-                "ext-pdo": "*",
-                "ext-phar": "*",
-                "phpunit/phpunit": "~4.0",
-                "squizlabs/php_codesniffer": "2.0.*@ALPHA"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.0.x-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Doctrine\\Instantiator\\": "src"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Marco Pivetta",
-                    "email": "ocramius@gmail.com",
-                    "homepage": "http://ocramius.github.com/"
-                }
-            ],
-            "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors",
-            "homepage": "https://github.com/doctrine/instantiator",
-            "keywords": [
-                "constructor",
-                "instantiate"
-            ],
-            "time": "2014-10-13 12:58:55"
-        },
-        {
-            "name": "mockery/mockery",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/padraic/mockery.git",
-                "reference": "30eb319efcf2ebe6b4529be51f60df78340bdbb5"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/padraic/mockery/zipball/30eb319efcf2ebe6b4529be51f60df78340bdbb5",
-                "reference": "30eb319efcf2ebe6b4529be51f60df78340bdbb5",
-                "shasum": ""
-            },
-            "require": {
-                "lib-pcre": ">=7.0",
-                "php": ">=5.3.2"
-            },
-            "require-dev": {
-                "hamcrest/hamcrest-php": "~1.1",
-                "phpunit/phpunit": "~4.0",
-                "satooshi/php-coveralls": "~0.7@dev"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "0.9.x-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Mockery": "library/"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "P�draic Brady",
-                    "email": "padraic.brady@gmail.com",
-                    "homepage": "http://blog.astrumfutura.com"
-                },
-                {
-                    "name": "Dave Marshall",
-                    "email": "dave.marshall@atstsolutions.co.uk",
-                    "homepage": "http://davedevelopment.co.uk"
-                }
-            ],
-            "description": "Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succint API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL). Designed as a drop in alternative to PHPUnit's phpunit-mock-objects library, Mockery is easy to integrate with PHPUnit and can operate alongside phpunit-mock-objects without the World ending.",
-            "homepage": "http://github.com/padraic/mockery",
-            "keywords": [
-                "BDD",
-                "TDD",
-                "library",
-                "mock",
-                "mock objects",
-                "mockery",
-                "stub",
-                "test",
-                "test double",
-                "testing"
-            ],
-            "time": "2014-11-10 08:31:38"
-        },
-        {
-            "name": "phpdocumentor/reflection-docblock",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git",
-                "reference": "fd0ac2007401505fb596fdfb859ec4e103d69e55"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/fd0ac2007401505fb596fdfb859ec4e103d69e55",
-                "reference": "fd0ac2007401505fb596fdfb859ec4e103d69e55",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.0"
-            },
-            "suggest": {
-                "dflydev/markdown": "~1.0",
-                "erusev/parsedown": "~1.0"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "2.0.x-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "phpDocumentor": [
-                        "src/"
-                    ]
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Mike van Riel",
-                    "email": "mike.vanriel@naenius.com"
-                }
-            ],
-            "time": "2014-09-02 14:26:20"
-        },
-        {
-            "name": "phpspec/prophecy",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/phpspec/prophecy.git",
-                "reference": "2bbc78d0b4b1ce8049479395ba950d4b13f21d94"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/phpspec/prophecy/zipball/2bbc78d0b4b1ce8049479395ba950d4b13f21d94",
-                "reference": "2bbc78d0b4b1ce8049479395ba950d4b13f21d94",
-                "shasum": ""
-            },
-            "require": {
-                "doctrine/instantiator": "~1.0,>=1.0.2",
-                "phpdocumentor/reflection-docblock": "~2.0"
-            },
-            "require-dev": {
-                "phpspec/phpspec": "~2.0"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.2.x-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Prophecy\\": "src/"
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Konstantin Kudryashov",
-                    "email": "ever.zet@gmail.com",
-                    "homepage": "http://everzet.com"
-                },
-                {
-                    "name": "Marcello Duarte",
-                    "email": "marcello.duarte@gmail.com"
-                }
-            ],
-            "description": "Highly opinionated mocking framework for PHP 5.3+",
-            "homepage": "http://phpspec.org",
-            "keywords": [
-                "Double",
-                "Dummy",
-                "fake",
-                "mock",
-                "spy",
-                "stub"
-            ],
-            "time": "2014-10-05 19:43:51"
-        },
-        {
-            "name": "phpunit/php-code-coverage",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/php-code-coverage.git",
-                "reference": "21b9006b7ceb7e1cb0b705615af31f67c8cd1692"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/21b9006b7ceb7e1cb0b705615af31f67c8cd1692",
-                "reference": "21b9006b7ceb7e1cb0b705615af31f67c8cd1692",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3",
-                "phpunit/php-file-iterator": "~1.3",
-                "phpunit/php-text-template": "~1.2",
-                "phpunit/php-token-stream": "~1.3",
-                "sebastian/environment": "~1.0",
-                "sebastian/version": "~1.0"
-            },
-            "require-dev": {
-                "ext-xdebug": ">=2.1.4",
-                "phpunit/phpunit": "dev-master"
-            },
-            "suggest": {
-                "ext-dom": "*",
-                "ext-xdebug": ">=2.2.1",
-                "ext-xmlwriter": "*"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "3.0.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sb@sebastian-bergmann.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.",
-            "homepage": "https://github.com/sebastianbergmann/php-code-coverage",
-            "keywords": [
-                "coverage",
-                "testing",
-                "xunit"
-            ],
-            "time": "2014-11-11 14:18:30"
-        },
-        {
-            "name": "phpunit/php-file-iterator",
-            "version": "1.3.4",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/php-file-iterator.git",
-                "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/acd690379117b042d1c8af1fafd61bde001bf6bb",
-                "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "type": "library",
-            "autoload": {
-                "classmap": [
-                    "File/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "include-path": [
-                ""
-            ],
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sb@sebastian-bergmann.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "FilterIterator implementation that filters files based on a list of suffixes.",
-            "homepage": "https://github.com/sebastianbergmann/php-file-iterator/",
-            "keywords": [
-                "filesystem",
-                "iterator"
-            ],
-            "time": "2013-10-10 15:34:57"
-        },
-        {
-            "name": "phpunit/php-text-template",
-            "version": "1.2.0",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/php-text-template.git",
-                "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/206dfefc0ffe9cebf65c413e3d0e809c82fbf00a",
-                "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "type": "library",
-            "autoload": {
-                "classmap": [
-                    "Text/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "include-path": [
-                ""
-            ],
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sb@sebastian-bergmann.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "Simple template engine.",
-            "homepage": "https://github.com/sebastianbergmann/php-text-template/",
-            "keywords": [
-                "template"
-            ],
-            "time": "2014-01-30 17:20:04"
-        },
-        {
-            "name": "phpunit/php-timer",
-            "version": "1.0.5",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/php-timer.git",
-                "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/19689d4354b295ee3d8c54b4f42c3efb69cbc17c",
-                "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "type": "library",
-            "autoload": {
-                "classmap": [
-                    "PHP/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "include-path": [
-                ""
-            ],
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sb@sebastian-bergmann.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "Utility class for timing",
-            "homepage": "https://github.com/sebastianbergmann/php-timer/",
-            "keywords": [
-                "timer"
-            ],
-            "time": "2013-08-02 07:42:54"
-        },
-        {
-            "name": "phpunit/php-token-stream",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/php-token-stream.git",
-                "reference": "f8d5d08c56de5cfd592b3340424a81733259a876"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/f8d5d08c56de5cfd592b3340424a81733259a876",
-                "reference": "f8d5d08c56de5cfd592b3340424a81733259a876",
-                "shasum": ""
-            },
-            "require": {
-                "ext-tokenizer": "*",
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.2"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.3-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                }
-            ],
-            "description": "Wrapper around PHP's tokenizer extension.",
-            "homepage": "https://github.com/sebastianbergmann/php-token-stream/",
-            "keywords": [
-                "tokenizer"
-            ],
-            "time": "2014-08-31 06:12:13"
-        },
-        {
-            "name": "phpunit/phpunit",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/phpunit.git",
-                "reference": "247756f342dfb0a319f8985ef06f21a00d98b59c"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/247756f342dfb0a319f8985ef06f21a00d98b59c",
-                "reference": "247756f342dfb0a319f8985ef06f21a00d98b59c",
-                "shasum": ""
-            },
-            "require": {
-                "ext-dom": "*",
-                "ext-json": "*",
-                "ext-pcre": "*",
-                "ext-reflection": "*",
-                "ext-spl": "*",
-                "php": ">=5.3.3",
-                "phpspec/prophecy": "~1.2",
-                "phpunit/php-code-coverage": "3.0.*@dev",
-                "phpunit/php-file-iterator": "~1.3.2",
-                "phpunit/php-text-template": "~1.2",
-                "phpunit/php-timer": "~1.0.2",
-                "phpunit/phpunit-mock-objects": "2.4.*@dev",
-                "sebastian/comparator": "1.1.*@dev",
-                "sebastian/diff": "~1.1",
-                "sebastian/environment": "~1.2",
-                "sebastian/exporter": "~1.0",
-                "sebastian/global-state": "1.0.*@dev",
-                "sebastian/version": "~1.0",
-                "symfony/yaml": "~2.0"
-            },
-            "suggest": {
-                "phpunit/php-invoker": "~1.1"
-            },
-            "bin": [
-                "phpunit"
-            ],
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "4.5.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "The PHP Unit Testing framework.",
-            "homepage": "https://phpunit.de/",
-            "keywords": [
-                "phpunit",
-                "testing",
-                "xunit"
-            ],
-            "time": "2014-11-06 08:43:29"
-        },
-        {
-            "name": "phpunit/phpunit-mock-objects",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git",
-                "reference": "96c5b81f9842f38fe6c73ad0020306cc4862a9e3"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/96c5b81f9842f38fe6c73ad0020306cc4862a9e3",
-                "reference": "96c5b81f9842f38fe6c73ad0020306cc4862a9e3",
-                "shasum": ""
-            },
-            "require": {
-                "doctrine/instantiator": "~1.0,>=1.0.2",
-                "php": ">=5.3.3",
-                "phpunit/php-text-template": "~1.2"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "4.4.*@dev"
-            },
-            "suggest": {
-                "ext-soap": "*"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "2.4.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sb@sebastian-bergmann.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "Mock Object library for PHPUnit",
-            "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/",
-            "keywords": [
-                "mock",
-                "xunit"
-            ],
-            "time": "2014-10-04 10:04:20"
-        },
-        {
-            "name": "sebastian/comparator",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/comparator.git",
-                "reference": "6f67d2ae044ba17ba30573941f4ac96c4777be97"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/6f67d2ae044ba17ba30573941f4ac96c4777be97",
-                "reference": "6f67d2ae044ba17ba30573941f4ac96c4777be97",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3",
-                "sebastian/diff": "~1.1",
-                "sebastian/exporter": "~1.0"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.1"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.1.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Jeff Welch",
-                    "email": "whatthejeff@gmail.com"
-                },
-                {
-                    "name": "Volker Dusch",
-                    "email": "github@wallbash.com"
-                },
-                {
-                    "name": "Bernhard Schussek",
-                    "email": "bschussek@2bepublished.at"
-                },
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                }
-            ],
-            "description": "Provides the functionality to compare PHP values for equality",
-            "homepage": "http://www.github.com/sebastianbergmann/comparator",
-            "keywords": [
-                "comparator",
-                "compare",
-                "equality"
-            ],
-            "time": "2014-10-21 10:04:18"
-        },
-        {
-            "name": "sebastian/diff",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/diff.git",
-                "reference": "3e22c89be2e1cddf7db89699cb23a9159df12e0c"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3e22c89be2e1cddf7db89699cb23a9159df12e0c",
-                "reference": "3e22c89be2e1cddf7db89699cb23a9159df12e0c",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.2"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.2-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Kore Nordmann",
-                    "email": "mail@kore-nordmann.de"
-                },
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                }
-            ],
-            "description": "Diff implementation",
-            "homepage": "http://www.github.com/sebastianbergmann/diff",
-            "keywords": [
-                "diff"
-            ],
-            "time": "2014-11-05 15:28:21"
-        },
-        {
-            "name": "sebastian/environment",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/environment.git",
-                "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6e6c71d918088c251b181ba8b3088af4ac336dd7",
-                "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.3"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.2.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                }
-            ],
-            "description": "Provides functionality to handle HHVM/PHP environments",
-            "homepage": "http://www.github.com/sebastianbergmann/environment",
-            "keywords": [
-                "Xdebug",
-                "environment",
-                "hhvm"
-            ],
-            "time": "2014-10-25 08:00:45"
-        },
-        {
-            "name": "sebastian/exporter",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/exporter.git",
-                "reference": "c7d59948d6e82818e1bdff7cadb6c34710eb7dc0"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c7d59948d6e82818e1bdff7cadb6c34710eb7dc0",
-                "reference": "c7d59948d6e82818e1bdff7cadb6c34710eb7dc0",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.0"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.0.x-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Jeff Welch",
-                    "email": "whatthejeff@gmail.com"
-                },
-                {
-                    "name": "Volker Dusch",
-                    "email": "github@wallbash.com"
-                },
-                {
-                    "name": "Bernhard Schussek",
-                    "email": "bschussek@2bepublished.at"
-                },
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                },
-                {
-                    "name": "Adam Harvey",
-                    "email": "aharvey@php.net"
-                }
-            ],
-            "description": "Provides the functionality to export PHP variables for visualization",
-            "homepage": "http://www.github.com/sebastianbergmann/exporter",
-            "keywords": [
-                "export",
-                "exporter"
-            ],
-            "time": "2014-09-10 00:51:36"
-        },
-        {
-            "name": "sebastian/global-state",
-            "version": "dev-master",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/global-state.git",
-                "reference": "231d48620efde984fd077ee92916099a3ece9a59"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/231d48620efde984fd077ee92916099a3ece9a59",
-                "reference": "231d48620efde984fd077ee92916099a3ece9a59",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "require-dev": {
-                "phpunit/phpunit": "~4.2"
-            },
-            "suggest": {
-                "ext-uopz": "*"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "1.0-dev"
-                }
-            },
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de"
-                }
-            ],
-            "description": "Snapshotting of global state",
-            "homepage": "http://www.github.com/sebastianbergmann/global-state",
-            "keywords": [
-                "global state"
-            ],
-            "time": "2014-10-06 09:49:11"
-        },
-        {
-            "name": "sebastian/version",
-            "version": "1.0.3",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/sebastianbergmann/version.git",
-                "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43",
-                "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43",
-                "shasum": ""
-            },
-            "type": "library",
-            "autoload": {
-                "classmap": [
-                    "src/"
-                ]
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "BSD-3-Clause"
-            ],
-            "authors": [
-                {
-                    "name": "Sebastian Bergmann",
-                    "email": "sebastian@phpunit.de",
-                    "role": "lead"
-                }
-            ],
-            "description": "Library that helps with managing the version number of Git-hosted PHP projects",
-            "homepage": "https://github.com/sebastianbergmann/version",
-            "time": "2014-03-07 15:35:33"
-        },
-        {
-            "name": "symfony/yaml",
-            "version": "2.7.x-dev",
-            "target-dir": "Symfony/Component/Yaml",
-            "source": {
-                "type": "git",
-                "url": "https://github.com/symfony/Yaml.git",
-                "reference": "6165f4b5224c22de2873deb6a3a4e622044f0705"
-            },
-            "dist": {
-                "type": "zip",
-                "url": "https://api.github.com/repos/symfony/Yaml/zipball/6165f4b5224c22de2873deb6a3a4e622044f0705",
-                "reference": "6165f4b5224c22de2873deb6a3a4e622044f0705",
-                "shasum": ""
-            },
-            "require": {
-                "php": ">=5.3.3"
-            },
-            "type": "library",
-            "extra": {
-                "branch-alias": {
-                    "dev-master": "2.7-dev"
-                }
-            },
-            "autoload": {
-                "psr-0": {
-                    "Symfony\\Component\\Yaml\\": ""
-                }
-            },
-            "notification-url": "https://packagist.org/downloads/",
-            "license": [
-                "MIT"
-            ],
-            "authors": [
-                {
-                    "name": "Symfony Community",
-                    "homepage": "http://symfony.com/contributors"
-                },
-                {
-                    "name": "Fabien Potencier",
-                    "email": "fabien@symfony.com"
-                }
-            ],
-            "description": "Symfony Yaml Component",
-            "homepage": "http://symfony.com",
-            "time": "2014-11-10 18:00:54"
-        }
-    ],
-    "aliases": [],
-    "minimum-stability": "dev",
-    "stability-flags": [],
-    "prefer-stable": false,
-    "platform": [],
-    "platform-dev": []
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/phpunit.xml
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/phpunit.xml b/sdks/php5/apache-usergrid/phpunit.xml
deleted file mode 100644
index ce3af97..0000000
--- a/sdks/php5/apache-usergrid/phpunit.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<phpunit backupGlobals="false"
-         backupStaticAttributes="false"
-         bootstrap="tests/bootstrap.php"
-         colors="true"
-         convertErrorsToExceptions="true"
-         convertNoticesToExceptions="true"
-         convertWarningsToExceptions="true"
-         processIsolation="false"
-         stopOnFailure="false"
-         syntaxCheck="false"
-        >
-    <testsuites>
-        <testsuite name="Apache Usergrid PHP SDK Test Suite">
-            <directory>./tests</directory>
-        </testsuite>
-    </testsuites>
-    <filter>
-        <whitelist>
-            <directory suffix=".php">./src/</directory>
-            <exclude>
-                <file>./src/Laravel/ApacheUsergridServiceProvider.php</file>
-            </exclude>
-        </whitelist>
-    </filter>
-    <logging>
-        <log type="coverage-text" target="php://stdout" showUncoveredFiles="true"/>
-    </logging>
-</phpunit>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/BadRequestException.php b/sdks/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
deleted file mode 100644
index 1e63c40..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-
-namespace Apache\Usergrid\Api\Exception;
-
-
-/**
- * Class BadRequestException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class BadRequestException extends UsergridException
-{
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php b/sdks/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
deleted file mode 100644
index c59a683..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Exception;
-
-
-/**
- * Class InvalidIdException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class InvalidIdException extends UsergridException
-{
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/NotFoundException.php b/sdks/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
deleted file mode 100644
index c371538..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Exception;
-
-
-/**
- * Class NotFoundException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class NotFoundException extends UsergridException
-{
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php b/sdks/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
deleted file mode 100644
index 2286133..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
+++ /dev/null
@@ -1,33 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Exception;
-
-
-/**
- * Class ServerErrorException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ServerErrorException extends UsergridException
-{
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php b/sdks/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
deleted file mode 100644
index 3e3ae41..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
+++ /dev/null
@@ -1,34 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-
-namespace Apache\Usergrid\Api\Exception;
-
-
-/**
- * Class UnauthorizedException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UnauthorizedException extends UsergridException
-{
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Exception/UsergridException.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Exception/UsergridException.php b/sdks/php5/apache-usergrid/src/Api/Exception/UsergridException.php
deleted file mode 100644
index 8aedb03..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Exception/UsergridException.php
+++ /dev/null
@@ -1,152 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Api\Exception;
-
-
-use Exception;
-use Guzzle\Http\Message\Request;
-use Guzzle\Http\Message\Response;
-use Guzzle\Plugin\ErrorResponse\ErrorResponseExceptionInterface;
-use Guzzle\Service\Command\CommandInterface;
-
-/**
- * Class UsergridException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UsergridException extends Exception implements ErrorResponseExceptionInterface
-{
-    /**
-     * The Guzzle request.
-     *
-     * @var \Guzzle\Http\Message\Request
-     */
-    protected $request;
-
-    /**
-     * The Guzzle response.
-     *
-     * @var \Guzzle\Http\Message\Response
-     */
-    protected $response;
-
-    /**
-     * The error type returned by Usergrid.
-     *
-     * @var string
-     */
-    protected $errorType;
-
-    /**
-     * {@inheritDoc}
-     */
-    public static function fromCommand(CommandInterface $command, Response $response)
-    {
-        $errors = json_decode($response->getBody(true), true);
-
-        $type = array_get($errors, 'error.type', null);
-
-        $code = array_get($errors, 'error.code', null);
-
-        $message = array_get($errors, 'error.message', null);
-
-        $class = '\\Apache\\Usergrid\\Api\\Exception\\' . studly_case($type) . 'Exception';
-
-        if (class_exists($class)) {
-            $exception = new $class($message, $response->getStatusCode());
-        } else {
-            $exception = new static($message, $response->getStatusCode());
-        }
-
-        $exception->setErrorType($type);
-
-        $exception->setResponse($response);
-
-        $exception->setRequest($command->getRequest());
-
-        return $exception;
-    }
-
-    /**
-     * Returns the Guzzle request.
-     *
-     * @return \Guzzle\Http\Message\Request
-     */
-    public function getRequest()
-    {
-        return $this->request;
-    }
-
-    /**
-     * Sets the Guzzle request.
-     *
-     * @param  \Guzzle\Http\Message\Request $request
-     * @return void
-     */
-    public function setRequest(Request $request)
-    {
-        $this->request = $request;
-    }
-
-    /**
-     * Returns the Guzzle response.
-     *
-     * @return \Guzzle\Http\Message\Response
-     */
-    public function getResponse()
-    {
-        return $this->response;
-    }
-
-    /**
-     * Sets the Guzzle response.
-     *
-     * @param  \Guzzle\Http\Message\Response $response
-     * @return void
-     */
-    public function setResponse(Response $response)
-    {
-        $this->response = $response;
-    }
-
-    /**
-     * Returns the error type returned by Usergrid.
-     *
-     * @return string
-     */
-    public function getErrorType()
-    {
-        return $this->errorType;
-    }
-
-    /**
-     * Sets the error type returned by Usergrid.
-     *
-     * @param  string $errorType
-     * @return void
-     */
-    public function setErrorType($errorType)
-    {
-        $this->errorType = $errorType;
-    }
-
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Filters/Boolean.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Filters/Boolean.php b/sdks/php5/apache-usergrid/src/Api/Filters/Boolean.php
deleted file mode 100644
index 021f2fd..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Filters/Boolean.php
+++ /dev/null
@@ -1,44 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Filters;
-
-
-/**
- * Class Boolean
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Boolean
-{
-
-    /**
-     * Converts a boolean into its string representation.
-     *
-     * @param  bool $boolean
-     * @return string
-     */
-    public static function convert($boolean)
-    {
-        return $boolean ? 'true' : 'false';
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Filters/Date.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Filters/Date.php b/sdks/php5/apache-usergrid/src/Api/Filters/Date.php
deleted file mode 100644
index 8b3c5c6..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Filters/Date.php
+++ /dev/null
@@ -1,44 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Filters;
-
-use Carbon\Carbon;
-
-/**
- * Class Date
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Date
-{
-
-    /**
-     * @param $date
-     * @return static
-     */
-    public static function convert($date)
-    {
-        $date2 = (int)($date / 1000);
-        $date_string = Carbon::createFromTimestampUTC($date2)->toDayDateTimeString();
-        return $date_string;
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Filters/Number.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Filters/Number.php b/sdks/php5/apache-usergrid/src/Api/Filters/Number.php
deleted file mode 100644
index 41047d3..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Filters/Number.php
+++ /dev/null
@@ -1,48 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Filters;
-
-
-/**
- * Class Number
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Number
-{
-
-    /**
-     * Converts a number into an integer.
-     *
-     * @param  mixed $number
-     * @return int
-     */
-    public static function convert($number)
-    {
-        if (is_string($number) || is_float($number)) {
-            return (int)($number * 100);
-        }
-
-        return $number;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/GuzzleClient.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/GuzzleClient.php b/sdks/php5/apache-usergrid/src/Api/GuzzleClient.php
deleted file mode 100644
index 6ef9d8a..0000000
--- a/sdks/php5/apache-usergrid/src/Api/GuzzleClient.php
+++ /dev/null
@@ -1,64 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api;
-
-
-use Guzzle\Service\Client;
-
-/**
- * Class GuzzleClient
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class GuzzleClient extends Client
-{
-
-    /**
-     * The Usergrid API client instance.
-     *
-     * @var  \Apache\Usergrid\Api\Usergrid
-     */
-    protected $apiClient;
-
-    /**
-     * Returns the Usergrid API client instance.
-     *
-     * @return  \Apache\Usergrid\Api\Usergrid
-     */
-    public function getApiClient()
-    {
-        return $this->apiClient;
-    }
-
-    /**
-     * Sets the Usergrid API client instance.
-     *
-     * @param \Apache\Usergrid\Api\Usergrid $client
-     * @return void
-     */
-    public function setApiClient(Usergrid $client)
-    {
-        $this->apiClient = $client;
-    }
-
-
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Application.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Application.php b/sdks/php5/apache-usergrid/src/Api/Models/Application.php
deleted file mode 100644
index 336d6d9..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Application.php
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Application
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Application extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/BaseCollection.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/BaseCollection.php b/sdks/php5/apache-usergrid/src/Api/Models/BaseCollection.php
deleted file mode 100644
index 4cc7d67..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/BaseCollection.php
+++ /dev/null
@@ -1,116 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Apache\Usergrid\Api\Usergrid;
-use Illuminate\Support\Collection;
-
-/**
- * Class BaseCollection
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class BaseCollection extends Collection
-{
-    /**
-     * List of API response properties that'll be
-     * automatically converted into collections.
-     *
-     * @var array
-     */
-    protected $collections = ['entities'];
-
-    /**
-     * The Usergrid API client instance.
-     *
-     * @var /Apache\Usergrid\Api\Usergrid
-     */
-    protected $apiClient;
-
-    /**
-     * Returns the given key value from the collection.
-     *
-     * @param  mixed $key
-     * @return mixed
-     */
-    public function __get($key)
-    {
-        if (in_array($key, $this->collections) || array_key_exists($key, $this->collections)) {
-            if ($mappedKey = array_get($this->collections, $key, [])) {
-                $key = strstr($mappedKey, '.', true);
-
-                $query = ltrim(strstr($mappedKey, '.'), '.');
-
-                $data = array_get($this->get($key), $query, []);
-            } else {
-                $data = $this->get($key, []);
-            }
-            // create a new class of self so subclasses get new collection from entities of the correct model
-            // eg: before when asking  the User Model for its entities returned a collection of the BaseCollection class not the user class..
-            $class = self::instance($data);
-            //set the api client on collection so api attribute properties can make api calls to get related models
-            $class->setApiClient($this->getApiClient());
-            // return class.
-            return $class;
-
-        }
-        // check to see if the property you asked for is a attribute method
-        if (method_exists($this, $method = "{$key}Attribute")) {
-            return $this->{$method}($this->get($key));
-        }
-
-        //else return key
-        return $this->get($key, null);
-    }
-
-    /**
-     * @param $data
-     * @return static
-     */
-    private static function instance($data)
-    {
-        return new static($data);
-    }
-
-    /**
-     * Returns the Usergrid API client instance.
-     *
-     * @return  /Apache\Usergrid\Api\Usergrid  /Apache\Usergrid\Api\Usergrid
-     */
-    public function getApiClient()
-    {
-        return $this->apiClient;
-    }
-
-    /**
-     * Sets the Usergrid API client instance.
-     *
-     * @param Usergrid $client
-     * @internal param $ /Apache\Usergrid\Api\Usergrid $client
-     * @return void
-     */
-    public function setApiClient(Usergrid $client)
-    {
-        $this->apiClient = $client;
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Collection.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Collection.php b/sdks/php5/apache-usergrid/src/Api/Models/Collection.php
deleted file mode 100644
index 9fb6d5b..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Collection.php
+++ /dev/null
@@ -1,37 +0,0 @@
-<?php
-
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Collection
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Collection extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Device.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Device.php b/sdks/php5/apache-usergrid/src/Api/Models/Device.php
deleted file mode 100644
index 403ff8d..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Device.php
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Device
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Device extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-
-    public function userAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'devices',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'users'
-        ])->toArray();
-    }
-
-    public function notifierAttribute()
-    {
-
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Entity.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Entity.php b/sdks/php5/apache-usergrid/src/Api/Models/Entity.php
deleted file mode 100644
index 5063fd0..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Entity.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Entity
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Entity extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Event.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Event.php b/sdks/php5/apache-usergrid/src/Api/Models/Event.php
deleted file mode 100644
index 2e04595..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Event.php
+++ /dev/null
@@ -1,35 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Event
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Event extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Group.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Group.php b/sdks/php5/apache-usergrid/src/Api/Models/Group.php
deleted file mode 100644
index 6b034ca..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Group.php
+++ /dev/null
@@ -1,54 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Group
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Group extends BaseCollection implements ResponseClassInterface
-{
-
-    use GuzzleCommandTrait;
-
-    public function usersAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'groups',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'users'
-        ])->toArray();
-    }
-
-    public function rolesAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'groups',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'roles'
-        ])->toArray();
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php b/sdks/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
deleted file mode 100644
index e6ccb68..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-use Guzzle\Service\Command\OperationCommand;
-
-/**
- * Class GuzzleCommandTrait
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-trait GuzzleCommandTrait
-{
-    /**
-     * Create a response model object from a completed command.
-     *
-     * @param OperationCommand $command That serialized the request
-     * @return \Illuminate\Support\Collection
-     */
-    public static function fromCommand(OperationCommand $command)
-    {
-        // Initialize the collection
-        $collection = new self($command->getResponse()->json());
-
-        // Set the Usergrid API client on the collection
-        $collection->setApiClient($command->getClient()->getApiClient());
-
-        // Return the collection
-        return $collection;
-    }
-
-    /**
-     *  Returns true if there is a cursor or false if there is not
-     * @return bool
-     */
-    public function hasNextPage()
-    {
-        return $this->has('cursor');
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Notifier.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Notifier.php b/sdks/php5/apache-usergrid/src/Api/Models/Notifier.php
deleted file mode 100644
index a4c21c8..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Notifier.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Application
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Notifier extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Organization.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Organization.php b/sdks/php5/apache-usergrid/src/Api/Models/Organization.php
deleted file mode 100644
index d58d3d4..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Organization.php
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Organization
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Organization extends BaseCollection implements ResponseClassInterface
-{
-
-    use GuzzleCommandTrait;
-
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Receipt.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Receipt.php b/sdks/php5/apache-usergrid/src/Api/Models/Receipt.php
deleted file mode 100644
index bc09235..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Receipt.php
+++ /dev/null
@@ -1,36 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Application
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Receipt extends BaseCollection implements ResponseClassInterface
-{
-    use GuzzleCommandTrait;
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/Role.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Role.php b/sdks/php5/apache-usergrid/src/Api/Models/Role.php
deleted file mode 100644
index 3e93465..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/Role.php
+++ /dev/null
@@ -1,54 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class Role
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Role extends BaseCollection implements ResponseClassInterface
-{
-
-    use GuzzleCommandTrait;
-
-    public function usersAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'roles',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'users'
-        ])->toArray();
-    }
-
-    public function groupsAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'roles',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'groups'
-        ])->toArray();
-    }
-}
\ No newline at end of file


[30/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/AddBookViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/AddBookViewController.m b/sdks/other/ios/samples/Books/books/AddBookViewController.m
new file mode 100644
index 0000000..85afa77
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/AddBookViewController.m
@@ -0,0 +1,169 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  AddBookViewController.m
+//  books
+//
+
+#import "AddBookViewController.h"
+#import "UGConnection.h"
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+
+@interface FormTableViewCell : UITableViewCell <UITextFieldDelegate>
+@property (nonatomic, strong) UILabel *label;
+@property (nonatomic, strong) UITextField *textField;
+@property (nonatomic, strong) NSString *key;
+@property (nonatomic, weak) id binding;
+@end
+
+@implementation FormTableViewCell
+
+- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
+{
+    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
+        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
+        self.label.backgroundColor = [UIColor clearColor];
+        self.label.font = [UIFont systemFontOfSize:10];
+        self.label.textColor = [UIColor grayColor];
+        self.label.textAlignment = NSTextAlignmentLeft;
+        [self.contentView addSubview:self.label];
+        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
+        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
+        self.textField.font = [UIFont systemFontOfSize:18];
+        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
+        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
+        self.textField.delegate = self;
+        if ([key isEqualToString:@"password"]) {
+            self.textField.secureTextEntry = YES;
+        }
+        [self.contentView addSubview:self.textField];
+        self.selectionStyle = UITableViewCellSelectionStyleNone;
+        // individual cell properties
+        self.label.text = title;
+        self.key = key;
+        self.binding = binding;
+    }
+    return self;
+}
+
+- (void) layoutSubviews
+{
+    [super layoutSubviews];
+    CGRect textFieldFrame = self.textField.frame;
+    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
+    self.textField.frame = textFieldFrame;
+}
+
+- (void) textFieldDidEndEditing:(UITextField *)textField
+{
+    [self.binding setObject:textField.text forKey:self.key];
+}
+
+@end
+
+@interface AddBookViewController ()
+@property (nonatomic, strong) NSMutableDictionary *values;
+@property (nonatomic, strong) NSArray *cells;
+@end
+
+@implementation AddBookViewController
+
+- (id)init {
+    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
+        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
+        if (!self.values) {
+            self.values = [NSMutableDictionary dictionary];
+        }
+        self.cells =
+        @[[[FormTableViewCell alloc] initWithTitle:@"Title" key:@"title" binding:self.values],
+          [[FormTableViewCell alloc] initWithTitle:@"Author" key:@"author" binding:self.values]];
+    }
+    return self;
+}
+
+- (void) loadView
+{
+    [super loadView];
+    self.title = @"Connection";
+    self.tableView.backgroundView = nil;
+    self.tableView.backgroundColor = [UIColor darkGrayColor];
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithTitle:@"Cancel"
+                                             style:UIBarButtonItemStyleBordered
+                                             target:self
+                                             action:@selector(cancel:)];
+    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
+                                              initWithTitle:@"Save"
+                                              style:UIBarButtonItemStyleBordered
+                                              target:self
+                                              action:@selector(save:)];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return [self.cells count];
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    return [self.cells objectAtIndex:[indexPath row]];
+}
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    FormTableViewCell *formCell = (FormTableViewCell *) cell;
+    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    FormTableViewCell *formCell = (FormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
+    [formCell.textField becomeFirstResponder];
+}
+
+#pragma mark - Sign In
+
+- (void) cancel:(id) sender
+{
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+- (void) save:(id) sender
+{
+    for (FormTableViewCell *cell in self.cells) {
+        [cell.textField resignFirstResponder];
+    }    
+    UGConnection *connection = [UGConnection sharedConnection];
+    [[[UGHTTPClient alloc] initWithRequest:
+      [connection createEntityInCollection:@"books" withValues:self.values]]
+     connectWithCompletionHandler:^(UGHTTPResult *result) {
+         [self dismissViewControllerAnimated:YES completion:nil];
+     }];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/AppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/AppDelegate.h b/sdks/other/ios/samples/Books/books/AppDelegate.h
new file mode 100644
index 0000000..185592e
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/AppDelegate.h
@@ -0,0 +1,43 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  AppDelegate.h
+//  books
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface AppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/AppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/AppDelegate.m b/sdks/other/ios/samples/Books/books/AppDelegate.m
new file mode 100644
index 0000000..f1082ef
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/AppDelegate.m
@@ -0,0 +1,43 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  AppDelegate.m
+//  books
+//
+
+#import "AppDelegate.h"
+#import "BooksViewController.h"
+
+@implementation AppDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
+    UINavigationController *navigationController = [[UINavigationController alloc]
+                                                    initWithRootViewController:[[BooksViewController alloc] init]];
+    navigationController.navigationBar.tintColor = [UIColor colorWithRed:100.0/255.0
+                                                                   green:150.0/255.0
+                                                                    blue:200.0/255.0
+                                                                   alpha:1];
+    self.window.rootViewController = navigationController;
+    self.window.backgroundColor = [UIColor whiteColor];
+    [self.window makeKeyAndVisible];
+    return YES;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/BooksViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/BooksViewController.h b/sdks/other/ios/samples/Books/books/BooksViewController.h
new file mode 100644
index 0000000..b286c29
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/BooksViewController.h
@@ -0,0 +1,41 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  BooksViewController.h
+//  books
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface BooksViewController : UITableViewController
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/BooksViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/BooksViewController.m b/sdks/other/ios/samples/Books/books/BooksViewController.m
new file mode 100644
index 0000000..44be61c
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/BooksViewController.m
@@ -0,0 +1,154 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  BooksViewController.m
+//  books
+//
+
+#import "BooksViewController.h"
+#import "UGSignInViewController.h"
+#import "UGConnection.h"
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+#import "AddBookViewController.h"
+
+@interface BooksViewController ()
+@property (nonatomic, strong) NSDictionary *content;
+@end
+
+@implementation BooksViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+    self = [super initWithStyle:style];
+    if (self) {
+        // Custom initialization
+    }
+    return self;
+}
+
+- (void)loadView
+{
+    [super loadView];
+    self.navigationItem.title = @"My Books";
+    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Add Book"
+                                                                              style:UIBarButtonItemStyleBordered target:self action:@selector(addbook:)];
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithTitle:@"Connection"
+                                             style:UIBarButtonItemStyleBordered
+                                             target:self
+                                             action:@selector(connect:)];                                              
+}
+
+- (void) connect:(id) sender
+{
+    UGSignInViewController *signinViewController = [[UGSignInViewController alloc] init];
+    UINavigationController *signinNavigationController =
+    [[UINavigationController alloc] initWithRootViewController:signinViewController];
+    signinNavigationController.modalPresentationStyle = UIModalPresentationFormSheet;
+    signinNavigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
+    [self presentViewController:signinNavigationController animated:YES completion:nil];
+}
+
+- (void) addbook:(id) sender
+{
+    AddBookViewController *addBookViewController = [[AddBookViewController alloc] init];
+    UINavigationController *navigationController =
+    [[UINavigationController alloc] initWithRootViewController:addBookViewController];
+    navigationController.modalPresentationStyle = UIModalPresentationFormSheet;
+    navigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
+    [self presentViewController:navigationController animated:YES completion:nil];
+}
+
+- (void) viewWillAppear:(BOOL)animated
+{
+    [self reload];
+}
+
+- (void) reload {
+    UGConnection *usergrid = [UGConnection sharedConnection];
+    if ([usergrid isAuthenticated]) {
+        NSLog(@"loading...");
+        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
+                                [usergrid getEntitiesInCollection:@"books" limit:100]];
+        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
+            NSLog(@"%@", result.object);
+            self.content = result.object;
+            [self.tableView reloadData];
+        }];
+    }
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    // Return the number of sections.
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    // Return the number of rows in the section.
+    return self.content ? [self.content[@"entities"] count] : 1;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    return [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
+}
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (!self.content) {
+        cell.textLabel.text = @"Please sign in.";
+    } else {
+        id entity = self.content[@"entities"][[indexPath row]];
+        cell.textLabel.text = entity[@"title"];
+        cell.detailTextLabel.text = entity[@"author"];
+        UIButton *deleteButton = [UIButton buttonWithType:UIButtonTypeRoundedRect];
+        cell.accessoryView = deleteButton;
+        [deleteButton setTitle:@"X" forState:UIControlStateNormal];
+        deleteButton.tag = [indexPath row];
+        [deleteButton addTarget:self action:@selector(deleteItem:) forControlEvents:UIControlEventTouchUpInside];
+        [deleteButton sizeToFit];
+    }
+    cell.selectionStyle = UITableViewCellSelectionStyleNone;
+}
+
+- (void) deleteItem:(UIButton *) sender {
+    int row = [sender tag];
+    id entity = self.content[@"entities"][row];
+    NSString *uuid = [entity objectForKey:@"uuid"];
+    UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
+                            [[UGConnection sharedConnection] deleteEntity:uuid inCollection:@"books"]];
+    [client connectWithCompletionHandler:^(UGHTTPResult *result) {
+        [self reload];
+    }];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (!self.content) {
+        [self connect:nil];
+    }
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/Default-568h@2x.png b/sdks/other/ios/samples/Books/books/Default-568h@2x.png
new file mode 100644
index 0000000..0891b7a
Binary files /dev/null and b/sdks/other/ios/samples/Books/books/Default-568h@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/Default.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/Default.png b/sdks/other/ios/samples/Books/books/Default.png
new file mode 100644
index 0000000..4c8ca6f
Binary files /dev/null and b/sdks/other/ios/samples/Books/books/Default.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/Default@2x.png b/sdks/other/ios/samples/Books/books/Default@2x.png
new file mode 100644
index 0000000..35b84cf
Binary files /dev/null and b/sdks/other/ios/samples/Books/books/Default@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/UGSignInViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/UGSignInViewController.h b/sdks/other/ios/samples/Books/books/UGSignInViewController.h
new file mode 100644
index 0000000..b831869
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/UGSignInViewController.h
@@ -0,0 +1,23 @@
+//
+//  UGSignInViewController.h
+//  books
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@class UGAppViewController;
+
+@interface UGSignInViewController : UITableViewController
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/UGSignInViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/UGSignInViewController.m b/sdks/other/ios/samples/Books/books/UGSignInViewController.m
new file mode 100644
index 0000000..6cccb77
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/UGSignInViewController.m
@@ -0,0 +1,184 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGSignInViewController.m
+//  books
+//
+
+
+#import "UGHTTPClient.h"
+#import "UGConnection.h"
+#import "UGSignInViewController.h"
+
+#define SERVER @"http://api.usergrid.com"
+
+@interface UGFormTableViewCell : UITableViewCell <UITextFieldDelegate>
+@property (nonatomic, strong) UILabel *label;
+@property (nonatomic, strong) UITextField *textField;
+@property (nonatomic, strong) NSString *key;
+@property (nonatomic, weak) id binding;
+@end
+
+@implementation UGFormTableViewCell
+
+- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
+{
+    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
+        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
+        self.label.backgroundColor = [UIColor clearColor];
+        self.label.font = [UIFont systemFontOfSize:10];
+        self.label.textColor = [UIColor grayColor];
+        self.label.textAlignment = NSTextAlignmentLeft;
+        [self.contentView addSubview:self.label];
+        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
+        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
+        self.textField.font = [UIFont systemFontOfSize:18];
+        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
+        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
+        self.textField.delegate = self;
+        if ([key isEqualToString:@"password"]) {
+            self.textField.secureTextEntry = YES;
+        }
+        [self.contentView addSubview:self.textField];
+        self.selectionStyle = UITableViewCellSelectionStyleNone;
+        // individual cell properties
+        self.label.text = title;
+        self.key = key;
+        self.binding = binding;
+    }
+    return self;
+}
+
+- (void) layoutSubviews
+{
+    [super layoutSubviews];
+    CGRect textFieldFrame = self.textField.frame;
+    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
+    self.textField.frame = textFieldFrame;
+}
+
+- (void) textFieldDidEndEditing:(UITextField *)textField
+{
+    [self.binding setObject:textField.text forKey:self.key];
+}
+
+@end
+
+@interface UGSignInViewController ()
+@property (nonatomic, strong) NSMutableDictionary *values;
+@property (nonatomic, strong) NSArray *cells;
+@end
+
+@implementation UGSignInViewController
+
+- (id)init {
+    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
+        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
+        if (!self.values) {
+            self.values = [NSMutableDictionary dictionary];
+            [self.values setObject:SERVER forKey:@"server"];
+        }
+        self.cells =
+        @[[[UGFormTableViewCell alloc] initWithTitle:@"Server" key:@"server" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Organization" key:@"organization" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Application" key:@"application" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Username" key:@"username" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Password" key:@"password" binding:self.values]];
+    }
+    return self;
+}
+
+- (void) loadView
+{
+    [super loadView];
+    self.title = @"Connection";
+    self.tableView.backgroundView = nil;
+    self.tableView.backgroundColor = [UIColor darkGrayColor];
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithTitle:@"Cancel"
+                                             style:UIBarButtonItemStyleBordered
+                                             target:self
+                                             action:@selector(cancel:)];
+    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
+                                              initWithTitle:@"Sign In"
+                                              style:UIBarButtonItemStyleBordered
+                                              target:self
+                                              action:@selector(signin:)];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return [self.cells count];
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    return [self.cells objectAtIndex:[indexPath row]];
+}
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UGFormTableViewCell *formCell = (UGFormTableViewCell *) cell;
+    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UGFormTableViewCell *formCell = (UGFormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
+    [formCell.textField becomeFirstResponder];
+}
+
+#pragma mark - Sign In
+
+- (void) cancel:(id) sender
+{
+    [self dismissViewControllerAnimated:YES completion:nil];
+}
+
+- (void) signin:(id) sender
+{
+    for (UGFormTableViewCell *cell in self.cells) {
+        [cell.textField resignFirstResponder];
+    }
+    [[NSUserDefaults standardUserDefaults] setObject:self.values forKey:@"usergrid"];
+    [[NSUserDefaults standardUserDefaults] synchronize];
+    
+    UGConnection *connection = [UGConnection sharedConnection];
+    connection.server = [self.values objectForKey:@"server"];
+    connection.organization = [self.values objectForKey:@"organization"];
+    connection.application = [self.values objectForKey:@"application"];
+    
+    [[[UGHTTPClient alloc] initWithRequest:
+      [connection getAccessTokenForApplicationWithUsername:[self.values objectForKey:@"username"]
+                                                  password:[self.values objectForKey:@"password"]]]
+     connectWithCompletionHandler:^(UGHTTPResult *result) {
+         [connection authenticateWithResult:result];
+         [self dismissViewControllerAnimated:YES completion:nil];
+     }];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/books-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/books-Info.plist b/sdks/other/ios/samples/Books/books/books-Info.plist
new file mode 100644
index 0000000..f394f12
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/books-Info.plist
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+-->
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/books-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/books-Prefix.pch b/sdks/other/ios/samples/Books/books/books-Prefix.pch
new file mode 100644
index 0000000..42d6379
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/books-Prefix.pch
@@ -0,0 +1,31 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+// Prefix header for all source files of the 'books' target in the 'books' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_3_0
+#warning "This project uses features only available in iOS SDK 3.0 and later."
+#endif
+
+#ifdef __OBJC__
+    #import <UIKit/UIKit.h>
+    #import <Foundation/Foundation.h>
+#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/en.lproj/InfoPlist.strings b/sdks/other/ios/samples/Books/books/en.lproj/InfoPlist.strings
new file mode 100644
index 0000000..7004264
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/en.lproj/InfoPlist.strings
@@ -0,0 +1,21 @@
+/*
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+*/
+
+/* Localized versions of Info.plist keys */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/main.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/main.m b/sdks/other/ios/samples/Books/books/main.m
new file mode 100644
index 0000000..a3b2f01
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/main.m
@@ -0,0 +1,32 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  main.m
+//  books
+//
+
+#import <UIKit/UIKit.h>
+
+#import "AppDelegate.h"
+
+int main(int argc, char *argv[])
+{
+    @autoreleasepool {
+        return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser.xcodeproj/project.pbxproj b/sdks/other/ios/samples/Browser/browser.xcodeproj/project.pbxproj
new file mode 100644
index 0000000..63320fd
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser.xcodeproj/project.pbxproj
@@ -0,0 +1,487 @@
+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		22FC709C1730595C00153630 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709B1730595C00153630 /* UIKit.framework */; };
+		22FC709E1730595C00153630 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709D1730595C00153630 /* Foundation.framework */; };
+		22FC70A01730595C00153630 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC709F1730595C00153630 /* CoreGraphics.framework */; };
+		22FC70A61730595C00153630 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70A41730595C00153630 /* InfoPlist.strings */; };
+		22FC70A81730595C00153630 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70A71730595C00153630 /* main.m */; };
+		22FC70AE1730595C00153630 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70AD1730595C00153630 /* Default.png */; };
+		22FC70B01730595C00153630 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70AF1730595C00153630 /* Default@2x.png */; };
+		22FC70B21730595C00153630 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC70B11730595C00153630 /* Default-568h@2x.png */; };
+		22FC70C41730639600153630 /* UGAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70B91730639600153630 /* UGAppDelegate.m */; };
+		22FC70C51730639600153630 /* UGAppViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BB1730639600153630 /* UGAppViewController.m */; };
+		22FC70C61730639600153630 /* UGCollectionViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BD1730639600153630 /* UGCollectionViewController.m */; };
+		22FC70C71730639600153630 /* UGEntityViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70BF1730639600153630 /* UGEntityViewController.m */; };
+		22FC70C81730639600153630 /* UGSignInViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70C11730639600153630 /* UGSignInViewController.m */; };
+		22FC70C91730639600153630 /* UGTextViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70C31730639600153630 /* UGTextViewController.m */; };
+		22FC70FD173063AF00153630 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70CD173063AF00153630 /* NSObject+SBJson.m */; };
+		22FC70FE173063AF00153630 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D0173063AF00153630 /* SBJsonParser.m */; };
+		22FC70FF173063AF00153630 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D2173063AF00153630 /* SBJsonStreamParser.m */; };
+		22FC7100173063AF00153630 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */; };
+		22FC7101173063AF00153630 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */; };
+		22FC7102173063AF00153630 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */; };
+		22FC7103173063AF00153630 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */; };
+		22FC7104173063AF00153630 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */; };
+		22FC7105173063AF00153630 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */; };
+		22FC7106173063AF00153630 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E0173063AF00153630 /* SBJsonTokeniser.m */; };
+		22FC7107173063AF00153630 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */; };
+		22FC7108173063AF00153630 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E4173063AF00153630 /* SBJsonWriter.m */; };
+		22FC7109173063AF00153630 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E6173063AF00153630 /* UGActivity.m */; };
+		22FC710A173063AF00153630 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70E8173063AF00153630 /* UGClient.m */; };
+		22FC710B173063AF00153630 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70EB173063AF00153630 /* UGClientResponse.m */; };
+		22FC710C173063AF00153630 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70ED173063AF00153630 /* UGHTTPManager.m */; };
+		22FC710D173063AF00153630 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70EF173063AF00153630 /* UGMultiStepAction.m */; };
+		22FC710E173063AF00153630 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F1173063AF00153630 /* UGQuery.m */; };
+		22FC710F173063AF00153630 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F3173063AF00153630 /* UGUser.m */; };
+		22FC7110173063AF00153630 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F6173063AF00153630 /* UGConnection.m */; };
+		22FC7111173063AF00153630 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70F8173063AF00153630 /* UGHTTPClient.m */; };
+		22FC7112173063AF00153630 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70FA173063AF00153630 /* UGHTTPHelpers.m */; };
+		22FC7113173063AF00153630 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC70FC173063AF00153630 /* UGHTTPResult.m */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+		22FC70981730595C00153630 /* browser.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = browser.app; sourceTree = BUILT_PRODUCTS_DIR; };
+		22FC709B1730595C00153630 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+		22FC709D1730595C00153630 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+		22FC709F1730595C00153630 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+		22FC70A31730595C00153630 /* browser-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "browser-Info.plist"; sourceTree = "<group>"; };
+		22FC70A51730595C00153630 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		22FC70A71730595C00153630 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+		22FC70A91730595C00153630 /* browser-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "browser-Prefix.pch"; sourceTree = "<group>"; };
+		22FC70AD1730595C00153630 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
+		22FC70AF1730595C00153630 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
+		22FC70B11730595C00153630 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
+		22FC70B81730639600153630 /* UGAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGAppDelegate.h; sourceTree = "<group>"; };
+		22FC70B91730639600153630 /* UGAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGAppDelegate.m; sourceTree = "<group>"; };
+		22FC70BA1730639600153630 /* UGAppViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGAppViewController.h; sourceTree = "<group>"; };
+		22FC70BB1730639600153630 /* UGAppViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGAppViewController.m; sourceTree = "<group>"; };
+		22FC70BC1730639600153630 /* UGCollectionViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGCollectionViewController.h; sourceTree = "<group>"; };
+		22FC70BD1730639600153630 /* UGCollectionViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGCollectionViewController.m; sourceTree = "<group>"; };
+		22FC70BE1730639600153630 /* UGEntityViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGEntityViewController.h; sourceTree = "<group>"; };
+		22FC70BF1730639600153630 /* UGEntityViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGEntityViewController.m; sourceTree = "<group>"; };
+		22FC70C01730639600153630 /* UGSignInViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGSignInViewController.h; sourceTree = "<group>"; };
+		22FC70C11730639600153630 /* UGSignInViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGSignInViewController.m; sourceTree = "<group>"; };
+		22FC70C21730639600153630 /* UGTextViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGTextViewController.h; sourceTree = "<group>"; };
+		22FC70C31730639600153630 /* UGTextViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGTextViewController.m; sourceTree = "<group>"; };
+		22FC70CC173063AF00153630 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
+		22FC70CD173063AF00153630 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
+		22FC70CE173063AF00153630 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
+		22FC70CF173063AF00153630 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
+		22FC70D0173063AF00153630 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
+		22FC70D1173063AF00153630 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
+		22FC70D2173063AF00153630 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
+		22FC70D3173063AF00153630 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
+		22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
+		22FC70D5173063AF00153630 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
+		22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
+		22FC70D7173063AF00153630 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
+		22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
+		22FC70D9173063AF00153630 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
+		22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
+		22FC70DB173063AF00153630 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
+		22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
+		22FC70DD173063AF00153630 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
+		22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
+		22FC70DF173063AF00153630 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
+		22FC70E0173063AF00153630 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
+		22FC70E1173063AF00153630 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
+		22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
+		22FC70E3173063AF00153630 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
+		22FC70E4173063AF00153630 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
+		22FC70E5173063AF00153630 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
+		22FC70E6173063AF00153630 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
+		22FC70E7173063AF00153630 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
+		22FC70E8173063AF00153630 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
+		22FC70E9173063AF00153630 /* UGClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
+		22FC70EA173063AF00153630 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
+		22FC70EB173063AF00153630 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
+		22FC70EC173063AF00153630 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
+		22FC70ED173063AF00153630 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
+		22FC70EE173063AF00153630 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
+		22FC70EF173063AF00153630 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
+		22FC70F0173063AF00153630 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
+		22FC70F1173063AF00153630 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
+		22FC70F2173063AF00153630 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
+		22FC70F3173063AF00153630 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
+		22FC70F5173063AF00153630 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
+		22FC70F6173063AF00153630 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
+		22FC70F7173063AF00153630 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
+		22FC70F8173063AF00153630 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
+		22FC70F9173063AF00153630 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
+		22FC70FA173063AF00153630 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
+		22FC70FB173063AF00153630 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
+		22FC70FC173063AF00153630 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+		22FC70951730595C00153630 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22FC709C1730595C00153630 /* UIKit.framework in Frameworks */,
+				22FC709E1730595C00153630 /* Foundation.framework in Frameworks */,
+				22FC70A01730595C00153630 /* CoreGraphics.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		22FC708F1730595C00153630 = {
+			isa = PBXGroup;
+			children = (
+				22FC70CA173063AF00153630 /* UGAPI */,
+				22FC70A11730595C00153630 /* browser */,
+				22FC709A1730595C00153630 /* Frameworks */,
+				22FC70991730595C00153630 /* Products */,
+			);
+			sourceTree = "<group>";
+		};
+		22FC70991730595C00153630 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70981730595C00153630 /* browser.app */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		22FC709A1730595C00153630 /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				22FC709B1730595C00153630 /* UIKit.framework */,
+				22FC709D1730595C00153630 /* Foundation.framework */,
+				22FC709F1730595C00153630 /* CoreGraphics.framework */,
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		22FC70A11730595C00153630 /* browser */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70B81730639600153630 /* UGAppDelegate.h */,
+				22FC70B91730639600153630 /* UGAppDelegate.m */,
+				22FC70BA1730639600153630 /* UGAppViewController.h */,
+				22FC70BB1730639600153630 /* UGAppViewController.m */,
+				22FC70BC1730639600153630 /* UGCollectionViewController.h */,
+				22FC70BD1730639600153630 /* UGCollectionViewController.m */,
+				22FC70BE1730639600153630 /* UGEntityViewController.h */,
+				22FC70BF1730639600153630 /* UGEntityViewController.m */,
+				22FC70C01730639600153630 /* UGSignInViewController.h */,
+				22FC70C11730639600153630 /* UGSignInViewController.m */,
+				22FC70C21730639600153630 /* UGTextViewController.h */,
+				22FC70C31730639600153630 /* UGTextViewController.m */,
+				22FC70A21730595C00153630 /* Supporting Files */,
+			);
+			path = browser;
+			sourceTree = "<group>";
+		};
+		22FC70A21730595C00153630 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70A31730595C00153630 /* browser-Info.plist */,
+				22FC70A41730595C00153630 /* InfoPlist.strings */,
+				22FC70A71730595C00153630 /* main.m */,
+				22FC70A91730595C00153630 /* browser-Prefix.pch */,
+				22FC70AD1730595C00153630 /* Default.png */,
+				22FC70AF1730595C00153630 /* Default@2x.png */,
+				22FC70B11730595C00153630 /* Default-568h@2x.png */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+		22FC70CA173063AF00153630 /* UGAPI */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70CB173063AF00153630 /* SBJson */,
+				22FC70E5173063AF00153630 /* UGActivity.h */,
+				22FC70E6173063AF00153630 /* UGActivity.m */,
+				22FC70E7173063AF00153630 /* UGClient.h */,
+				22FC70E8173063AF00153630 /* UGClient.m */,
+				22FC70E9173063AF00153630 /* UGClientDelegate.h */,
+				22FC70EA173063AF00153630 /* UGClientResponse.h */,
+				22FC70EB173063AF00153630 /* UGClientResponse.m */,
+				22FC70EC173063AF00153630 /* UGHTTPManager.h */,
+				22FC70ED173063AF00153630 /* UGHTTPManager.m */,
+				22FC70EE173063AF00153630 /* UGMultiStepAction.h */,
+				22FC70EF173063AF00153630 /* UGMultiStepAction.m */,
+				22FC70F0173063AF00153630 /* UGQuery.h */,
+				22FC70F1173063AF00153630 /* UGQuery.m */,
+				22FC70F2173063AF00153630 /* UGUser.h */,
+				22FC70F3173063AF00153630 /* UGUser.m */,
+				22FC70F4173063AF00153630 /* v2 */,
+			);
+			name = UGAPI;
+			path = ../../UGAPI;
+			sourceTree = "<group>";
+		};
+		22FC70CB173063AF00153630 /* SBJson */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70CC173063AF00153630 /* NSObject+SBJson.h */,
+				22FC70CD173063AF00153630 /* NSObject+SBJson.m */,
+				22FC70CE173063AF00153630 /* SBJson.h */,
+				22FC70CF173063AF00153630 /* SBJsonParser.h */,
+				22FC70D0173063AF00153630 /* SBJsonParser.m */,
+				22FC70D1173063AF00153630 /* SBJsonStreamParser.h */,
+				22FC70D2173063AF00153630 /* SBJsonStreamParser.m */,
+				22FC70D3173063AF00153630 /* SBJsonStreamParserAccumulator.h */,
+				22FC70D4173063AF00153630 /* SBJsonStreamParserAccumulator.m */,
+				22FC70D5173063AF00153630 /* SBJsonStreamParserAdapter.h */,
+				22FC70D6173063AF00153630 /* SBJsonStreamParserAdapter.m */,
+				22FC70D7173063AF00153630 /* SBJsonStreamParserState.h */,
+				22FC70D8173063AF00153630 /* SBJsonStreamParserState.m */,
+				22FC70D9173063AF00153630 /* SBJsonStreamWriter.h */,
+				22FC70DA173063AF00153630 /* SBJsonStreamWriter.m */,
+				22FC70DB173063AF00153630 /* SBJsonStreamWriterAccumulator.h */,
+				22FC70DC173063AF00153630 /* SBJsonStreamWriterAccumulator.m */,
+				22FC70DD173063AF00153630 /* SBJsonStreamWriterState.h */,
+				22FC70DE173063AF00153630 /* SBJsonStreamWriterState.m */,
+				22FC70DF173063AF00153630 /* SBJsonTokeniser.h */,
+				22FC70E0173063AF00153630 /* SBJsonTokeniser.m */,
+				22FC70E1173063AF00153630 /* SBJsonUTF8Stream.h */,
+				22FC70E2173063AF00153630 /* SBJsonUTF8Stream.m */,
+				22FC70E3173063AF00153630 /* SBJsonWriter.h */,
+				22FC70E4173063AF00153630 /* SBJsonWriter.m */,
+			);
+			path = SBJson;
+			sourceTree = "<group>";
+		};
+		22FC70F4173063AF00153630 /* v2 */ = {
+			isa = PBXGroup;
+			children = (
+				22FC70F5173063AF00153630 /* UGConnection.h */,
+				22FC70F6173063AF00153630 /* UGConnection.m */,
+				22FC70F7173063AF00153630 /* UGHTTPClient.h */,
+				22FC70F8173063AF00153630 /* UGHTTPClient.m */,
+				22FC70F9173063AF00153630 /* UGHTTPHelpers.h */,
+				22FC70FA173063AF00153630 /* UGHTTPHelpers.m */,
+				22FC70FB173063AF00153630 /* UGHTTPResult.h */,
+				22FC70FC173063AF00153630 /* UGHTTPResult.m */,
+			);
+			path = v2;
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		22FC70971730595C00153630 /* browser */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = 22FC70B51730595C00153630 /* Build configuration list for PBXNativeTarget "browser" */;
+			buildPhases = (
+				22FC70941730595C00153630 /* Sources */,
+				22FC70951730595C00153630 /* Frameworks */,
+				22FC70961730595C00153630 /* Resources */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = browser;
+			productName = browser;
+			productReference = 22FC70981730595C00153630 /* browser.app */;
+			productType = "com.apple.product-type.application";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		22FC70901730595C00153630 /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				LastUpgradeCheck = 0460;
+				ORGANIZATIONNAME = "Radtastical Inc.";
+			};
+			buildConfigurationList = 22FC70931730595C00153630 /* Build configuration list for PBXProject "browser" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = English;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+			);
+			mainGroup = 22FC708F1730595C00153630;
+			productRefGroup = 22FC70991730595C00153630 /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				22FC70971730595C00153630 /* browser */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		22FC70961730595C00153630 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22FC70A61730595C00153630 /* InfoPlist.strings in Resources */,
+				22FC70AE1730595C00153630 /* Default.png in Resources */,
+				22FC70B01730595C00153630 /* Default@2x.png in Resources */,
+				22FC70B21730595C00153630 /* Default-568h@2x.png in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		22FC70941730595C00153630 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22FC70A81730595C00153630 /* main.m in Sources */,
+				22FC70C41730639600153630 /* UGAppDelegate.m in Sources */,
+				22FC70C51730639600153630 /* UGAppViewController.m in Sources */,
+				22FC70C61730639600153630 /* UGCollectionViewController.m in Sources */,
+				22FC70C71730639600153630 /* UGEntityViewController.m in Sources */,
+				22FC70C81730639600153630 /* UGSignInViewController.m in Sources */,
+				22FC70C91730639600153630 /* UGTextViewController.m in Sources */,
+				22FC70FD173063AF00153630 /* NSObject+SBJson.m in Sources */,
+				22FC70FE173063AF00153630 /* SBJsonParser.m in Sources */,
+				22FC70FF173063AF00153630 /* SBJsonStreamParser.m in Sources */,
+				22FC7100173063AF00153630 /* SBJsonStreamParserAccumulator.m in Sources */,
+				22FC7101173063AF00153630 /* SBJsonStreamParserAdapter.m in Sources */,
+				22FC7102173063AF00153630 /* SBJsonStreamParserState.m in Sources */,
+				22FC7103173063AF00153630 /* SBJsonStreamWriter.m in Sources */,
+				22FC7104173063AF00153630 /* SBJsonStreamWriterAccumulator.m in Sources */,
+				22FC7105173063AF00153630 /* SBJsonStreamWriterState.m in Sources */,
+				22FC7106173063AF00153630 /* SBJsonTokeniser.m in Sources */,
+				22FC7107173063AF00153630 /* SBJsonUTF8Stream.m in Sources */,
+				22FC7108173063AF00153630 /* SBJsonWriter.m in Sources */,
+				22FC7109173063AF00153630 /* UGActivity.m in Sources */,
+				22FC710A173063AF00153630 /* UGClient.m in Sources */,
+				22FC710B173063AF00153630 /* UGClientResponse.m in Sources */,
+				22FC710C173063AF00153630 /* UGHTTPManager.m in Sources */,
+				22FC710D173063AF00153630 /* UGMultiStepAction.m in Sources */,
+				22FC710E173063AF00153630 /* UGQuery.m in Sources */,
+				22FC710F173063AF00153630 /* UGUser.m in Sources */,
+				22FC7110173063AF00153630 /* UGConnection.m in Sources */,
+				22FC7111173063AF00153630 /* UGHTTPClient.m in Sources */,
+				22FC7112173063AF00153630 /* UGHTTPHelpers.m in Sources */,
+				22FC7113173063AF00153630 /* UGHTTPResult.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+		22FC70A41730595C00153630 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				22FC70A51730595C00153630 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		22FC70B31730595C00153630 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"DEBUG=1",
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				ONLY_ACTIVE_ARCH = YES;
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+			};
+			name = Debug;
+		};
+		22FC70B41730595C00153630 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = YES;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		22FC70B61730595C00153630 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "browser/browser-Prefix.pch";
+				INFOPLIST_FILE = "browser/browser-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Debug;
+		};
+		22FC70B71730595C00153630 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "browser/browser-Prefix.pch";
+				INFOPLIST_FILE = "browser/browser-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		22FC70931730595C00153630 /* Build configuration list for PBXProject "browser" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				22FC70B31730595C00153630 /* Debug */,
+				22FC70B41730595C00153630 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		22FC70B51730595C00153630 /* Build configuration list for PBXNativeTarget "browser" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				22FC70B61730595C00153630 /* Debug */,
+				22FC70B71730595C00153630 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = 22FC70901730595C00153630 /* Project object */;
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/Default-568h@2x.png b/sdks/other/ios/samples/Browser/browser/Default-568h@2x.png
new file mode 100644
index 0000000..0891b7a
Binary files /dev/null and b/sdks/other/ios/samples/Browser/browser/Default-568h@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/Default.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/Default.png b/sdks/other/ios/samples/Browser/browser/Default.png
new file mode 100644
index 0000000..4c8ca6f
Binary files /dev/null and b/sdks/other/ios/samples/Browser/browser/Default.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/Default@2x.png b/sdks/other/ios/samples/Browser/browser/Default@2x.png
new file mode 100644
index 0000000..35b84cf
Binary files /dev/null and b/sdks/other/ios/samples/Browser/browser/Default@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGAppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGAppDelegate.h b/sdks/other/ios/samples/Browser/browser/UGAppDelegate.h
new file mode 100644
index 0000000..fb1453f
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGAppDelegate.h
@@ -0,0 +1,24 @@
+//
+//  UGAppDelegate.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@interface UGAppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGAppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGAppDelegate.m b/sdks/other/ios/samples/Browser/browser/UGAppDelegate.m
new file mode 100644
index 0000000..246a860
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGAppDelegate.m
@@ -0,0 +1,39 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGAppDelegate.m
+//  Browser
+//
+
+#import "UGAppDelegate.h"
+#import "UGAppViewController.h"
+
+@implementation UGAppDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
+    UINavigationController *navigationController = [[UINavigationController alloc]
+                                                    initWithRootViewController:[[UGAppViewController alloc] init]];
+    navigationController.navigationBar.tintColor = [UIColor darkGrayColor];
+    self.window.rootViewController = navigationController;
+    [self.window makeKeyAndVisible];
+    return YES;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGAppViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGAppViewController.h b/sdks/other/ios/samples/Browser/browser/UGAppViewController.h
new file mode 100644
index 0000000..7f26de9
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGAppViewController.h
@@ -0,0 +1,27 @@
+//
+//  UGAppViewController.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@interface UGAppViewController : UITableViewController
+@property (nonatomic, strong) NSDictionary *application;
+
+
+- (void) downloadApplicationDescription;
+
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGAppViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGAppViewController.m b/sdks/other/ios/samples/Browser/browser/UGAppViewController.m
new file mode 100644
index 0000000..b298fe1
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGAppViewController.m
@@ -0,0 +1,143 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGAppViewController.m
+//  Browser
+//
+
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+#import "UGConnection.h"
+#import "UGAppViewController.h"
+#import "UGSignInViewController.h"
+#import "UGCollectionViewController.h"
+
+@interface UGAppViewController ()
+
+@end
+
+@implementation UGAppViewController
+
+- (void) loadView
+{
+    [super loadView];
+    self.navigationItem.title = @"Usergrid";
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithTitle:@"Connection"
+                                             style:UIBarButtonItemStyleBordered
+                                             target:self
+                                             action:@selector(connect:)];
+}
+
+- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
+{
+    if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
+        return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
+    } else {
+        return YES;
+    }
+}
+
+- (void) connect:(id) sender
+{
+    UGSignInViewController *signinViewController = [[UGSignInViewController alloc] init];
+    signinViewController.appViewController = self;
+    UINavigationController *signinNavigationController =
+    [[UINavigationController alloc] initWithRootViewController:signinViewController];
+    signinNavigationController.modalPresentationStyle = UIModalPresentationFormSheet;
+    signinNavigationController.navigationBar.tintColor = self.navigationController.navigationBar.tintColor;
+    [self presentModalViewController:signinNavigationController animated:YES];
+}
+
+- (void) downloadApplicationDescription
+{
+    UGConnection *usergrid = [UGConnection sharedConnection];
+    [[[UGHTTPClient alloc]
+      initWithRequest:[usergrid getApplication:usergrid.application inOrganization:usergrid.organization]]
+     connectWithCompletionHandler:^(UGHTTPResult *result) {
+         self.application = result.object[@"entities"][0];
+         [self.tableView reloadData];
+     }];
+}
+
+- (NSInteger) numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return self.application ? 2 : 0;
+}
+
+- (NSInteger) tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    if (section == 0) {
+        return self.application ? 1 : 0;
+    } else if (section == 1) {
+        return self.application ? [self.application[@"metadata"][@"collections"] count] : 0;
+    } else {
+        return 0;
+    }
+}
+
+- (UITableViewCell *) tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
+    cell.backgroundColor = [UIColor whiteColor];
+    return cell;
+}
+
+- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if ([indexPath section] == 0) {
+        cell.textLabel.text = self.application[@"name"];
+        cell.accessoryType = UITableViewCellAccessoryNone;
+    } else {
+        NSDictionary *collections = self.application[@"metadata"][@"collections"];
+        NSString *key =  [[[collections allKeys] sortedArrayUsingSelector:@selector(compare:)] objectAtIndex:[indexPath row]];
+        NSDictionary *object = collections[key];
+        cell.textLabel.text = [NSString stringWithFormat:@"%@",
+                               object[@"title"]];
+        cell.detailTextLabel.text = [NSString stringWithFormat:@"name:%@ type:%@",
+                                     object[@"name"],
+                                     object[@"type"]];
+        cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
+    }
+    cell.backgroundColor = [UIColor whiteColor];
+    cell.selectionStyle = UITableViewCellSelectionStyleGray;
+}
+
+- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
+{
+    if (section == 0) {
+        return @"Application";
+    } else {
+        return @"Collections";
+    }
+}
+
+- (void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    [tableView deselectRowAtIndexPath:indexPath animated:YES];
+    if ([indexPath section] == 1) {
+        NSDictionary *collections = self.application[@"metadata"][@"collections"];
+        NSString *key =  [[[collections allKeys] sortedArrayUsingSelector:@selector(compare:)] objectAtIndex:[indexPath row]];
+        NSDictionary *collection = collections[key];
+        UGCollectionViewController *collectionViewController = [[UGCollectionViewController alloc] init];
+        collectionViewController.collection = collection;
+        [self.navigationController pushViewController:collectionViewController animated:YES];
+    }
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.h b/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.h
new file mode 100644
index 0000000..1b0074b
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.h
@@ -0,0 +1,23 @@
+//
+//  UGCollectionViewController.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@interface UGCollectionViewController : UITableViewController
+@property (nonatomic, strong) NSDictionary *collection;
+@property (nonatomic, strong) NSDictionary *collectionDetail;
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.m b/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.m
new file mode 100644
index 0000000..720bd09
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGCollectionViewController.m
@@ -0,0 +1,115 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGCollectionViewController.m
+//  Browser
+//
+
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+#import "UGConnection.h"
+#import "UGCollectionViewController.h"
+#import "UGEntityViewController.h"
+
+@interface UGCollectionViewController ()
+
+@end
+
+@implementation UGCollectionViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+    self = [super initWithStyle:style];
+    if (self) {
+        // Custom initialization
+    }
+    return self;
+}
+
+- (void) loadView
+{
+    [super loadView];
+}
+
+- (void)didReceiveMemoryWarning
+{
+    [super didReceiveMemoryWarning];
+    // Dispose of any resources that can be recreated.
+}
+
+- (void) getCollection
+{
+    [[[UGHTTPClient alloc] initWithRequest:[[UGConnection sharedConnection]
+                                            getEntitiesInCollection:self.collection[@"name"]
+                                            limit:200]]
+     connectWithCompletionHandler:^(UGHTTPResult *result) {
+         self.collectionDetail = result.object;
+         [self.tableView reloadData];
+         self.navigationItem.title = result.object[@"path"];
+     }];
+}
+
+- (void) viewWillAppear:(BOOL)animated
+{
+    [self getCollection];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    if (!self.collectionDetail) {
+        return 0;
+    } else {
+        return [self.collectionDetail[@"count"] intValue];
+    }
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
+    cell.textLabel.font = [UIFont boldSystemFontOfSize:14];
+    return cell;
+}
+
+- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    int row = [indexPath row];
+    NSDictionary *entity = self.collectionDetail[@"entities"][row];
+    cell.textLabel.text = entity[@"name"];
+    cell.detailTextLabel.text = entity[@"uuid"];
+}
+
+
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UGEntityViewController *entityViewController = [[UGEntityViewController alloc] init];
+    int row = [indexPath row];
+    entityViewController.entity = self.collectionDetail[@"entities"][row];
+    [self.navigationController pushViewController:entityViewController animated:YES];
+}
+
+@end


[31/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp.xcodeproj/project.pbxproj b/sdks/other/ios/UGAPIApp.xcodeproj/project.pbxproj
new file mode 100644
index 0000000..029a356
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp.xcodeproj/project.pbxproj
@@ -0,0 +1,653 @@
+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		22CA67241732087600C03C70 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22CA67231732087600C03C70 /* Default-568h@2x.png */; };
+		22D61E75171CBBF100E9CD17 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E6E171CBBF100E9CD17 /* UGConnection.m */; };
+		22D61E76171CBBF100E9CD17 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */; };
+		22D61E77171CBBF100E9CD17 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */; };
+		22D61E78171CBBF100E9CD17 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */; };
+		C96E782F1782349C004DD244 /* SSKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = C96E782E1782349C004DD244 /* SSKeychain.m */; };
+		C96E783717824711004DD244 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C96E783617824711004DD244 /* Security.framework */; };
+		E89D6CA1150E5B2E005F5FB9 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */; };
+		E89D6CA3150E5B2E005F5FB9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */; };
+		E89D6CA5150E5B2E005F5FB9 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */; };
+		E89D6CAB150E5B2E005F5FB9 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */; };
+		E89D6CAD150E5B2E005F5FB9 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CAC150E5B2E005F5FB9 /* main.m */; };
+		E89D6CB1150E5B2E005F5FB9 /* UGAppAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */; };
+		E89D6CB4150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */; };
+		E89D6CB7150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */; };
+		E89D6CBA150E5B2E005F5FB9 /* UGAppViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */; };
+		E89D6CC2150E5B2E005F5FB9 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */; };
+		E89D6CC3150E5B2E005F5FB9 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */; };
+		E89D6CC4150E5B2E005F5FB9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */; };
+		E89D6CCC150E5B2E005F5FB9 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */; };
+		E89D6CCF150E5B2E005F5FB9 /* UGAPIAppTests.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */; };
+		E89D6D05150E5B99005F5FB9 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */; };
+		E89D6D06150E5B99005F5FB9 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */; };
+		E89D6D07150E5B99005F5FB9 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */; };
+		E89D6D08150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */; };
+		E89D6D09150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */; };
+		E89D6D0A150E5B99005F5FB9 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */; };
+		E89D6D0B150E5B99005F5FB9 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */; };
+		E89D6D0C150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */; };
+		E89D6D0D150E5B99005F5FB9 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */; };
+		E89D6D0E150E5B99005F5FB9 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */; };
+		E89D6D0F150E5B99005F5FB9 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */; };
+		E89D6D10150E5B99005F5FB9 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */; };
+		E89D6D11150E5B99005F5FB9 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF8150E5B99005F5FB9 /* UGActivity.m */; };
+		E89D6D12150E5B99005F5FB9 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFA150E5B99005F5FB9 /* UGClient.m */; };
+		E89D6D13150E5B99005F5FB9 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */; };
+		E89D6D14150E5B99005F5FB9 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */; };
+		E89D6D15150E5B99005F5FB9 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */; };
+		E89D6D16150E5B99005F5FB9 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D02150E5B99005F5FB9 /* UGQuery.m */; };
+		E89D6D17150E5B99005F5FB9 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D04150E5B99005F5FB9 /* UGUser.m */; };
+		E89D6D19150E5C54005F5FB9 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXContainerItemProxy section */
+		E89D6CC5150E5B2E005F5FB9 /* PBXContainerItemProxy */ = {
+			isa = PBXContainerItemProxy;
+			containerPortal = E89D6C93150E5B2E005F5FB9 /* Project object */;
+			proxyType = 1;
+			remoteGlobalIDString = E89D6C9B150E5B2E005F5FB9;
+			remoteInfo = UGAPIApp;
+		};
+/* End PBXContainerItemProxy section */
+
+/* Begin PBXFileReference section */
+		22CA67231732087600C03C70 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
+		22D61E6D171CBBF100E9CD17 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
+		22D61E6E171CBBF100E9CD17 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
+		22D61E6F171CBBF100E9CD17 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
+		22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
+		22D61E71171CBBF100E9CD17 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
+		22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
+		22D61E73171CBBF100E9CD17 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
+		22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
+		638F675816EF875F002BD513 /* UGClientDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
+		C96E782D1782349C004DD244 /* SSKeychain.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSKeychain.h; sourceTree = "<group>"; };
+		C96E782E1782349C004DD244 /* SSKeychain.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSKeychain.m; sourceTree = "<group>"; };
+		C96E783617824711004DD244 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; };
+		E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = UGAPIApp.app; sourceTree = BUILT_PRODUCTS_DIR; };
+		E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+		E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+		E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+		E89D6CA8150E5B2E005F5FB9 /* UGAPIApp-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "UGAPIApp-Info.plist"; sourceTree = "<group>"; };
+		E89D6CAA150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		E89D6CAC150E5B2E005F5FB9 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+		E89D6CAE150E5B2E005F5FB9 /* UGAPIApp-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "UGAPIApp-Prefix.pch"; sourceTree = "<group>"; };
+		E89D6CAF150E5B2E005F5FB9 /* UGAppAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAppAppDelegate.h; sourceTree = "<group>"; };
+		E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAppAppDelegate.m; sourceTree = "<group>"; };
+		E89D6CB3150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPhone.storyboard; sourceTree = "<group>"; };
+		E89D6CB6150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPad.storyboard; sourceTree = "<group>"; };
+		E89D6CB8150E5B2E005F5FB9 /* UGAppViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAppViewController.h; sourceTree = "<group>"; };
+		E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAppViewController.m; sourceTree = "<group>"; };
+		E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = UGAPIAppTests.octest; sourceTree = BUILT_PRODUCTS_DIR; };
+		E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; };
+		E89D6CC9150E5B2E005F5FB9 /* UGAPIAppTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "UGAPIAppTests-Info.plist"; sourceTree = "<group>"; };
+		E89D6CCB150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		E89D6CCD150E5B2E005F5FB9 /* UGAPIAppTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAPIAppTests.h; sourceTree = "<group>"; };
+		E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAPIAppTests.m; sourceTree = "<group>"; };
+		E89D6CDE150E5B99005F5FB9 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
+		E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
+		E89D6CE0150E5B99005F5FB9 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
+		E89D6CE1150E5B99005F5FB9 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
+		E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
+		E89D6CE3150E5B99005F5FB9 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
+		E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
+		E89D6CE5150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
+		E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
+		E89D6CE7150E5B99005F5FB9 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
+		E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
+		E89D6CE9150E5B99005F5FB9 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
+		E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
+		E89D6CEB150E5B99005F5FB9 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
+		E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
+		E89D6CED150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
+		E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
+		E89D6CEF150E5B99005F5FB9 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
+		E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
+		E89D6CF1150E5B99005F5FB9 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
+		E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
+		E89D6CF3150E5B99005F5FB9 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
+		E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
+		E89D6CF5150E5B99005F5FB9 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
+		E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
+		E89D6CF7150E5B99005F5FB9 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
+		E89D6CF8150E5B99005F5FB9 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
+		E89D6CF9150E5B99005F5FB9 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
+		E89D6CFA150E5B99005F5FB9 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
+		E89D6CFB150E5B99005F5FB9 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
+		E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
+		E89D6CFD150E5B99005F5FB9 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
+		E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
+		E89D6CFF150E5B99005F5FB9 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
+		E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
+		E89D6D01150E5B99005F5FB9 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
+		E89D6D02150E5B99005F5FB9 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
+		E89D6D03150E5B99005F5FB9 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
+		E89D6D04150E5B99005F5FB9 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
+		E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+		E89D6C99150E5B2E005F5FB9 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				C96E783717824711004DD244 /* Security.framework in Frameworks */,
+				E89D6D19150E5C54005F5FB9 /* CoreLocation.framework in Frameworks */,
+				E89D6CA1150E5B2E005F5FB9 /* UIKit.framework in Frameworks */,
+				E89D6CA3150E5B2E005F5FB9 /* Foundation.framework in Frameworks */,
+				E89D6CA5150E5B2E005F5FB9 /* CoreGraphics.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+		E89D6CBC150E5B2E005F5FB9 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				E89D6CC2150E5B2E005F5FB9 /* SenTestingKit.framework in Frameworks */,
+				E89D6CC3150E5B2E005F5FB9 /* UIKit.framework in Frameworks */,
+				E89D6CC4150E5B2E005F5FB9 /* Foundation.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		22D61E6C171CBBF100E9CD17 /* v2 */ = {
+			isa = PBXGroup;
+			children = (
+				22D61E6D171CBBF100E9CD17 /* UGConnection.h */,
+				22D61E6E171CBBF100E9CD17 /* UGConnection.m */,
+				22D61E6F171CBBF100E9CD17 /* UGHTTPClient.h */,
+				22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */,
+				22D61E71171CBBF100E9CD17 /* UGHTTPHelpers.h */,
+				22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */,
+				22D61E73171CBBF100E9CD17 /* UGHTTPResult.h */,
+				22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */,
+			);
+			path = v2;
+			sourceTree = "<group>";
+		};
+		C96E782917821C9D004DD244 /* SSKeychain */ = {
+			isa = PBXGroup;
+			children = (
+				C96E782D1782349C004DD244 /* SSKeychain.h */,
+				C96E782E1782349C004DD244 /* SSKeychain.m */,
+			);
+			name = SSKeychain;
+			sourceTree = "<group>";
+		};
+		E89D6C91150E5B2E005F5FB9 = {
+			isa = PBXGroup;
+			children = (
+				C96E783617824711004DD244 /* Security.framework */,
+				22CA67231732087600C03C70 /* Default-568h@2x.png */,
+				E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */,
+				E89D6CDC150E5B99005F5FB9 /* UGAPI */,
+				E89D6CA6150E5B2E005F5FB9 /* UGAPIApp */,
+				E89D6CC7150E5B2E005F5FB9 /* UGAPIAppTests */,
+				E89D6C9F150E5B2E005F5FB9 /* Frameworks */,
+				E89D6C9D150E5B2E005F5FB9 /* Products */,
+			);
+			sourceTree = "<group>";
+		};
+		E89D6C9D150E5B2E005F5FB9 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */,
+				E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		E89D6C9F150E5B2E005F5FB9 /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */,
+				E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */,
+				E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */,
+				E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */,
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		E89D6CA6150E5B2E005F5FB9 /* UGAPIApp */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CAF150E5B2E005F5FB9 /* UGAppAppDelegate.h */,
+				E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */,
+				E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */,
+				E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */,
+				E89D6CB8150E5B2E005F5FB9 /* UGAppViewController.h */,
+				E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */,
+				E89D6CA7150E5B2E005F5FB9 /* Supporting Files */,
+			);
+			path = UGAPIApp;
+			sourceTree = "<group>";
+		};
+		E89D6CA7150E5B2E005F5FB9 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CA8150E5B2E005F5FB9 /* UGAPIApp-Info.plist */,
+				E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */,
+				E89D6CAC150E5B2E005F5FB9 /* main.m */,
+				E89D6CAE150E5B2E005F5FB9 /* UGAPIApp-Prefix.pch */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+		E89D6CC7150E5B2E005F5FB9 /* UGAPIAppTests */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CCD150E5B2E005F5FB9 /* UGAPIAppTests.h */,
+				E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */,
+				E89D6CC8150E5B2E005F5FB9 /* Supporting Files */,
+			);
+			path = UGAPIAppTests;
+			sourceTree = "<group>";
+		};
+		E89D6CC8150E5B2E005F5FB9 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CC9150E5B2E005F5FB9 /* UGAPIAppTests-Info.plist */,
+				E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+		E89D6CDC150E5B99005F5FB9 /* UGAPI */ = {
+			isa = PBXGroup;
+			children = (
+				C96E782917821C9D004DD244 /* SSKeychain */,
+				22D61E6C171CBBF100E9CD17 /* v2 */,
+				E89D6CDD150E5B99005F5FB9 /* SBJson */,
+				E89D6CF7150E5B99005F5FB9 /* UGActivity.h */,
+				E89D6CF8150E5B99005F5FB9 /* UGActivity.m */,
+				E89D6CF9150E5B99005F5FB9 /* UGClient.h */,
+				E89D6CFA150E5B99005F5FB9 /* UGClient.m */,
+				E89D6CFB150E5B99005F5FB9 /* UGClientResponse.h */,
+				E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */,
+				E89D6CFD150E5B99005F5FB9 /* UGHTTPManager.h */,
+				E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */,
+				E89D6CFF150E5B99005F5FB9 /* UGMultiStepAction.h */,
+				E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */,
+				E89D6D01150E5B99005F5FB9 /* UGQuery.h */,
+				E89D6D02150E5B99005F5FB9 /* UGQuery.m */,
+				E89D6D03150E5B99005F5FB9 /* UGUser.h */,
+				E89D6D04150E5B99005F5FB9 /* UGUser.m */,
+				638F675816EF875F002BD513 /* UGClientDelegate.h */,
+			);
+			path = UGAPI;
+			sourceTree = "<group>";
+		};
+		E89D6CDD150E5B99005F5FB9 /* SBJson */ = {
+			isa = PBXGroup;
+			children = (
+				E89D6CDE150E5B99005F5FB9 /* NSObject+SBJson.h */,
+				E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */,
+				E89D6CE0150E5B99005F5FB9 /* SBJson.h */,
+				E89D6CE1150E5B99005F5FB9 /* SBJsonParser.h */,
+				E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */,
+				E89D6CE3150E5B99005F5FB9 /* SBJsonStreamParser.h */,
+				E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */,
+				E89D6CE5150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.h */,
+				E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */,
+				E89D6CE7150E5B99005F5FB9 /* SBJsonStreamParserAdapter.h */,
+				E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */,
+				E89D6CE9150E5B99005F5FB9 /* SBJsonStreamParserState.h */,
+				E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */,
+				E89D6CEB150E5B99005F5FB9 /* SBJsonStreamWriter.h */,
+				E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */,
+				E89D6CED150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.h */,
+				E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */,
+				E89D6CEF150E5B99005F5FB9 /* SBJsonStreamWriterState.h */,
+				E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */,
+				E89D6CF1150E5B99005F5FB9 /* SBJsonTokeniser.h */,
+				E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */,
+				E89D6CF3150E5B99005F5FB9 /* SBJsonUTF8Stream.h */,
+				E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */,
+				E89D6CF5150E5B99005F5FB9 /* SBJsonWriter.h */,
+				E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */,
+			);
+			path = SBJson;
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = E89D6CD2150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIApp" */;
+			buildPhases = (
+				E89D6C98150E5B2E005F5FB9 /* Sources */,
+				E89D6C99150E5B2E005F5FB9 /* Frameworks */,
+				E89D6C9A150E5B2E005F5FB9 /* Resources */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = UGAPIApp;
+			productName = UGAPIApp;
+			productReference = E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */;
+			productType = "com.apple.product-type.application";
+		};
+		E89D6CBF150E5B2E005F5FB9 /* UGAPIAppTests */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = E89D6CD5150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIAppTests" */;
+			buildPhases = (
+				E89D6CBB150E5B2E005F5FB9 /* Sources */,
+				E89D6CBC150E5B2E005F5FB9 /* Frameworks */,
+				E89D6CBD150E5B2E005F5FB9 /* Resources */,
+				E89D6CBE150E5B2E005F5FB9 /* ShellScript */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+				E89D6CC6150E5B2E005F5FB9 /* PBXTargetDependency */,
+			);
+			name = UGAPIAppTests;
+			productName = UGAPIAppTests;
+			productReference = E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */;
+			productType = "com.apple.product-type.bundle";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		E89D6C93150E5B2E005F5FB9 /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				CLASSPREFIX = UGApp;
+				LastUpgradeCheck = 0430;
+			};
+			buildConfigurationList = E89D6C96150E5B2E005F5FB9 /* Build configuration list for PBXProject "UGAPIApp" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = English;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+			);
+			mainGroup = E89D6C91150E5B2E005F5FB9;
+			productRefGroup = E89D6C9D150E5B2E005F5FB9 /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */,
+				E89D6CBF150E5B2E005F5FB9 /* UGAPIAppTests */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		E89D6C9A150E5B2E005F5FB9 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				E89D6CAB150E5B2E005F5FB9 /* InfoPlist.strings in Resources */,
+				E89D6CB4150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard in Resources */,
+				E89D6CB7150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard in Resources */,
+				22CA67241732087600C03C70 /* Default-568h@2x.png in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+		E89D6CBD150E5B2E005F5FB9 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				E89D6CCC150E5B2E005F5FB9 /* InfoPlist.strings in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXShellScriptBuildPhase section */
+		E89D6CBE150E5B2E005F5FB9 /* ShellScript */ = {
+			isa = PBXShellScriptBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+			);
+			inputPaths = (
+			);
+			outputPaths = (
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+			shellPath = /bin/sh;
+			shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n";
+		};
+/* End PBXShellScriptBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		E89D6C98150E5B2E005F5FB9 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				E89D6CAD150E5B2E005F5FB9 /* main.m in Sources */,
+				E89D6CB1150E5B2E005F5FB9 /* UGAppAppDelegate.m in Sources */,
+				E89D6CBA150E5B2E005F5FB9 /* UGAppViewController.m in Sources */,
+				E89D6D05150E5B99005F5FB9 /* NSObject+SBJson.m in Sources */,
+				E89D6D06150E5B99005F5FB9 /* SBJsonParser.m in Sources */,
+				E89D6D07150E5B99005F5FB9 /* SBJsonStreamParser.m in Sources */,
+				E89D6D08150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m in Sources */,
+				E89D6D09150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m in Sources */,
+				E89D6D0A150E5B99005F5FB9 /* SBJsonStreamParserState.m in Sources */,
+				E89D6D0B150E5B99005F5FB9 /* SBJsonStreamWriter.m in Sources */,
+				E89D6D0C150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m in Sources */,
+				E89D6D0D150E5B99005F5FB9 /* SBJsonStreamWriterState.m in Sources */,
+				E89D6D0E150E5B99005F5FB9 /* SBJsonTokeniser.m in Sources */,
+				E89D6D0F150E5B99005F5FB9 /* SBJsonUTF8Stream.m in Sources */,
+				E89D6D10150E5B99005F5FB9 /* SBJsonWriter.m in Sources */,
+				E89D6D11150E5B99005F5FB9 /* UGActivity.m in Sources */,
+				E89D6D12150E5B99005F5FB9 /* UGClient.m in Sources */,
+				E89D6D13150E5B99005F5FB9 /* UGClientResponse.m in Sources */,
+				E89D6D14150E5B99005F5FB9 /* UGHTTPManager.m in Sources */,
+				E89D6D15150E5B99005F5FB9 /* UGMultiStepAction.m in Sources */,
+				E89D6D16150E5B99005F5FB9 /* UGQuery.m in Sources */,
+				E89D6D17150E5B99005F5FB9 /* UGUser.m in Sources */,
+				22D61E75171CBBF100E9CD17 /* UGConnection.m in Sources */,
+				22D61E76171CBBF100E9CD17 /* UGHTTPClient.m in Sources */,
+				22D61E77171CBBF100E9CD17 /* UGHTTPHelpers.m in Sources */,
+				22D61E78171CBBF100E9CD17 /* UGHTTPResult.m in Sources */,
+				C96E782F1782349C004DD244 /* SSKeychain.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+		E89D6CBB150E5B2E005F5FB9 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				E89D6CCF150E5B2E005F5FB9 /* UGAPIAppTests.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXTargetDependency section */
+		E89D6CC6150E5B2E005F5FB9 /* PBXTargetDependency */ = {
+			isa = PBXTargetDependency;
+			target = E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */;
+			targetProxy = E89D6CC5150E5B2E005F5FB9 /* PBXContainerItemProxy */;
+		};
+/* End PBXTargetDependency section */
+
+/* Begin PBXVariantGroup section */
+		E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				E89D6CAA150E5B2E005F5FB9 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+		E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */ = {
+			isa = PBXVariantGroup;
+			children = (
+				E89D6CB3150E5B2E005F5FB9 /* en */,
+			);
+			name = MainStoryboard_iPhone.storyboard;
+			sourceTree = "<group>";
+		};
+		E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */ = {
+			isa = PBXVariantGroup;
+			children = (
+				E89D6CB6150E5B2E005F5FB9 /* en */,
+			);
+			name = MainStoryboard_iPad.storyboard;
+			sourceTree = "<group>";
+		};
+		E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				E89D6CCB150E5B2E005F5FB9 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		E89D6CD0150E5B2E005F5FB9 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"DEBUG=1",
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+			};
+			name = Debug;
+		};
+		E89D6CD1150E5B2E005F5FB9 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = YES;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
+				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		E89D6CD3150E5B2E005F5FB9 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
+				INFOPLIST_FILE = "UGAPIApp/UGAPIApp-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Debug;
+		};
+		E89D6CD4150E5B2E005F5FB9 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
+				INFOPLIST_FILE = "UGAPIApp/UGAPIApp-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Release;
+		};
+		E89D6CD6150E5B2E005F5FB9 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/UGAPIApp.app/UGAPIApp";
+				FRAMEWORK_SEARCH_PATHS = (
+					"$(SDKROOT)/Developer/Library/Frameworks",
+					"$(DEVELOPER_LIBRARY_DIR)/Frameworks",
+				);
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
+				INFOPLIST_FILE = "UGAPIAppTests/UGAPIAppTests-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				TEST_HOST = "$(BUNDLE_LOADER)";
+				WRAPPER_EXTENSION = octest;
+			};
+			name = Debug;
+		};
+		E89D6CD7150E5B2E005F5FB9 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/UGAPIApp.app/UGAPIApp";
+				FRAMEWORK_SEARCH_PATHS = (
+					"$(SDKROOT)/Developer/Library/Frameworks",
+					"$(DEVELOPER_LIBRARY_DIR)/Frameworks",
+				);
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
+				INFOPLIST_FILE = "UGAPIAppTests/UGAPIAppTests-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				TEST_HOST = "$(BUNDLE_LOADER)";
+				WRAPPER_EXTENSION = octest;
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		E89D6C96150E5B2E005F5FB9 /* Build configuration list for PBXProject "UGAPIApp" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				E89D6CD0150E5B2E005F5FB9 /* Debug */,
+				E89D6CD1150E5B2E005F5FB9 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		E89D6CD2150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIApp" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				E89D6CD3150E5B2E005F5FB9 /* Debug */,
+				E89D6CD4150E5B2E005F5FB9 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		E89D6CD5150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIAppTests" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				E89D6CD6150E5B2E005F5FB9 /* Debug */,
+				E89D6CD7150E5B2E005F5FB9 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = E89D6C93150E5B2E005F5FB9 /* Project object */;
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/sdks/other/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
new file mode 100644
index 0000000..3092016
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<Workspace
+   version = "1.0">
+   <FileRef
+      location = "self:UGAPIApp.xcodeproj">
+   </FileRef>
+</Workspace>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAPIApp-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAPIApp-Info.plist b/sdks/other/ios/UGAPIApp/UGAPIApp-Info.plist
new file mode 100644
index 0000000..45143c7
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAPIApp-Info.plist
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.apigee.usergrid.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIMainStoryboardFile</key>
+	<string>MainStoryboard_iPhone</string>
+	<key>UIMainStoryboardFile~ipad</key>
+	<string>MainStoryboard_iPad</string>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAPIApp-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAPIApp-Prefix.pch b/sdks/other/ios/UGAPIApp/UGAPIApp-Prefix.pch
new file mode 100644
index 0000000..b497ab1
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAPIApp-Prefix.pch
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+//
+// Prefix header for all source files of the 'UGAPIApp' target in the 'UGAPIApp' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_5_0
+#warning "This project uses features only available in iOS SDK 5.0 and later."
+#endif
+
+#ifdef __OBJC__
+    #import <UIKit/UIKit.h>
+    #import <Foundation/Foundation.h>
+#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAppAppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAppAppDelegate.h b/sdks/other/ios/UGAPIApp/UGAppAppDelegate.h
new file mode 100644
index 0000000..15c3ced
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAppAppDelegate.h
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <UIKit/UIKit.h>
+@class UGHTTPManager;
+
+@interface UGAppAppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAppAppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAppAppDelegate.m b/sdks/other/ios/UGAPIApp/UGAppAppDelegate.m
new file mode 100644
index 0000000..2e7d6de
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAppAppDelegate.m
@@ -0,0 +1,139 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGAppAppDelegate.h"
+#import "UGHTTPManager.h"
+#import "SBJson.h"
+#import "UGClient.h"
+#import "UGClientResponse.h"
+
+UGClient *g_client = nil;
+int g_taps = 0;
+
+@implementation UGAppAppDelegate
+
+@synthesize window = _window;
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+    // Override point for customization after application launch.
+    return YES;
+}
+							
+- (void)applicationWillResignActive:(UIApplication *)application
+{
+    // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
+    // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
+}
+
+- (void)applicationDidEnterBackground:(UIApplication *)application
+{
+    // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 
+    // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
+}
+
+- (void)applicationWillEnterForeground:(UIApplication *)application
+{
+    // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
+}
+
+- (void)applicationDidBecomeActive:(UIApplication *)application
+{
+    // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
+}
+
+- (void)applicationWillTerminate:(UIApplication *)application
+{
+    // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
+}
+
+-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
+{
+    // called when there's a touch.
+    [self testUGClient];
+}
+
+-(void)testUGClient
+{
+    // creation and init
+    if ( !g_client )
+    {
+        g_client =[[UGClient alloc] initWithOrganizationId:@"1hotrod" withApplicationID:@"fred" ];
+    }
+    
+    UGClientResponse *response = nil;
+    response = [g_client logInUser:@"alice" password:@"test1test"];
+    if ( [response transactionState] == kUGClientResponseFailure )
+    {
+        [self outputResponse:response title:@"LOG IN ERROR"];
+        return;
+    }
+    
+    CLLocation *fakeLocation = [[CLLocation alloc] initWithLatitude:37.776753 longitude:-122.407846];
+    
+    UGQuery *query = [UGQuery new];
+    [query addRequiredWithinLocation:@"location" location:fakeLocation distance:2000];
+    
+    response = [g_client getUsers:query];
+    [self outputResponse:response title:@"getUsers Response"];
+}
+
+-(void)ugClientResponse:(UGClientResponse *)response
+{
+    // note the results
+    [self outputResponse:response title:@"Asynch Response"];
+}
+
+-(void)outputResponse:(UGClientResponse *)response title:(NSString *)title
+{
+    NSLog(@"-----%@-----", title);
+    if ( !response )
+    {
+        NSLog(@"Response is nil");
+        NSLog(@"------------------");
+        return;
+    }
+    
+    
+    if ( [response transactionState] == kUGClientResponseSuccess )
+    {
+        NSLog(@"state: SUCCESS");
+        NSLog(@"id: %d", [response transactionID]);
+        NSLog(@"raw:\n%@", [response rawResponse]);
+    }
+    else if ( [response transactionState] == kUGClientResponsePending )
+    {
+        NSLog(@"state: PENDING");
+        NSLog(@"id: %d", [response transactionID]);
+    }
+    else if ( [response transactionState] == kUGClientResponseFailure )
+    {
+        NSLog(@"state: FAILURE");
+        NSLog(@"id: %d", [response transactionID]);
+        NSLog(@"reason: '%@'", [response response]);
+        NSLog(@"raw:\n%@", [response rawResponse]);
+    }
+    else 
+    {
+        NSLog(@"Object is mangled or invalid.");
+    }
+    NSLog(@"------------------");
+}
+
+
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAppViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAppViewController.h b/sdks/other/ios/UGAPIApp/UGAppViewController.h
new file mode 100644
index 0000000..9846c31
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAppViewController.h
@@ -0,0 +1,22 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <UIKit/UIKit.h>
+
+@interface UGAppViewController : UIViewController
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/UGAppViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/UGAppViewController.m b/sdks/other/ios/UGAPIApp/UGAppViewController.m
new file mode 100644
index 0000000..b7c5424
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/UGAppViewController.m
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGAppViewController.h"
+
+@interface UGAppViewController ()
+
+@end
+
+@implementation UGAppViewController
+
+- (void)viewDidLoad
+{
+    [super viewDidLoad];
+	// Do any additional setup after loading the view, typically from a nib.
+}
+
+- (void)viewDidUnload
+{
+    [super viewDidUnload];
+    // Release any retained subviews of the main view.
+}
+
+- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
+{
+    if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
+        return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
+    } else {
+        return YES;
+    }
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/en.lproj/InfoPlist.strings b/sdks/other/ios/UGAPIApp/en.lproj/InfoPlist.strings
new file mode 100644
index 0000000..477b28f
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/en.lproj/InfoPlist.strings
@@ -0,0 +1,2 @@
+/* Localized versions of Info.plist keys */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard b/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
new file mode 100644
index 0000000..447df68
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="1.0" toolsVersion="1906" systemVersion="11A511" targetRuntime="iOS.CocoaTouch.iPad" nextObjectID="6" propertyAccessControl="none" initialViewController="2">
+    <dependencies>
+        <development defaultVersion="4200" identifier="xcode"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="902"/>
+    </dependencies>
+    <scenes>
+        <scene sceneID="4">
+            <objects>
+                <placeholder placeholderIdentifier="IBFirstResponder" id="3" sceneMemberID="firstResponder"/>
+                <viewController id="2" customClass="UGAppViewController" sceneMemberID="viewController">
+                    <view key="view" contentMode="scaleToFill" id="5">
+                        <rect key="frame" x="0.0" y="20" width="768" height="1004"/>
+                        <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+                        <subviews/>
+                        <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
+                    </view>
+                </viewController>
+            </objects>
+        </scene>
+    </scenes>
+    <simulatedMetricsContainer key="defaultSimulatedMetrics">
+        <simulatedStatusBarMetrics key="statusBar" statusBarStyle="blackTranslucent"/>
+        <simulatedOrientationMetrics key="orientation"/>
+        <simulatedScreenMetrics key="destination"/>
+    </simulatedMetricsContainer>
+</document>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard b/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
new file mode 100644
index 0000000..92b0831
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="1.0" toolsVersion="1906" systemVersion="11A511" targetRuntime="iOS.CocoaTouch" nextObjectID="6" propertyAccessControl="none" initialViewController="2">
+    <dependencies>
+        <development defaultVersion="4200" identifier="xcode"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="902"/>
+    </dependencies>
+    <scenes>
+        <scene sceneID="5">
+            <objects>
+                <placeholder placeholderIdentifier="IBFirstResponder" id="4" sceneMemberID="firstResponder"/>
+                <viewController id="2" customClass="UGAppViewController" sceneMemberID="viewController">
+                    <view key="view" contentMode="scaleToFill" id="3">
+                        <rect key="frame" x="0.0" y="20" width="320" height="460"/>
+                        <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+                        <subviews/>
+                        <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
+                    </view>
+                </viewController>
+            </objects>
+        </scene>
+    </scenes>
+    <simulatedMetricsContainer key="defaultSimulatedMetrics">
+        <simulatedStatusBarMetrics key="statusBar"/>
+        <simulatedOrientationMetrics key="orientation"/>
+        <simulatedScreenMetrics key="destination"/>
+    </simulatedMetricsContainer>
+</document>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIApp/main.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIApp/main.m b/sdks/other/ios/UGAPIApp/main.m
new file mode 100644
index 0000000..f547811
--- /dev/null
+++ b/sdks/other/ios/UGAPIApp/main.m
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <UIKit/UIKit.h>
+
+#import "UGAppAppDelegate.h"
+
+int main(int argc, char *argv[])
+{
+    @autoreleasepool {
+        return UIApplicationMain(argc, argv, nil, NSStringFromClass([UGAppAppDelegate class]));
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIAppTests/UGAPIAppTests-Info.plist b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
new file mode 100644
index 0000000..94b9921
--- /dev/null
+++ b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.apigee.usergrid.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundlePackageType</key>
+	<string>BNDL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1</string>
+</dict>
+</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.h b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.h
new file mode 100644
index 0000000..abaf125
--- /dev/null
+++ b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.h
@@ -0,0 +1,22 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <SenTestingKit/SenTestingKit.h>
+
+@interface UGAPIAppTests : SenTestCase
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.m b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.m
new file mode 100644
index 0000000..0cda4c0
--- /dev/null
+++ b/sdks/other/ios/UGAPIAppTests/UGAPIAppTests.m
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGAPIAppTests.h"
+
+@implementation UGAPIAppTests
+
+- (void)setUp
+{
+    [super setUp];
+    
+    // Set-up code here.
+}
+
+- (void)tearDown
+{
+    // Tear-down code here.
+    
+    [super tearDown];
+}
+
+- (void)testExample
+{
+    STFail(@"Unit tests are not implemented yet in UGAPIAppTests");
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPIAppTests/en.lproj/InfoPlist.strings b/sdks/other/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
new file mode 100644
index 0000000..477b28f
--- /dev/null
+++ b/sdks/other/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
@@ -0,0 +1,2 @@
+/* Localized versions of Info.plist keys */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/changelog.md
----------------------------------------------------------------------
diff --git a/sdks/other/ios/changelog.md b/sdks/other/ios/changelog.md
new file mode 100644
index 0000000..88d0b1f
--- /dev/null
+++ b/sdks/other/ios/changelog.md
@@ -0,0 +1,11 @@
+##Change log
+
+
+###0.9.2
+
+- Added Facebook login
+
+
+###0.9.1
+
+- Fixed several bugs
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books.xcodeproj/project.pbxproj b/sdks/other/ios/samples/Books/books.xcodeproj/project.pbxproj
new file mode 100644
index 0000000..3db9841
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books.xcodeproj/project.pbxproj
@@ -0,0 +1,342 @@
+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		224EA246170F6F63002B136A /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA23F170F6F63002B136A /* UGConnection.m */; };
+		224EA247170F6F63002B136A /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA241170F6F63002B136A /* UGHTTPClient.m */; };
+		224EA248170F6F63002B136A /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA243170F6F63002B136A /* UGHTTPHelpers.m */; };
+		224EA249170F6F63002B136A /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA245170F6F63002B136A /* UGHTTPResult.m */; };
+		227AE09F170DF424004F6E20 /* UGSignInViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 227AE09E170DF424004F6E20 /* UGSignInViewController.m */; };
+		227AE0A2170E01CF004F6E20 /* AddBookViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 227AE0A1170E01CF004F6E20 /* AddBookViewController.m */; };
+		228ADD73170DE2ED0030F962 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD72170DE2ED0030F962 /* UIKit.framework */; };
+		228ADD75170DE2ED0030F962 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD74170DE2ED0030F962 /* Foundation.framework */; };
+		228ADD77170DE2ED0030F962 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD76170DE2ED0030F962 /* CoreGraphics.framework */; };
+		228ADD7D170DE2ED0030F962 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD7B170DE2ED0030F962 /* InfoPlist.strings */; };
+		228ADD7F170DE2ED0030F962 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD7E170DE2ED0030F962 /* main.m */; };
+		228ADD83170DE2ED0030F962 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD82170DE2ED0030F962 /* AppDelegate.m */; };
+		228ADD85170DE2ED0030F962 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD84170DE2ED0030F962 /* Default.png */; };
+		228ADD87170DE2ED0030F962 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD86170DE2ED0030F962 /* Default@2x.png */; };
+		228ADD89170DE2ED0030F962 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD88170DE2ED0030F962 /* Default-568h@2x.png */; };
+		228ADD91170DE3170030F962 /* BooksViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD90170DE3170030F962 /* BooksViewController.m */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+		224EA23E170F6F63002B136A /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
+		224EA23F170F6F63002B136A /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
+		224EA240170F6F63002B136A /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
+		224EA241170F6F63002B136A /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
+		224EA242170F6F63002B136A /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
+		224EA243170F6F63002B136A /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
+		224EA244170F6F63002B136A /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
+		224EA245170F6F63002B136A /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
+		227AE09D170DF424004F6E20 /* UGSignInViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGSignInViewController.h; sourceTree = "<group>"; };
+		227AE09E170DF424004F6E20 /* UGSignInViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGSignInViewController.m; sourceTree = "<group>"; };
+		227AE0A0170E01CF004F6E20 /* AddBookViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AddBookViewController.h; sourceTree = "<group>"; };
+		227AE0A1170E01CF004F6E20 /* AddBookViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AddBookViewController.m; sourceTree = "<group>"; };
+		228ADD6F170DE2ED0030F962 /* books.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = books.app; sourceTree = BUILT_PRODUCTS_DIR; };
+		228ADD72170DE2ED0030F962 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+		228ADD74170DE2ED0030F962 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+		228ADD76170DE2ED0030F962 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+		228ADD7A170DE2ED0030F962 /* books-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "books-Info.plist"; sourceTree = "<group>"; };
+		228ADD7C170DE2ED0030F962 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		228ADD7E170DE2ED0030F962 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+		228ADD80170DE2ED0030F962 /* books-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "books-Prefix.pch"; sourceTree = "<group>"; };
+		228ADD81170DE2ED0030F962 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
+		228ADD82170DE2ED0030F962 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
+		228ADD84170DE2ED0030F962 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
+		228ADD86170DE2ED0030F962 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
+		228ADD88170DE2ED0030F962 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
+		228ADD8F170DE3170030F962 /* BooksViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BooksViewController.h; sourceTree = "<group>"; };
+		228ADD90170DE3170030F962 /* BooksViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BooksViewController.m; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+		228ADD6C170DE2ED0030F962 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				228ADD73170DE2ED0030F962 /* UIKit.framework in Frameworks */,
+				228ADD75170DE2ED0030F962 /* Foundation.framework in Frameworks */,
+				228ADD77170DE2ED0030F962 /* CoreGraphics.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		224EA23D170F6F63002B136A /* UGAPI */ = {
+			isa = PBXGroup;
+			children = (
+				224EA23E170F6F63002B136A /* UGConnection.h */,
+				224EA23F170F6F63002B136A /* UGConnection.m */,
+				224EA240170F6F63002B136A /* UGHTTPClient.h */,
+				224EA241170F6F63002B136A /* UGHTTPClient.m */,
+				224EA242170F6F63002B136A /* UGHTTPHelpers.h */,
+				224EA243170F6F63002B136A /* UGHTTPHelpers.m */,
+				224EA244170F6F63002B136A /* UGHTTPResult.h */,
+				224EA245170F6F63002B136A /* UGHTTPResult.m */,
+			);
+			name = UGAPI;
+			path = ../../UGAPI/v2;
+			sourceTree = "<group>";
+		};
+		228ADD66170DE2ED0030F962 = {
+			isa = PBXGroup;
+			children = (
+				224EA23D170F6F63002B136A /* UGAPI */,
+				228ADD78170DE2ED0030F962 /* books */,
+				228ADD79170DE2ED0030F962 /* Supporting Files */,
+				228ADD71170DE2ED0030F962 /* Frameworks */,
+				228ADD70170DE2ED0030F962 /* Products */,
+			);
+			sourceTree = "<group>";
+		};
+		228ADD70170DE2ED0030F962 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				228ADD6F170DE2ED0030F962 /* books.app */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		228ADD71170DE2ED0030F962 /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				228ADD72170DE2ED0030F962 /* UIKit.framework */,
+				228ADD74170DE2ED0030F962 /* Foundation.framework */,
+				228ADD76170DE2ED0030F962 /* CoreGraphics.framework */,
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		228ADD78170DE2ED0030F962 /* books */ = {
+			isa = PBXGroup;
+			children = (
+				228ADD81170DE2ED0030F962 /* AppDelegate.h */,
+				228ADD82170DE2ED0030F962 /* AppDelegate.m */,
+				228ADD8F170DE3170030F962 /* BooksViewController.h */,
+				228ADD90170DE3170030F962 /* BooksViewController.m */,
+				227AE09D170DF424004F6E20 /* UGSignInViewController.h */,
+				227AE09E170DF424004F6E20 /* UGSignInViewController.m */,
+				227AE0A0170E01CF004F6E20 /* AddBookViewController.h */,
+				227AE0A1170E01CF004F6E20 /* AddBookViewController.m */,
+			);
+			path = books;
+			sourceTree = "<group>";
+		};
+		228ADD79170DE2ED0030F962 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				228ADD7A170DE2ED0030F962 /* books-Info.plist */,
+				228ADD7B170DE2ED0030F962 /* InfoPlist.strings */,
+				228ADD7E170DE2ED0030F962 /* main.m */,
+				228ADD80170DE2ED0030F962 /* books-Prefix.pch */,
+				228ADD84170DE2ED0030F962 /* Default.png */,
+				228ADD86170DE2ED0030F962 /* Default@2x.png */,
+				228ADD88170DE2ED0030F962 /* Default-568h@2x.png */,
+			);
+			name = "Supporting Files";
+			path = books;
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		228ADD6E170DE2ED0030F962 /* books */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = 228ADD8C170DE2ED0030F962 /* Build configuration list for PBXNativeTarget "books" */;
+			buildPhases = (
+				228ADD6B170DE2ED0030F962 /* Sources */,
+				228ADD6C170DE2ED0030F962 /* Frameworks */,
+				228ADD6D170DE2ED0030F962 /* Resources */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = books;
+			productName = books;
+			productReference = 228ADD6F170DE2ED0030F962 /* books.app */;
+			productType = "com.apple.product-type.application";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		228ADD67170DE2ED0030F962 /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				LastUpgradeCheck = 0460;
+				ORGANIZATIONNAME = Radtastical;
+			};
+			buildConfigurationList = 228ADD6A170DE2ED0030F962 /* Build configuration list for PBXProject "books" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = English;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+			);
+			mainGroup = 228ADD66170DE2ED0030F962;
+			productRefGroup = 228ADD70170DE2ED0030F962 /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				228ADD6E170DE2ED0030F962 /* books */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		228ADD6D170DE2ED0030F962 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				228ADD7D170DE2ED0030F962 /* InfoPlist.strings in Resources */,
+				228ADD85170DE2ED0030F962 /* Default.png in Resources */,
+				228ADD87170DE2ED0030F962 /* Default@2x.png in Resources */,
+				228ADD89170DE2ED0030F962 /* Default-568h@2x.png in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		228ADD6B170DE2ED0030F962 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				228ADD7F170DE2ED0030F962 /* main.m in Sources */,
+				228ADD83170DE2ED0030F962 /* AppDelegate.m in Sources */,
+				228ADD91170DE3170030F962 /* BooksViewController.m in Sources */,
+				227AE09F170DF424004F6E20 /* UGSignInViewController.m in Sources */,
+				227AE0A2170E01CF004F6E20 /* AddBookViewController.m in Sources */,
+				224EA246170F6F63002B136A /* UGConnection.m in Sources */,
+				224EA247170F6F63002B136A /* UGHTTPClient.m in Sources */,
+				224EA248170F6F63002B136A /* UGHTTPHelpers.m in Sources */,
+				224EA249170F6F63002B136A /* UGHTTPResult.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+		228ADD7B170DE2ED0030F962 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				228ADD7C170DE2ED0030F962 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		228ADD8A170DE2ED0030F962 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"DEBUG=1",
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				ONLY_ACTIVE_ARCH = YES;
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+			};
+			name = Debug;
+		};
+		228ADD8B170DE2ED0030F962 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = YES;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		228ADD8D170DE2ED0030F962 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "books/books-Prefix.pch";
+				INFOPLIST_FILE = "books/books-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Debug;
+		};
+		228ADD8E170DE2ED0030F962 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "books/books-Prefix.pch";
+				INFOPLIST_FILE = "books/books-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		228ADD6A170DE2ED0030F962 /* Build configuration list for PBXProject "books" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				228ADD8A170DE2ED0030F962 /* Debug */,
+				228ADD8B170DE2ED0030F962 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		228ADD8C170DE2ED0030F962 /* Build configuration list for PBXNativeTarget "books" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				228ADD8D170DE2ED0030F962 /* Debug */,
+				228ADD8E170DE2ED0030F962 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = 228ADD67170DE2ED0030F962 /* Project object */;
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Books/books/AddBookViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Books/books/AddBookViewController.h b/sdks/other/ios/samples/Books/books/AddBookViewController.h
new file mode 100644
index 0000000..d9aaeb7
--- /dev/null
+++ b/sdks/other/ios/samples/Books/books/AddBookViewController.h
@@ -0,0 +1,41 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  AddBookViewController.h
+//  books
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface AddBookViewController : UITableViewController
+
+@end


[34/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
new file mode 100755
index 0000000..90d442a
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
@@ -0,0 +1,69 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+@class SBJsonStreamWriter;
+
+@interface SBJsonStreamWriterState : NSObject
++ (id)sharedInstance;
+- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer;
+- (void)appendSeparator:(SBJsonStreamWriter*)writer;
+- (BOOL)expectingKey:(SBJsonStreamWriter*)writer;
+- (void)transitionState:(SBJsonStreamWriter*)writer;
+- (void)appendWhitespace:(SBJsonStreamWriter*)writer;
+@end
+
+@interface SBJsonStreamWriterStateObjectStart : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateObjectKey : SBJsonStreamWriterStateObjectStart
+@end
+
+@interface SBJsonStreamWriterStateObjectValue : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateArrayStart : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateArrayValue : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateStart : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateComplete : SBJsonStreamWriterState
+@end
+
+@interface SBJsonStreamWriterStateError : SBJsonStreamWriterState
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
new file mode 100755
index 0000000..9f04cac
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
@@ -0,0 +1,139 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamWriterState.h"
+#import "SBJsonStreamWriter.h"
+
+#define SINGLETON \
++ (id)sharedInstance { \
+    static id state; \
+    if (!state) state = [[self alloc] init]; \
+    return state; \
+}
+
+
+@implementation SBJsonStreamWriterState
++ (id)sharedInstance { return nil; }
+- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer { return NO; }
+- (void)appendSeparator:(SBJsonStreamWriter*)writer {}
+- (BOOL)expectingKey:(SBJsonStreamWriter*)writer { return NO; }
+- (void)transitionState:(SBJsonStreamWriter *)writer {}
+- (void)appendWhitespace:(SBJsonStreamWriter*)writer {
+	[writer appendBytes:"\n" length:1];
+	for (NSUInteger i = 0; i < writer.stateStack.count; i++)
+	    [writer appendBytes:"  " length:2];
+}
+@end
+
+@implementation SBJsonStreamWriterStateObjectStart
+
+SINGLETON
+
+- (void)transitionState:(SBJsonStreamWriter *)writer {
+	writer.state = [SBJsonStreamWriterStateObjectValue sharedInstance];
+}
+- (BOOL)expectingKey:(SBJsonStreamWriter *)writer {
+	writer.error = @"JSON object key must be string";
+	return YES;
+}
+@end
+
+@implementation SBJsonStreamWriterStateObjectKey
+
+SINGLETON
+
+- (void)appendSeparator:(SBJsonStreamWriter *)writer {
+	[writer appendBytes:"," length:1];
+}
+@end
+
+@implementation SBJsonStreamWriterStateObjectValue
+
+SINGLETON
+
+- (void)appendSeparator:(SBJsonStreamWriter *)writer {
+	[writer appendBytes:":" length:1];
+}
+- (void)transitionState:(SBJsonStreamWriter *)writer {
+    writer.state = [SBJsonStreamWriterStateObjectKey sharedInstance];
+}
+- (void)appendWhitespace:(SBJsonStreamWriter *)writer {
+	[writer appendBytes:" " length:1];
+}
+@end
+
+@implementation SBJsonStreamWriterStateArrayStart
+
+SINGLETON
+
+- (void)transitionState:(SBJsonStreamWriter *)writer {
+    writer.state = [SBJsonStreamWriterStateArrayValue sharedInstance];
+}
+@end
+
+@implementation SBJsonStreamWriterStateArrayValue
+
+SINGLETON
+
+- (void)appendSeparator:(SBJsonStreamWriter *)writer {
+	[writer appendBytes:"," length:1];
+}
+@end
+
+@implementation SBJsonStreamWriterStateStart
+
+SINGLETON
+
+
+- (void)transitionState:(SBJsonStreamWriter *)writer {
+    writer.state = [SBJsonStreamWriterStateComplete sharedInstance];
+}
+- (void)appendSeparator:(SBJsonStreamWriter *)writer {
+}
+@end
+
+@implementation SBJsonStreamWriterStateComplete
+
+SINGLETON
+
+- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer {
+	writer.error = @"Stream is closed";
+	return YES;
+}
+@end
+
+@implementation SBJsonStreamWriterStateError
+
+SINGLETON
+
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.h b/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.h
new file mode 100755
index 0000000..e484a94
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.h
@@ -0,0 +1,67 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+ Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 
+ Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ 
+ Neither the name of the the author nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+typedef enum {
+    sbjson_token_error = -1,
+    sbjson_token_eof,
+    
+    sbjson_token_array_start,
+    sbjson_token_array_end,
+    
+    sbjson_token_object_start,
+    sbjson_token_object_end,
+
+    sbjson_token_separator,
+    sbjson_token_keyval_separator,
+    
+    sbjson_token_number,
+    sbjson_token_string,
+    sbjson_token_true,
+    sbjson_token_false,
+    sbjson_token_null,
+    
+} sbjson_token_t;
+
+@class SBJsonUTF8Stream;
+
+@interface SBJsonTokeniser : NSObject 
+
+@property (strong) SBJsonUTF8Stream *stream;
+@property (copy) NSString *error;
+
+- (void)appendData:(NSData*)data_;
+
+- (sbjson_token_t)getToken:(NSObject**)token;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.m b/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.m
new file mode 100755
index 0000000..75d3268
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.m
@@ -0,0 +1,453 @@
+/*
+ Copyright (c) 2010-2011, Stig Brautaset. All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+
+ Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+
+ Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ Neither the name of the the author nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonTokeniser.h"
+#import "SBJsonUTF8Stream.h"
+
+#define SBStringIsIllegalSurrogateHighCharacter(character) (((character) >= 0xD800UL) && ((character) <= 0xDFFFUL))
+#define SBStringIsSurrogateLowCharacter(character) ((character >= 0xDC00UL) && (character <= 0xDFFFUL))
+#define SBStringIsSurrogateHighCharacter(character) ((character >= 0xD800UL) && (character <= 0xDBFFUL))
+
+@implementation SBJsonTokeniser
+
+@synthesize error = _error;
+@synthesize stream = _stream;
+
+- (id)init {
+    self = [super init];
+    if (self) {
+        _stream = [[SBJsonUTF8Stream alloc] init];
+
+    }
+
+    return self;
+}
+
+
+- (void)appendData:(NSData *)data_ {
+    [_stream appendData:data_];
+}
+
+
+- (sbjson_token_t)match:(const char *)pattern length:(NSUInteger)len retval:(sbjson_token_t)token {
+    if (![_stream haveRemainingCharacters:len])
+        return sbjson_token_eof;
+
+    if ([_stream skipCharacters:pattern length:len])
+        return token;
+
+    self.error = [NSString stringWithFormat:@"Expected '%s' after initial '%.1s'", pattern, pattern];
+    return sbjson_token_error;
+}
+
+- (BOOL)decodeEscape:(unichar)ch into:(unichar*)decoded {
+    switch (ch) {
+        case '\\':
+        case '/':
+        case '"':
+            *decoded = ch;
+            break;
+
+        case 'b':
+            *decoded = '\b';
+            break;
+
+        case 'n':
+            *decoded = '\n';
+            break;
+
+        case 'r':
+            *decoded = '\r';
+            break;
+
+        case 't':
+            *decoded = '\t';
+            break;
+
+        case 'f':
+            *decoded = '\f';
+            break;
+
+        default:
+            self.error = @"Illegal escape character";
+            return NO;
+            break;
+    }
+    return YES;
+}
+
+- (BOOL)decodeHexQuad:(unichar*)quad {
+    unichar c, tmp = 0;
+
+    for (int i = 0; i < 4; i++) {
+        (void)[_stream getNextUnichar:&c];
+        tmp *= 16;
+        switch (c) {
+            case '0' ... '9':
+                tmp += c - '0';
+                break;
+
+            case 'a' ... 'f':
+                tmp += 10 + c - 'a';
+                break;
+
+            case 'A' ... 'F':
+                tmp += 10 + c - 'A';
+                break;
+
+            default:
+                return NO;
+        }
+    }
+    *quad = tmp;
+    return YES;
+}
+
+- (sbjson_token_t)getStringToken:(NSObject**)token {
+    NSMutableString *acc = nil;
+
+    for (;;) {
+        [_stream skip];
+        
+        unichar ch;
+        {
+            NSMutableString *string = nil;
+            
+            if (![_stream getStringFragment:&string])
+                return sbjson_token_eof;
+            
+            if (!string) {
+                self.error = @"Broken Unicode encoding";
+                return sbjson_token_error;
+            }
+            
+            if (![_stream getUnichar:&ch])
+                return sbjson_token_eof;
+            
+            if (acc) {
+                [acc appendString:string];
+                
+            } else if (ch == '"') {
+                *token = [string copy];
+                [_stream skip];
+                return sbjson_token_string;
+                
+            } else {
+                acc = [string mutableCopy];
+            }
+        }
+
+        
+        switch (ch) {
+            case 0 ... 0x1F:
+                self.error = [NSString stringWithFormat:@"Unescaped control character [0x%0.2X]", (int)ch];
+                return sbjson_token_error;
+                break;
+
+            case '"':
+                *token = acc;
+                [_stream skip];
+                return sbjson_token_string;
+                break;
+
+            case '\\':
+                if (![_stream getNextUnichar:&ch])
+                    return sbjson_token_eof;
+
+                if (ch == 'u') {
+                    if (![_stream haveRemainingCharacters:5])
+                        return sbjson_token_eof;
+
+                    unichar hi;
+                    if (![self decodeHexQuad:&hi]) {
+                        self.error = @"Invalid hex quad";
+                        return sbjson_token_error;
+                    }
+
+                    if (SBStringIsSurrogateHighCharacter(hi)) {
+                        unichar lo;
+
+                        if (![_stream haveRemainingCharacters:6])
+                            return sbjson_token_eof;
+
+                        (void)[_stream getNextUnichar:&ch];
+                        (void)[_stream getNextUnichar:&lo];
+                        if (ch != '\\' || lo != 'u' || ![self decodeHexQuad:&lo]) {
+                            self.error = @"Missing low character in surrogate pair";
+                            return sbjson_token_error;
+                        }
+
+                        if (!SBStringIsSurrogateLowCharacter(lo)) {
+                            self.error = @"Invalid low character in surrogate pair";
+                            return sbjson_token_error;
+                        }
+
+                        [acc appendFormat:@"%C%C", hi, lo];
+                    } else if (SBStringIsIllegalSurrogateHighCharacter(hi)) {
+                        self.error = @"Invalid high character in surrogate pair";
+                        return sbjson_token_error;
+                    } else {
+                        [acc appendFormat:@"%C", hi];
+                    }
+
+
+                } else {
+                    unichar decoded;
+                    if (![self decodeEscape:ch into:&decoded])
+                        return sbjson_token_error;
+                    [acc appendFormat:@"%C", decoded];
+                }
+
+                break;
+
+            default: {
+                self.error = [NSString stringWithFormat:@"Invalid UTF-8: '%x'", (int)ch];
+                return sbjson_token_error;
+                break;
+            }
+        }
+    }
+    return sbjson_token_eof;
+}
+
+- (sbjson_token_t)getNumberToken:(NSObject**)token {
+
+    NSUInteger numberStart = _stream.index;
+    NSCharacterSet *digits = [NSCharacterSet decimalDigitCharacterSet];
+
+    unichar ch;
+    if (![_stream getUnichar:&ch])
+        return sbjson_token_eof;
+
+    BOOL isNegative = NO;
+    if (ch == '-') {
+        isNegative = YES;
+        if (![_stream getNextUnichar:&ch])
+            return sbjson_token_eof;
+    }
+
+    unsigned long long mantissa = 0;
+    int mantissa_length = 0;
+    
+    if (ch == '0') {
+        mantissa_length++;
+        if (![_stream getNextUnichar:&ch])
+            return sbjson_token_eof;
+
+        if ([digits characterIsMember:ch]) {
+            self.error = @"Leading zero is illegal in number";
+            return sbjson_token_error;
+        }
+    }
+
+    while ([digits characterIsMember:ch]) {
+        mantissa *= 10;
+        mantissa += (ch - '0');
+        mantissa_length++;
+
+        if (![_stream getNextUnichar:&ch])
+            return sbjson_token_eof;
+    }
+
+    short exponent = 0;
+    BOOL isFloat = NO;
+
+    if (ch == '.') {
+        isFloat = YES;
+        if (![_stream getNextUnichar:&ch])
+            return sbjson_token_eof;
+
+        while ([digits characterIsMember:ch]) {
+            mantissa *= 10;
+            mantissa += (ch - '0');
+            mantissa_length++;
+            exponent--;
+
+            if (![_stream getNextUnichar:&ch])
+                return sbjson_token_eof;
+        }
+
+        if (!exponent) {
+            self.error = @"No digits after decimal point";
+            return sbjson_token_error;
+        }
+    }
+
+    BOOL hasExponent = NO;
+    if (ch == 'e' || ch == 'E') {
+        hasExponent = YES;
+
+        if (![_stream getNextUnichar:&ch])
+            return sbjson_token_eof;
+
+        BOOL expIsNegative = NO;
+        if (ch == '-') {
+            expIsNegative = YES;
+            if (![_stream getNextUnichar:&ch])
+                return sbjson_token_eof;
+
+        } else if (ch == '+') {
+            if (![_stream getNextUnichar:&ch])
+                return sbjson_token_eof;
+        }
+
+        short explicit_exponent = 0;
+        short explicit_exponent_length = 0;
+        while ([digits characterIsMember:ch]) {
+            explicit_exponent *= 10;
+            explicit_exponent += (ch - '0');
+            explicit_exponent_length++;
+
+            if (![_stream getNextUnichar:&ch])
+                return sbjson_token_eof;
+        }
+
+        if (explicit_exponent_length == 0) {
+            self.error = @"No digits in exponent";
+            return sbjson_token_error;
+        }
+
+        if (expIsNegative)
+            exponent -= explicit_exponent;
+        else
+            exponent += explicit_exponent;
+    }
+
+    if (!mantissa_length && isNegative) {
+        self.error = @"No digits after initial minus";
+        return sbjson_token_error;
+
+    } else if (mantissa_length >= 19) {
+        
+        NSString *number = [_stream stringWithRange:NSMakeRange(numberStart, _stream.index - numberStart)];
+        *token = [NSDecimalNumber decimalNumberWithString:number];
+
+    } else if (!isFloat && !hasExponent) {
+        if (!isNegative)
+            *token = [NSNumber numberWithUnsignedLongLong:mantissa];
+        else
+            *token = [NSNumber numberWithLongLong:-mantissa];
+    } else {
+        *token = [NSDecimalNumber decimalNumberWithMantissa:mantissa
+                                                   exponent:exponent
+                                                 isNegative:isNegative];
+    }
+
+    return sbjson_token_number;
+}
+
+- (sbjson_token_t)getToken:(NSObject **)token {
+
+    [_stream skipWhitespace];
+
+    unichar ch;
+    if (![_stream getUnichar:&ch])
+        return sbjson_token_eof;
+
+    NSUInteger oldIndexLocation = _stream.index;
+    sbjson_token_t tok;
+
+    switch (ch) {
+        case '[':
+            tok = sbjson_token_array_start;
+            [_stream skip];
+            break;
+
+        case ']':
+            tok = sbjson_token_array_end;
+            [_stream skip];
+            break;
+
+        case '{':
+            tok = sbjson_token_object_start;
+            [_stream skip];
+            break;
+
+        case ':':
+            tok = sbjson_token_keyval_separator;
+            [_stream skip];
+            break;
+
+        case '}':
+            tok = sbjson_token_object_end;
+            [_stream skip];
+            break;
+
+        case ',':
+            tok = sbjson_token_separator;
+            [_stream skip];
+            break;
+
+        case 'n':
+            tok = [self match:"null" length:4 retval:sbjson_token_null];
+            break;
+
+        case 't':
+            tok = [self match:"true" length:4 retval:sbjson_token_true];
+            break;
+
+        case 'f':
+            tok = [self match:"false" length:5 retval:sbjson_token_false];
+            break;
+
+        case '"':
+            tok = [self getStringToken:token];
+            break;
+
+        case '0' ... '9':
+        case '-':
+            tok = [self getNumberToken:token];
+            break;
+
+        case '+':
+            self.error = @"Leading + is illegal in number";
+            tok = sbjson_token_error;
+            break;
+
+        default:
+            self.error = [NSString stringWithFormat:@"Illegal start of token [%c]", ch];
+            tok = sbjson_token_error;
+            break;
+    }
+
+    if (tok == sbjson_token_eof) {
+        // We ran out of bytes in the middle of a token.
+        // We don't know how to restart in mid-flight, so
+        // rewind to the start of the token for next attempt.
+        // Hopefully we'll have more data then.
+        _stream.index = oldIndexLocation;
+    }
+
+    return tok;
+}
+
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.h b/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
new file mode 100755
index 0000000..a26f032
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
@@ -0,0 +1,58 @@
+/*
+ Copyright (c) 2011, Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+ Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 
+ Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ 
+ Neither the name of the the author nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+
+@interface SBJsonUTF8Stream : NSObject {
+@private
+    const char *_bytes;
+    NSMutableData *_data;
+    NSUInteger _length;
+}
+
+@property (assign) NSUInteger index;
+
+- (void)appendData:(NSData*)data_;
+
+- (BOOL)haveRemainingCharacters:(NSUInteger)chars;
+
+- (void)skip;
+- (void)skipWhitespace;
+- (BOOL)skipCharacters:(const char *)chars length:(NSUInteger)len;
+
+- (BOOL)getUnichar:(unichar*)ch;
+- (BOOL)getNextUnichar:(unichar*)ch;
+- (BOOL)getStringFragment:(NSString**)string;
+
+- (NSString*)stringWithRange:(NSRange)range;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.m b/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
new file mode 100755
index 0000000..f57015d
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
@@ -0,0 +1,141 @@
+/*
+ Copyright (c) 2011, Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+ Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 
+ Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+ 
+ Neither the name of the the author nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonUTF8Stream.h"
+
+
+@implementation SBJsonUTF8Stream
+
+@synthesize index = _index;
+
+- (id)init {
+    self = [super init];
+    if (self) {
+        _data = [[NSMutableData alloc] initWithCapacity:4096u];
+    }
+    return self;
+}
+
+
+- (void)appendData:(NSData *)data_ {
+    
+    if (_index) {
+        // Discard data we've already parsed
+		[_data replaceBytesInRange:NSMakeRange(0, _index) withBytes:"" length:0];
+        
+        // Reset index to point to current position
+		_index = 0;
+	}
+    
+    [_data appendData:data_];
+    
+    // This is an optimisation. 
+    _bytes = (const char*)[_data bytes];
+    _length = [_data length];
+}
+
+
+- (BOOL)getUnichar:(unichar*)ch {
+    if (_index < _length) {
+        *ch = (unichar)_bytes[_index];
+        return YES;
+    }
+    return NO;
+}
+
+- (BOOL)getNextUnichar:(unichar*)ch {
+    if (++_index < _length) {
+        *ch = (unichar)_bytes[_index];
+        return YES;
+    }
+    return NO;
+}
+
+- (BOOL)getStringFragment:(NSString **)string {
+    NSUInteger start = _index;
+    while (_index < _length) {
+        switch (_bytes[_index]) {
+            case '"':
+            case '\\':
+            case 0 ... 0x1f:
+                *string = [[NSString alloc] initWithBytes:(_bytes + start)
+                                                   length:(_index - start)
+                                                 encoding:NSUTF8StringEncoding];
+                return YES;
+                break;
+            default:
+                _index++;
+                break;
+        }
+    }
+    return NO;
+}
+
+- (void)skip {
+    _index++;
+}
+
+- (void)skipWhitespace {
+    while (_index < _length) {
+        switch (_bytes[_index]) {
+            case ' ':
+            case '\t':
+            case '\r':
+            case '\n':
+                _index++;
+                break;
+            default:
+                return;
+                break;
+        }
+    }
+}
+
+- (BOOL)haveRemainingCharacters:(NSUInteger)chars {
+    return [_data length] - _index >= chars;
+}
+
+- (BOOL)skipCharacters:(const char *)chars length:(NSUInteger)len {
+    const void *bytes = ((const char*)[_data bytes]) + _index;
+    if (!memcmp(bytes, chars, len)) {
+        _index += len;
+        return YES;
+    }
+    return NO;
+}
+
+- (NSString*)stringWithRange:(NSRange)range {
+    return [[NSString alloc] initWithBytes:_bytes + range.location length:range.length encoding:NSUTF8StringEncoding];
+    
+}
+
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.h b/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.h
new file mode 100755
index 0000000..640816c
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.h
@@ -0,0 +1,117 @@
+/*
+ Copyright (C) 2009 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+/**
+ @brief The JSON writer class.
+ 
+ This uses SBJsonStreamWriter internally.
+ 
+ @see @ref json2objc
+ */
+
+@interface SBJsonWriter : NSObject
+
+/**
+ @brief The maximum recursing depth.
+ 
+ Defaults to 32. If the input is nested deeper than this the input will be deemed to be
+ malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
+ turn off this security feature by setting the maxDepth value to 0.
+ */
+@property NSUInteger maxDepth;
+
+/**
+ @brief Return an error trace, or nil if there was no errors.
+ 
+ Note that this method returns the trace of the last method that failed.
+ You need to check the return value of the call you're making to figure out
+ if the call actually failed, before you know call this method.
+ */
+@property (readonly, copy) NSString *error;
+
+/**
+ @brief Whether we are generating human-readable (multiline) JSON.
+ 
+ Set whether or not to generate human-readable JSON. The default is NO, which produces
+ JSON without any whitespace. (Except inside strings.) If set to YES, generates human-readable
+ JSON with linebreaks after each array value and dictionary key/value pair, indented two
+ spaces per nesting level.
+ */
+@property BOOL humanReadable;
+
+/**
+ @brief Whether or not to sort the dictionary keys in the output.
+ 
+ If this is set to YES, the dictionary keys in the JSON output will be in sorted order.
+ (This is useful if you need to compare two structures, for example.) The default is NO.
+ */
+@property BOOL sortKeys;
+
+/**
+ @brief An optional comparator to be used if sortKeys is YES.
+ 
+ If this is nil, sorting will be done via @selector(compare:).
+ */
+@property (copy) NSComparator sortKeysComparator;
+
+/**
+ @brief Return JSON representation for the given object.
+ 
+ Returns a string containing JSON representation of the passed in value, or nil on error.
+ If nil is returned and @p error is not NULL, @p *error can be interrogated to find the cause of the error.
+ 
+ @param value any instance that can be represented as JSON text.
+ */
+- (NSString*)stringWithObject:(id)value;
+
+/**
+ @brief Return JSON representation for the given object.
+ 
+ Returns an NSData object containing JSON represented as UTF8 text, or nil on error.
+ 
+ @param value any instance that can be represented as JSON text.
+ */
+- (NSData*)dataWithObject:(id)value;
+
+/**
+ @brief Return JSON representation (or fragment) for the given object.
+ 
+ Returns a string containing JSON representation of the passed in value, or nil on error.
+ If nil is returned and @p error is not NULL, @p *error can be interrogated to find the cause of the error.
+ 
+ @param value any instance that can be represented as a JSON fragment
+ @param error pointer to object to be populated with NSError on failure
+ 
+ */- (NSString*)stringWithObject:(id)value
+                           error:(NSError**)error;
+
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.m b/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.m
new file mode 100755
index 0000000..d200f9c
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonWriter.m
@@ -0,0 +1,112 @@
+/*
+ Copyright (C) 2009 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonWriter.h"
+#import "SBJsonStreamWriter.h"
+#import "SBJsonStreamWriterAccumulator.h"
+
+
+@interface SBJsonWriter ()
+@property (copy) NSString *error;
+@end
+
+@implementation SBJsonWriter
+
+@synthesize sortKeys;
+@synthesize humanReadable;
+
+@synthesize error;
+@synthesize maxDepth;
+
+@synthesize sortKeysComparator;
+
+- (id)init {
+    self = [super init];
+    if (self) {
+        self.maxDepth = 32u;        
+    }
+    return self;
+}
+
+
+- (NSString*)stringWithObject:(id)value {
+	NSData *data = [self dataWithObject:value];
+	if (data)
+		return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
+	return nil;
+}	
+
+- (NSString*)stringWithObject:(id)value error:(NSError**)error_ {
+    NSString *tmp = [self stringWithObject:value];
+    if (tmp)
+        return tmp;
+    
+    if (error_) {
+		NSDictionary *ui = [NSDictionary dictionaryWithObjectsAndKeys:error, NSLocalizedDescriptionKey, nil];
+        *error_ = [NSError errorWithDomain:@"org.brautaset.SBJsonWriter.ErrorDomain" code:0 userInfo:ui];
+	}
+	
+    return nil;
+}
+
+- (NSData*)dataWithObject:(id)object {	
+    self.error = nil;
+
+    SBJsonStreamWriterAccumulator *accumulator = [[SBJsonStreamWriterAccumulator alloc] init];
+    
+	SBJsonStreamWriter *streamWriter = [[SBJsonStreamWriter alloc] init];
+	streamWriter.sortKeys = self.sortKeys;
+	streamWriter.maxDepth = self.maxDepth;
+	streamWriter.sortKeysComparator = self.sortKeysComparator;
+	streamWriter.humanReadable = self.humanReadable;
+    streamWriter.delegate = accumulator;
+	
+	BOOL ok = NO;
+	if ([object isKindOfClass:[NSDictionary class]])
+		ok = [streamWriter writeObject:object];
+	
+	else if ([object isKindOfClass:[NSArray class]])
+		ok = [streamWriter writeArray:object];
+		
+	else if ([object respondsToSelector:@selector(proxyForJson)])
+		return [self dataWithObject:[object proxyForJson]];
+	else {
+		self.error = @"Not valid type for JSON";
+		return nil;
+	}
+	
+	if (ok)
+		return accumulator.data;
+	
+	self.error = streamWriter.error;
+	return nil;	
+}
+	
+	
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SSKeychain.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SSKeychain.h b/sdks/other/ios/UGAPI/SSKeychain.h
new file mode 100644
index 0000000..23093b6
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SSKeychain.h
@@ -0,0 +1,357 @@
+//
+//  SSKeychain.h
+//  SSToolkit
+//
+//  Created by Sam Soffes on 5/19/10.
+//  Copyright (c) 2009-2011 Sam Soffes. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import <Security/Security.h>
+
+/** Error codes that can be returned in NSError objects. */
+typedef enum {
+	/** No error. */
+	SSKeychainErrorNone = noErr,
+	
+	/** Some of the arguments were invalid. */
+	SSKeychainErrorBadArguments = -1001,
+	
+	/** There was no password. */
+	SSKeychainErrorNoPassword = -1002,
+	
+	/** One or more parameters passed internally were not valid. */
+	SSKeychainErrorInvalidParameter = errSecParam,
+	
+	/** Failed to allocate memory. */
+	SSKeychainErrorFailedToAllocated = errSecAllocate,
+	
+	/** No trust results are available. */
+	SSKeychainErrorNotAvailable = errSecNotAvailable,
+	
+	/** Authorization/Authentication failed. */
+	SSKeychainErrorAuthorizationFailed = errSecAuthFailed,
+	
+	/** The item already exists. */
+	SSKeychainErrorDuplicatedItem = errSecDuplicateItem,
+	
+	/** The item cannot be found.*/
+	SSKeychainErrorNotFound = errSecItemNotFound,
+	
+	/** Interaction with the Security Server is not allowed. */
+	SSKeychainErrorInteractionNotAllowed = errSecInteractionNotAllowed,
+	
+	/** Unable to decode the provided data. */
+	SSKeychainErrorFailedToDecode = errSecDecode
+} SSKeychainErrorCode;
+
+extern NSString *const kSSKeychainErrorDomain;
+
+/** Account name. */
+extern NSString *const kSSKeychainAccountKey;
+
+/**
+ Time the item was created.
+ 
+ The value will be a string.
+ */
+extern NSString *const kSSKeychainCreatedAtKey;
+
+/** Item class. */
+extern NSString *const kSSKeychainClassKey;
+
+/** Item description. */
+extern NSString *const kSSKeychainDescriptionKey;
+
+/** Item label. */
+extern NSString *const kSSKeychainLabelKey;
+
+/** Time the item was last modified.
+ 
+ The value will be a string.
+ */
+extern NSString *const kSSKeychainLastModifiedKey;
+
+/** Where the item was created. */
+extern NSString *const kSSKeychainWhereKey;
+
+/**
+ Simple wrapper for accessing accounts, getting passwords, setting passwords, and deleting passwords using the system
+ Keychain on Mac OS X and iOS.
+ 
+ This was originally inspired by EMKeychain and SDKeychain (both of which are now gone). Thanks to the authors.
+ SSKeychain has since switched to a simpler implementation that was abstracted from [SSToolkit](http://sstoolk.it).
+ */
+@interface SSKeychain : NSObject
+
+///-----------------------
+/// @name Getting Accounts
+///-----------------------
+
+/**
+ Returns an array containing the Keychain's accounts, or `nil` if the Keychain has no accounts.
+ 
+ See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
+ dictionaries returned by this method.
+ 
+ @return An array of dictionaries containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
+ accounts. The order of the objects in the array isn't defined.
+ 
+ @see allAccounts:
+ */
++ (NSArray *)allAccounts;
+
+/**
+ Returns an array containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
+ accounts.
+ 
+ See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
+ dictionaries returned by this method.
+ 
+ @param error If accessing the accounts fails, upon return contains an error that describes the problem.
+ 
+ @return An array of dictionaries containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
+ accounts. The order of the objects in the array isn't defined.
+ 
+ @see allAccounts
+ */
++ (NSArray *)allAccounts:(NSError **)error;
+
+/**
+ Returns an array containing the Keychain's accounts for a given service, or `nil` if the Keychain doesn't have any
+ accounts for the given service.
+ 
+ See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
+ dictionaries returned by this method.
+ 
+ @param serviceName The service for which to return the corresponding accounts.
+ 
+ @return An array of dictionaries containing the Keychain's accountsfor a given `serviceName`, or `nil` if the Keychain
+ doesn't have any accounts for the given `serviceName`. The order of the objects in the array isn't defined.
+ 
+ @see accountsForService:error:
+ */
++ (NSArray *)accountsForService:(NSString *)serviceName;
+
+/**
+ Returns an array containing the Keychain's accounts for a given service, or `nil` if the Keychain doesn't have any
+ accounts for the given service.
+ 
+ @param serviceName The service for which to return the corresponding accounts.
+ 
+ @param error If accessing the accounts fails, upon return contains an error that describes the problem.
+ 
+ @return An array of dictionaries containing the Keychain's accountsfor a given `serviceName`, or `nil` if the Keychain
+ doesn't have any accounts for the given `serviceName`. The order of the objects in the array isn't defined.
+ 
+ @see accountsForService:
+ */
++ (NSArray *)accountsForService:(NSString *)serviceName error:(NSError **)error;
+
+
+///------------------------
+/// @name Getting Passwords
+///------------------------
+
+/**
+ Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't have a
+ password for the given parameters.
+ 
+ @param serviceName The service for which to return the corresponding password.
+ 
+ @param account The account for which to return the corresponding password.
+ 
+ @return Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't
+ have a password for the given parameters.
+ 
+ @see passwordForService:account:error:
+ */
++ (NSString *)passwordForService:(NSString *)serviceName account:(NSString *)account;
+
+/**
+ Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't have a
+ password for the given parameters.
+ 
+ @param serviceName The service for which to return the corresponding password.
+ 
+ @param account The account for which to return the corresponding password.
+ 
+ @param error If accessing the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't
+ have a password for the given parameters.
+ 
+ @see passwordForService:account:
+ */
++ (NSString *)passwordForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
+
+/**
+ Returns the password data for a given account and service, or `nil` if the Keychain doesn't have data
+ for the given parameters.
+ 
+ @param serviceName The service for which to return the corresponding password.
+ 
+ @param account The account for which to return the corresponding password.
+ 
+ @param error If accessing the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns a the password data for the given account and service, or `nil` if the Keychain doesn't
+ have data for the given parameters.
+ 
+ @see passwordDataForService:account:error:
+ */
++ (NSData *)passwordDataForService:(NSString *)serviceName account:(NSString *)account;
+
+/**
+ Returns the password data for a given account and service, or `nil` if the Keychain doesn't have data
+ for the given parameters.
+ 
+ @param serviceName The service for which to return the corresponding password.
+ 
+ @param account The account for which to return the corresponding password.
+ 
+ @param error If accessing the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns a the password data for the given account and service, or `nil` if the Keychain doesn't
+ have a password for the given parameters.
+ 
+ @see passwordDataForService:account:
+ */
++ (NSData *)passwordDataForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
+
+
+///-------------------------
+/// @name Deleting Passwords
+///-------------------------
+
+/**
+ Deletes a password from the Keychain.
+ 
+ @param serviceName The service for which to delete the corresponding password.
+ 
+ @param account The account for which to delete the corresponding password.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see deletePasswordForService:account:error:
+ */
++ (BOOL)deletePasswordForService:(NSString *)serviceName account:(NSString *)account;
+
+/**
+ Deletes a password from the Keychain.
+ 
+ @param serviceName The service for which to delete the corresponding password.
+ 
+ @param account The account for which to delete the corresponding password.
+ 
+ @param error If deleting the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see deletePasswordForService:account:
+ */
++ (BOOL)deletePasswordForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
+
+
+///------------------------
+/// @name Setting Passwords
+///------------------------
+
+/**
+ Sets a password in the Keychain.
+ 
+ @param password The password to store in the Keychain.
+ 
+ @param serviceName The service for which to set the corresponding password.
+ 
+ @param account The account for which to set the corresponding password.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see setPassword:forService:account:error:
+ */
++ (BOOL)setPassword:(NSString *)password forService:(NSString *)serviceName account:(NSString *)account;
+
+/**
+ Sets a password in the Keychain.
+ 
+ @param password The password to store in the Keychain.
+ 
+ @param serviceName The service for which to set the corresponding password.
+ 
+ @param account The account for which to set the corresponding password.
+ 
+ @param error If setting the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see setPassword:forService:account:
+ */
++ (BOOL)setPassword:(NSString *)password forService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
+
+/**
+ Sets arbirary data in the Keychain.
+ 
+ @param password The data to store in the Keychain.
+ 
+ @param serviceName The service for which to set the corresponding password.
+ 
+ @param account The account for which to set the corresponding password.
+ 
+ @param error If setting the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see setPasswordData:forService:account:error:
+ */
++ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)serviceName account:(NSString *)account;
+
+/**
+ Sets arbirary data in the Keychain.
+ 
+ @param password The data to store in the Keychain.
+ 
+ @param serviceName The service for which to set the corresponding password.
+ 
+ @param account The account for which to set the corresponding password.
+ 
+ @param error If setting the password fails, upon return contains an error that describes the problem.
+ 
+ @return Returns `YES` on success, or `NO` on failure.
+ 
+ @see setPasswordData:forService:account:
+ */
++ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
+
+
+///--------------------
+/// @name Configuration
+///--------------------
+
+#if __IPHONE_4_0 && TARGET_OS_IPHONE
+/**
+ Returns the accessibility type for all future passwords saved to the Keychain.
+ 
+ @return Returns the accessibility type.
+ 
+ The return value will be `NULL` or one of the "Keychain Item Accessibility Constants" used for determining when a
+ keychain item should be readable.
+ 
+ @see accessibilityType
+ */
++ (CFTypeRef)accessibilityType;
+
+/**
+ Sets the accessibility type for all future passwords saved to the Keychain.
+ 
+ @param accessibilityType One of the "Keychain Item Accessibility Constants" used for determining when a keychain item
+ should be readable.
+ 
+ If the value is `NULL` (the default), the Keychain default will be used.
+ 
+ @see accessibilityType
+ */
++ (void)setAccessibilityType:(CFTypeRef)accessibilityType;
+#endif
+
+@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SSKeychain.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SSKeychain.m b/sdks/other/ios/UGAPI/SSKeychain.m
new file mode 100644
index 0000000..1267b5e
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SSKeychain.m
@@ -0,0 +1,262 @@
+//
+//  SSKeychain.m
+//  SSToolkit
+//
+//  Created by Sam Soffes on 5/19/10.
+//  Copyright (c) 2009-2011 Sam Soffes. All rights reserved.
+//
+
+#import "SSKeychain.h"
+
+NSString *const kSSKeychainErrorDomain = @"com.samsoffes.sskeychain";
+
+NSString *const kSSKeychainAccountKey = @"acct";
+NSString *const kSSKeychainCreatedAtKey = @"cdat";
+NSString *const kSSKeychainClassKey = @"labl";
+NSString *const kSSKeychainDescriptionKey = @"desc";
+NSString *const kSSKeychainLabelKey = @"labl";
+NSString *const kSSKeychainLastModifiedKey = @"mdat";
+NSString *const kSSKeychainWhereKey = @"svce";
+
+#if __IPHONE_4_0 && TARGET_OS_IPHONE
+CFTypeRef SSKeychainAccessibilityType = NULL;
+#endif
+
+@interface SSKeychain ()
++ (NSMutableDictionary *)_queryForService:(NSString *)service account:(NSString *)account;
+@end
+
+@implementation SSKeychain
+
+#pragma mark - Getting Accounts
+
++ (NSArray *)allAccounts {
+    return [self accountsForService:nil error:nil];
+}
+
+
++ (NSArray *)allAccounts:(NSError **)error {
+    return [self accountsForService:nil error:error];
+}
+
+
++ (NSArray *)accountsForService:(NSString *)service {
+    return [self accountsForService:service error:nil];
+}
+
+
++ (NSArray *)accountsForService:(NSString *)service error:(NSError **)error {
+    OSStatus status = SSKeychainErrorBadArguments;
+    NSMutableDictionary *query = [self _queryForService:service account:nil];
+#if __has_feature(objc_arc)
+	[query setObject:(__bridge id)kCFBooleanTrue forKey:(__bridge id)kSecReturnAttributes];
+    [query setObject:(__bridge id)kSecMatchLimitAll forKey:(__bridge id)kSecMatchLimit];
+#else
+    [query setObject:(id)kCFBooleanTrue forKey:(id)kSecReturnAttributes];
+    [query setObject:(id)kSecMatchLimitAll forKey:(id)kSecMatchLimit];
+#endif
+	
+	CFTypeRef result = NULL;
+#if __has_feature(objc_arc)
+    status = SecItemCopyMatching((__bridge CFDictionaryRef)query, &result);
+#else
+	status = SecItemCopyMatching((CFDictionaryRef)query, &result);
+#endif
+    if (status != noErr && error != NULL) {
+		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
+		return nil;
+	}
+	
+#if __has_feature(objc_arc)
+	return (__bridge_transfer NSArray *)result;
+#else
+    return [(NSArray *)result autorelease];
+#endif
+}
+
+
+#pragma mark - Getting Passwords
+
++ (NSString *)passwordForService:(NSString *)service account:(NSString *)account {
+	return [self passwordForService:service account:account error:nil];
+}
+
+
++ (NSString *)passwordForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
+    NSData *data = [self passwordDataForService:service account:account error:error];
+	if (data.length > 0) {
+		NSString *string = [[NSString alloc] initWithData:(NSData *)data encoding:NSUTF8StringEncoding];
+#if !__has_feature(objc_arc)
+		[string autorelease];
+#endif
+		return string;
+	}
+	
+	return nil;
+}
+
+
++ (NSData *)passwordDataForService:(NSString *)service account:(NSString *)account {
+    return [self passwordDataForService:service account:account error:nil];
+}
+
+
++ (NSData *)passwordDataForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
+    OSStatus status = SSKeychainErrorBadArguments;
+	if (!service || !account) {
+		if (error) {
+			*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
+		}
+		return nil;
+	}
+	
+	CFTypeRef result = NULL;
+	NSMutableDictionary *query = [self _queryForService:service account:account];
+#if __has_feature(objc_arc)
+	[query setObject:(__bridge id)kCFBooleanTrue forKey:(__bridge id)kSecReturnData];
+	[query setObject:(__bridge id)kSecMatchLimitOne forKey:(__bridge id)kSecMatchLimit];
+	status = SecItemCopyMatching((__bridge CFDictionaryRef)query, &result);
+#else
+	[query setObject:(id)kCFBooleanTrue forKey:(id)kSecReturnData];
+	[query setObject:(id)kSecMatchLimitOne forKey:(id)kSecMatchLimit];
+	status = SecItemCopyMatching((CFDictionaryRef)query, &result);
+#endif
+	
+	if (status != noErr && error != NULL) {
+		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
+		return nil;
+	}
+	
+#if __has_feature(objc_arc)
+	return (__bridge_transfer NSData *)result;
+#else
+    return [(NSData *)result autorelease];
+#endif
+}
+
+
+#pragma mark - Deleting Passwords
+
++ (BOOL)deletePasswordForService:(NSString *)service account:(NSString *)account {
+	return [self deletePasswordForService:service account:account error:nil];
+}
+
+
++ (BOOL)deletePasswordForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
+	OSStatus status = SSKeychainErrorBadArguments;
+	if (service && account) {
+		NSMutableDictionary *query = [self _queryForService:service account:account];
+#if __has_feature(objc_arc)
+		status = SecItemDelete((__bridge CFDictionaryRef)query);
+#else
+		status = SecItemDelete((CFDictionaryRef)query);
+#endif
+	}
+	if (status != noErr && error != NULL) {
+		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
+	}
+	return (status == noErr);
+    
+}
+
+
+#pragma mark - Setting Passwords
+
++ (BOOL)setPassword:(NSString *)password forService:(NSString *)service account:(NSString *)account {
+	return [self setPassword:password forService:service account:account error:nil];
+}
+
+
++ (BOOL)setPassword:(NSString *)password forService:(NSString *)service account:(NSString *)account error:(NSError **)error {
+    NSData *data = [password dataUsingEncoding:NSUTF8StringEncoding];
+    return [self setPasswordData:data forService:service account:account error:error];
+}
+
+
++ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)service account:(NSString *)account {
+    return [self setPasswordData:password forService:service account:account error:nil];
+}
+
+
++ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)service account:(NSString *)account error:(NSError **)error {
+    OSStatus status = SSKeychainErrorBadArguments;
+	if (password && service && account) {
+        [self deletePasswordForService:service account:account];
+        NSMutableDictionary *query = [self _queryForService:service account:account];
+#if __has_feature(objc_arc)
+		[query setObject:password forKey:(__bridge id)kSecValueData];
+#else
+		[query setObject:password forKey:(id)kSecValueData];
+#endif
+		
+#if __IPHONE_4_0 && TARGET_OS_IPHONE
+		if (SSKeychainAccessibilityType) {
+#if __has_feature(objc_arc)
+			[query setObject:(id)[self accessibilityType] forKey:(__bridge id)kSecAttrAccessible];
+#else
+			[query setObject:(id)[self accessibilityType] forKey:(id)kSecAttrAccessible];
+#endif
+		}
+#endif
+		
+#if __has_feature(objc_arc)
+        status = SecItemAdd((__bridge CFDictionaryRef)query, NULL);
+#else
+		status = SecItemAdd((CFDictionaryRef)query, NULL);
+#endif
+	}
+	if (status != noErr && error != NULL) {
+		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
+	}
+	return (status == noErr);
+}
+
+
+#pragma mark - Configuration
+
+#if __IPHONE_4_0 && TARGET_OS_IPHONE
++ (CFTypeRef)accessibilityType {
+	return SSKeychainAccessibilityType;
+}
+
+
++ (void)setAccessibilityType:(CFTypeRef)accessibilityType {
+	CFRetain(accessibilityType);
+	if (SSKeychainAccessibilityType) {
+		CFRelease(SSKeychainAccessibilityType);
+	}
+	SSKeychainAccessibilityType = accessibilityType;
+}
+#endif
+
+
+#pragma mark - Private
+
++ (NSMutableDictionary *)_queryForService:(NSString *)service account:(NSString *)account {
+    NSMutableDictionary *dictionary = [NSMutableDictionary dictionaryWithCapacity:3];
+#if __has_feature(objc_arc)
+    [dictionary setObject:(__bridge id)kSecClassGenericPassword forKey:(__bridge id)kSecClass];
+#else
+	[dictionary setObject:(id)kSecClassGenericPassword forKey:(id)kSecClass];
+#endif
+	
+    if (service) {
+#if __has_feature(objc_arc)
+		[dictionary setObject:service forKey:(__bridge id)kSecAttrService];
+#else
+		[dictionary setObject:service forKey:(id)kSecAttrService];
+#endif
+	}
+	
+    if (account) {
+#if __has_feature(objc_arc)
+		[dictionary setObject:account forKey:(__bridge id)kSecAttrAccount];
+#else
+		[dictionary setObject:account forKey:(id)kSecAttrAccount];
+#endif
+	}
+	
+    return dictionary;
+}
+
+@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGActivity.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGActivity.h b/sdks/other/ios/UGAPI/UGActivity.h
new file mode 100755
index 0000000..1139518
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGActivity.h
@@ -0,0 +1,64 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+
+@interface UGActivity : NSObject
+
+// In order for an activity to be valid, you must call setBasics and one of the setActor functions. 
+// In all cases, the return value will be YES if the function succeeded and NO if there
+// was a problem with the set. A response of NO will usually mean you sent nil for a required field.
+
+// these are the basics of the activity.
+// verb: the action being taken
+// category: The type of activity it is
+// content: The content of this activity. The format is defined by the category
+// title: The title of this category.
+-(BOOL) setBasics: (NSString *)verb category:(NSString *)category content:(NSString *)content title:(NSString *)title;
+
+// actorUserName: The username of the entity doing this activity
+// actorDisplayName: The visible name of the entity doing this activity
+// actorUUID: The UUID of the entity doing this activity
+-(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorUUID:(NSString *)actorUUID;
+
+// actorUserName: The username of the entity doing this activity
+// actorDisplayName: The visible name of the entity doing this activity
+// actorUUID: The UUID of the entity doing this activity
+-(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorEmail:(NSString *)actorEmail;
+
+// Associating an object with the Activity is optional. You don't have to supply an object at all.
+
+// objectType: the type of the object associated with this activity
+// displayName: The visible name of the object associated with this activity
+// entityType: the entity type of this object within UserGrid. The actual type that it is stored under
+// entityUUID: The uuid of the object associated with this activity
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName entityType:(NSString *)entityType entityUUID:(NSString *)entityUUID;
+
+// similar to the function above, but it takes an arbitrary object content (which can be new and unique) instead of an already-defined object
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName objectContent:(NSString *)objectContent;
+
+// similar to the other two functions, but simply has the type and displayName. In this case, the 
+// "content" value supplied in setBasics will be used as the object content.
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName;
+
+// returns YES if this is properly set up. NO if it has not been properly set up
+-(BOOL)isValid;
+
+// turn this object in to an NSDictionary. Used internally by UGClient
+-(NSDictionary *)toNSDictionary;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGActivity.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGActivity.m b/sdks/other/ios/UGAPI/UGActivity.m
new file mode 100755
index 0000000..3eaea00
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGActivity.m
@@ -0,0 +1,263 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGActivity.h"
+
+// the way they have set up the object info
+enum
+{
+    kUGActivityNoObject = 0,
+    kUGActivityObjectEntity = 1,
+    kUGActivityObjectContent = 2,
+    kUGActivityObjectNameOnly = 3
+};
+
+@implementation UGActivity
+{
+    // basic stats
+    NSString *m_verb;
+    NSString *m_category;
+    NSString *m_content;
+    NSString *m_title;
+    
+    // stats related to the actor
+    NSString *m_actorUserName;
+    NSString *m_actorDisplayName;
+    NSString *m_actorUUID;
+    NSString *m_actorEmail;
+    
+    // stats related to the object
+    NSString *m_objectType;
+    NSString *m_objectDisplayName;
+    
+    // for the object, either these must be set...
+    NSString *m_entityType;
+    NSString *m_entityUUID;
+    
+    // ...or this must be set
+    NSString *m_objectContent;
+    
+    // or it will use the content field as the content for the object
+    
+    // tracking how the object is currently set up
+    int m_objectDataType;
+}
+
+-(id)init
+{
+    self = [super init];
+    if ( self )
+    {
+        m_objectDataType = kUGActivityNoObject;
+    }
+    return self;
+}
+
+-(BOOL) setBasics: (NSString *)verb category:(NSString *)category content:(NSString *)content title:(NSString *)title
+{
+    // input validation
+    if ( !verb || !category || !content || !title ) return NO;
+    
+    m_verb = verb;
+    m_category = category;
+    m_content = content;
+    m_title = title;
+
+    return YES;
+}
+
+-(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorUUID:(NSString *)actorUUID
+{
+    // input validation
+    if ( !actorUserName || !actorDisplayName || !actorUUID ) return NO;
+    
+    m_actorUserName = actorUserName;
+    m_actorDisplayName = actorDisplayName;
+    m_actorUUID = actorUUID;
+    m_actorEmail = nil;
+    
+    return YES;
+}
+
+-(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorEmail:(NSString *)actorEmail
+{
+    // input validation
+    if ( !actorUserName || !actorDisplayName || !actorEmail ) return NO;
+    
+    m_actorUserName = actorUserName;
+    m_actorDisplayName = actorDisplayName;
+    m_actorEmail = actorEmail;
+    m_actorUUID = nil;
+    
+    return YES;
+}
+
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName entityType:(NSString *)entityType entityUUID:(NSString *)entityUUID
+{
+    // input validation
+    if ( !objectType || !displayName || !entityType || !entityUUID ) return NO;
+    
+    m_objectType = objectType;
+    m_objectDisplayName = displayName;
+    m_entityType = entityType;
+    m_entityUUID = entityUUID;
+    m_objectDataType = kUGActivityObjectEntity;
+    
+    // clear out the unused value
+    m_objectContent = nil;
+    
+    return YES;
+}
+
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName objectContent:(NSString *)objectContent
+{
+    // input validation
+    if ( !objectType || !displayName || !objectContent ) return NO;
+    
+    m_objectType = objectType;
+    m_objectDisplayName = displayName;
+    m_objectContent = objectContent;
+    m_objectDataType = kUGActivityObjectContent;
+    
+    // clear out the unused values
+    m_entityType = nil;
+    m_entityUUID = nil;
+    
+    return YES;
+}
+
+-(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName
+{
+    // input validation
+    if ( !objectType || !displayName ) return NO;
+    
+    m_objectType = objectType;
+    m_objectDisplayName = displayName;
+    m_objectDataType = kUGActivityObjectNameOnly;
+    
+    // we'll use m_content when the time comes. But we don't want to 
+    // assume they've set it yet. They can call the setup functions in any order.
+    m_objectContent = nil; 
+    m_entityType = nil;
+    m_entityUUID = nil;
+    
+    return YES;
+}
+
+-(BOOL)isValid
+{
+    // if any of the required values are nil, it's not valid
+    if ( !m_verb || !m_category || !m_content || !m_title || !m_actorUserName || !m_actorDisplayName )
+    {
+        return NO;
+    }
+    
+    // either the uuid or the email of the user must be valid
+    if ( !m_actorUUID && !m_actorEmail )
+    {
+        return NO;
+    }
+    
+    // the object data requirements are based on the object setup
+    switch ( m_objectDataType )
+    {
+        case kUGActivityObjectEntity:
+        {
+            if ( !m_objectType || !m_objectDisplayName || !m_entityType || !m_entityUUID ) return NO;
+        }
+        break;
+            
+        case kUGActivityObjectContent:
+        {
+            if ( !m_objectType || !m_objectDisplayName || !m_objectContent ) return NO;
+        }
+            break;
+            
+        case kUGActivityObjectNameOnly:
+        {
+            if ( !m_objectType || !m_objectDisplayName ) return NO;
+        }
+        break;
+            
+        // kUGActivityNoObject has no requirements.
+    }
+    
+    // if we're here, we're valid.
+    return YES;
+}
+
+-(NSDictionary *)toNSDictionary
+{
+    NSMutableDictionary *ret = [NSMutableDictionary new];
+    
+    // add all the fields in
+    [ret setObject:@"activity" forKey:@"type"];
+    [ret setObject:m_verb forKey:@"verb"];
+    [ret setObject:m_category forKey:@"category"];
+    [ret setObject:m_content forKey:@"content"];
+    [ret setObject:m_title forKey:@"title"];
+    
+    // make the actor's subdictionary
+    NSMutableDictionary *actor = [NSMutableDictionary new];
+    [actor setObject:@"person" forKey:@"type"];
+    [actor setObject:@"user" forKey:@"entityType"];
+    [actor setObject:m_actorDisplayName forKey:@"displayName"];
+    
+    if ( m_actorUUID )
+    {
+        [actor setObject:m_actorUUID forKey:@"uuid"];
+    }
+    if ( m_actorEmail )
+    {
+        [actor setObject:m_actorEmail forKey:@"email"];
+    }
+    
+    // add the actor to the main dict
+    [ret setObject:actor forKey:@"actor"];
+    
+    if ( m_objectDataType != kUGActivityNoObject )
+    {
+        // there is an associated object. Prep a dict for it
+        NSMutableDictionary *object = [NSMutableDictionary new];
+        
+        // these fields are involved in all cases
+        [object setObject:m_objectType forKey:@"type"];
+        [object setObject:m_objectDisplayName forKey:@"displayName"];
+        
+        if ( m_objectDataType == kUGActivityObjectContent )
+        {
+            [object setObject:m_objectContent forKey:@"content"];
+        }
+        else if ( m_objectDataType == kUGActivityObjectNameOnly )
+        {
+            [object setObject:m_content forKey:@"content"];
+        }
+        else if ( m_objectDataType == kUGActivityObjectEntity )
+        {
+            [object setObject:m_entityType forKey:@"entityType"];
+            [object setObject:m_entityUUID forKey:@"entityUUID"];
+        }
+        
+        // add to the dict
+        [ret setObject:object forKey:@"object"];
+    }
+    
+    // done with the assembly
+    return ret;
+}
+
+@end


[37/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/Icon.ai
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/Icon.ai b/sdks/ios/samples/parties/Icon.ai
deleted file mode 100644
index ad69fcf..0000000
--- a/sdks/ios/samples/parties/Icon.ai
+++ /dev/null
@@ -1,4620 +0,0 @@
-%PDF-1.5
%\ufffd\ufffd\ufffd\ufffd
-1 0 obj
<</Metadata 2 0 R/OCProperties<</D<</ON[6 0 R 36 0 R 65 0 R 94 0 R 123 0 R 152 0 R 181 0 R 210 0 R 239 0 R 268 0 R]/Order 269 0 R/RBGroups[]>>/OCGs[6 0 R 36 0 R 65 0 R 94 0 R 123 0 R 152 0 R 181 0 R 210 0 R 239 0 R 268 0 R]>>/Pages 3 0 R/Type/Catalog>>
endobj
2 0 obj
<</Length 56153/Subtype/XML/Type/Metadata>>stream
-<?xpacket begin="\ufeff" id="W5M0MpCehiHzreSzNTczkc9d"?>
-<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.0-c060 61.134777, 2010/02/12-17:32:00        ">
-   <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
-      <rdf:Description rdf:about=""
-            xmlns:dc="http://purl.org/dc/elements/1.1/">
-         <dc:format>application/pdf</dc:format>
-         <dc:title>
-            <rdf:Alt>
-               <rdf:li xml:lang="x-default">Icon</rdf:li>
-            </rdf:Alt>
-         </dc:title>
-      </rdf:Description>
-      <rdf:Description rdf:about=""
-            xmlns:xmp="http://ns.adobe.com/xap/1.0/"
-            xmlns:xmpGImg="http://ns.adobe.com/xap/1.0/g/img/">
-         <xmp:MetadataDate>2013-05-04T20:26:56-07:00</xmp:MetadataDate>
-         <xmp:ModifyDate>2013-05-04T20:26:56-07:00</xmp:ModifyDate>
-         <xmp:CreateDate>2013-05-04T20:19:17-07:00</xmp:CreateDate>
-         <xmp:CreatorTool>Adobe Illustrator CS5</xmp:CreatorTool>
-         <xmp:Thumbnails>
-            <rdf:Alt>
-               <rdf:li rdf:parseType="Resource">
-                  <xmpGImg:width>256</xmpGImg:width>
-                  <xmpGImg:height>256</xmpGImg:height>
-                  <xmpGImg:format>JPEG</xmpGImg:format>
-                  <xmpGImg:image>/9j/4AAQSkZJRgABAgEASABIAAD/7QAsUGhvdG9zaG9wIDMuMAA4QklNA+0AAAAAABAASAAAAAEA&#xA;AQBIAAAAAQAB/+4ADkFkb2JlAGTAAAAAAf/bAIQABgQEBAUEBgUFBgkGBQYJCwgGBggLDAoKCwoK&#xA;DBAMDAwMDAwQDA4PEA8ODBMTFBQTExwbGxscHx8fHx8fHx8fHwEHBwcNDA0YEBAYGhURFRofHx8f&#xA;Hx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8f/8AAEQgBAAEAAwER&#xA;AAIRAQMRAf/EAaIAAAAHAQEBAQEAAAAAAAAAAAQFAwIGAQAHCAkKCwEAAgIDAQEBAQEAAAAAAAAA&#xA;AQACAwQFBgcICQoLEAACAQMDAgQCBgcDBAIGAnMBAgMRBAAFIRIxQVEGE2EicYEUMpGhBxWxQiPB&#xA;UtHhMxZi8CRygvElQzRTkqKyY3PCNUQnk6OzNhdUZHTD0uIIJoMJChgZhJRFRqS0VtNVKBry4/PE&#xA;1OT0ZXWFlaW1xdXl9WZ2hpamtsbW5vY3R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo+Ck5SVlpeYmZ&#xA;qbnJ2en5KjpKWmp6ipqqusra6voRAAICAQIDBQUEBQYECAMDbQEAAhEDBCESMUEFURNhIgZxgZEy&#xA;obHwFMHR4SNCFVJicvEzJDRDghaSUyWiY7LCB3PSNeJEgxdUkwgJChgZJjZFGidkdFU38qOzwygp&#xA;0+PzhJSktMTU5PRldYWVpbXF1eX1RlZmdoaWprbG1ub2R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo&#xA;+DlJWWl5iZmpucnZ6fkqOkpaanqKmqq6ytrq+v/aAAwDAQACEQMRAD8AB5yD7A7FXYq7FXYq7
 FXY&#xA;q7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq&#xA;7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7&#xA;FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7F&#xA;XYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FX&#xA;Yq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXY&#xA;q7FXYq7FXYqjLDRtY1EO2n2NxeLHQSG3ieUKT05cAaVpk4Y5S+kEtOXU4sf1yjG+8gIv/CHmz/qy&#xA;X/8A0izf805P8vk/my+Raf5R0/8AqkP9MP1tf4Q82D/pS3//AEizf804/l8n82XyK/yjp/8AVIf6&#xA;YfrS64tLq2k9O5heCT+SRSh+5gMqII5uVDJGQuJB9ylgZOxVMrfyz5kuYEnttJvJ4JBWOWO3ldGH&#xA;iGVSDlscMyLET8nFnrsETUpwBHfIKv8AhDzZ/wBWS/8A+kWb/mnD+XyfzZfIsf5R0/8AqkP9MP1q&#xA;N35b8xWdu9zd6Xd29vHTnNLBKiLU0FWZQBUmmRlhnEWYkD3M8etwzPDGcSe4SCXZW5KJsNM1LUJG&#xA;isLSa7kQcnSCN5WC1pUhAdslGEpbAW1Zc8MYuchEeZpHf4Q82f8AVkv/APpFm/5pyz8vk/my+RaP&#xA;5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8AVIf6YfrWv5T80xoXfRr5EHVmtpgB&#xA;9JXAcGQc4n5JGv052
 GSH+mH60sdHjco6lHU0ZWFCD7g5U5QIIsK1jpuo6hMYbC1mu5lUu0cEbSMF&#xA;BALEICaVIyUYSkaAthlzQxi5yER5mkf/AIQ82f8AVkv/APpFm/5pyz8vk/my+Rcf+UdP/qkP9MP1&#xA;u/wh5s/6sl//ANIs3/NOP5fJ/Nl8iv8AKOn/ANUh/ph+t3+EPNn/AFZL/wD6RZv+acfy+T+bL5Ff&#xA;5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8AVIf6YfraPlLzWCAdFvwWNFH1abc0&#xA;r/L7YPy+T+afkU/yhp/9Uh/ph+tv/CHmz/qyX/8A0izf804fy+T+bL5FH8o6f/VIf6YfrWS+VfNE&#xA;MTyy6PexxRqXkke2lVVVRUkkrQADAcGQCzE/JMdfpyaGSBJ/pD9aV5U5aZW3lnzJdQJcW2lXk8Eg&#xA;rHLHbyujDxDKpBy2OGZFiJr3ONPW4ImpTgCO+QVf8IebP+rJf/8ASLN/zTh/L5P5svkWH8o6f/VI&#xA;f6YfrS+8sb2xnNve28trOACYpkaNwDuDxYA5XKJiaIouTjywmLiRIeW6hkWbsVdirsVdir2H8hv9&#xA;49Y/4yQf8RfNx2V/F8P0vGe1f1Y/cf0PVM27yTsVQ2o6Xp2pW5tr+2juYG6pKoYfMV6H3GQnjjMV&#xA;IW24c88UuKBMT5PEvzI/LU6AP0npfKTSGIEqMeTwMxoKnuhOwP0HNFrNF4fqj9P3PddjdtfmP3eT&#xA;bJ9/7WD2FnNe3tvZwCs1zIkUY/ynYKP15gxiSaDvcuQQgZHlEW+p7CyhsbG3soBSG2jSKMf5KKFH&#xA;6s6yEBGIA6Pk+XKckzI85G1fJNaB13TI9V0a906QDjdQvGCezEfCfoahyvNj44GPe5GlznFljMfw&#xA;m3y1LFJDK8Ui8ZI2Kup6hlNCM5R9XjIEWORekfkX/w
 ApDqH/ADCf8zUzZdl/3h936Q8z7U/3Mf63&#xA;6C9rzevDOxV2KpD5p8l6H5jtWjvIQl1SkN6gAlQ9t/2h/knMbPpYZRvz73YaHtLLppXE+nrHo87/&#xA;ACq0W90X8wtT028Wk1vZSDkOjKZoSrr7MN812gxmGYxPMD9Iek7e1Mc+ihkjyMx90nsWbp4t2Kux&#xA;V2Ksd8+63caJ5fOpwV5W9xAXTpzQyAOh/wBZajMXWZTCHEO8Oy7J00c+bwz1jL7tk9s7uC8tIbu3&#xA;YPBOiyROO6uKg5kRkJAEdXAyYzCRjLmDSo6JIjI6hkcFWU7gg7EHCRbEEg2HznqXkq5i89ny3CCB&#xA;NcAW79f3D/GH/wBjH1+Wc1PTkZfDHe+lYe04nSeOekd/fy+0voi0tYLS1htbdeEFuixRIOyoOIH3&#xA;DOkjERAA6Pm+TIZyMjzJtS1TUrbTNOudQum4wW0bSSHvRR0HuegwZMghEyPRlgwyyzEI85GnzDrO&#xA;q3Orardalcms11IZGHYA/ZUeyigGctkmZSMj1fVdNgjhxxhHlEILINzsVdirsVdir2H8hv8AePWP&#xA;+MkH/EXzcdlfxfD9LxntX9WP3H9D1TNu8kx7zF578v8Al69htNTkkjknT1FZIy6heRWppv1HhmLm&#xA;1cMcqk7LR9lZtTAyxgEDbmndneWt7axXdpKs1tMoeKVDVWBzIhMSFjk4GTHKEjGQqQW6hYW2oWNx&#xA;Y3Kh7e5jaORT4MKff4YJwEokHkU4csscxOPOJt4n+Vvlt28+zJOKroplMldv3qsYlH3kt9GaLQ4b&#xA;zb/wvddu60fkxX+Vr5c3umdA8C0HQuUDAuoDMtdwGqASPficFpo1beFD54/NPR/0Z5yvOIpDe0u4&#xA;9v8Aftef/JQNnN67Hw5T57vpHYWp8XSx74+n5cvspPPyL/5SHUP+YT/mamX9l/3h936
 Q4HtT/cx/&#xA;rfoL2vN68Mxzzl53sPK0VrJd28s4umdUEXHbgATXkR/NmLqdUMVWLt2fZvZk9WZCJA4e9R8ofmJo&#xA;nmeeW1tUlt7qJfU9GYL8SVALKVJGxO+R0+sjlNDYs+0ex8ulAlKjE9QynMx1LDfM2q6J5c83WOt6&#xA;i5iS7sLi0ZkQuS0c0MiV41PRmzBz5I4somesSPtDu9Fgy6nTSxQ34Zxl8xIH9C3/AJW/5G/5a5P+&#xA;RMn9Mf5Rxeaf9Dur/mj5hlWl6laanp8F/ZsXtrhecTEFSRWnQ75l48gnESHIuoz4JYpmEvqCKybU&#xA;xK+/NPybZXtxZ3F1ItxbSPDMohkIDxsVYVA33GYU9fjiSD0dxi7B1U4iUQKkLG46sT/MT8xPK2t+&#xA;VrjT9PuHkupHiZVaJ1FFcE7kU6Zh6zWQyQ4Y83b9j9j6jBqBOYHDR6juRv5K+Z/rWnTaDcPWeyrL&#xA;a1O5hY/Ev+wc/jlnZmewYHpyafabQ8Exmjylsff+0fc9MzavLJfJoWnya7DrbJ/p0MDWyv8A5DMG&#xA;+8bj6TlRwxMxPrVOSNVMYTi/hMr/AB+OiYZa4zyn87vMoWG38v27/FJS4vQP5R/dofmfi+gZp+08&#xA;/KA95eu9mNFZOY+6P6T+j5vIM1D2TsVdirsVdirsVew/kN/vHrH/ABkg/wCIvm47K/i+H6XjPav6&#xA;sfuP6Hqmbd5J4z+dtpdXHmLT1gheVja0ARSxr6j7bDNH2mLyD3fre29mMkY4J2QPV+gM7/LHRdR0&#xA;jylb22oKY7h3eb0G6xq52U+B70982GhxShjqToO29TDNqTKG4oC+9leZjqGI/l7p0anXNYCgHVtS&#xA;uJImpSsMcjKh+luRzB0UPqn/ADpH5O57XzE+Hi/1PHH5kC/0MuzOdM8/8s+aPrf5na/YGSsDxrHA&#xA;Oo5WZ4MB8y7
 nNZgz3qJD8bfgvRa3Q8GgxTre9/8AO/sD0DNm868x/PLR/W0my1ZF+O0kMMp78JRU&#xA;E/Jl/HNV2pj2Evg9T7L6msksZ/iF/Efj7Ei/Iv8A5SHUP+YT/mamY/Zf94fd+kOw9qf7mP8AW/QX&#xA;teb14ZivnzyL/iyGzj+u/UvqjO1fS9XlzCj+eOlOOYer0vjVvVO37K7U/KGR4eLirrXL4FC+R/yz&#xA;tPK97NfNeNe3cielG3p+kqISC3w8nqTQb1yOl0IxG7stvanbctVEQ4eGN3zv9AZpmc6N4h+dmtw3&#xA;mvWunQsHGnRt6pFDSWYgsu3gqLmh7Sy8U+Efwvd+zOlMMJmf4z9g/Bec5rnpX0l+XX/KEaR/xg/4&#xA;2OdLof7qL5l2z/jWT3sjzKdY+YfN/wDylmt/8x91/wAnmzltR/eS/rH731Ts7/F8f9SP3BKMpcxN&#xA;PLOuT6HrlpqcNf3Dj1UH7UbbOv0qTlmHIYSEh0cXW6UZ8UsZ6j7ej6dtbmC6tormBxJBOiyROOhV&#xA;hUH7s6mMhIWORfK5wMJGJ5hUyTFDalqFtp2n3F/dNxt7aNpJD7KK0HuegyGSYhEyPRtwYZZJiEec&#xA;jT5h1zV7nWNWutSuT+9uZC5HUKOiqPZVoBnLZJmcjI9X1TS6eOHHHHHlEIHIN7sVdirsVdirsVew&#xA;/kN/vHrH/GSD/iL5uOyv4vh+l4z2r+rH7j+h6pm3eSdirsVYx5+81JomlehbMG1i/wD3Gnwg/Fyf&#xA;4fU+S1+/MPWajw40PqPJ2vZOgOfJcv7uG8j+j4p3o2mxaZpNpp8W6WsSRV8SooW+k75kYsfBER7n&#xA;B1OY5ckpn+I2jMsaEg0/yJ5V07VBqtnZGK/DOwm9adt5AQ1VZypryPbMaGkxxlxAb/F2GbtXUZMf&#xA;hylcO6o9Pgn+ZLr0q81aQNY8u6hptKtcQsI/
 +Mi/FGf+DUZTqMfHjMXL0Go8HPGfcfs6/Y8p/IwE&#xA;eYtQBFCLShB/4ypmo7L/ALw+79Ieu9qf7mH9b9Be15vXhmi6BwhI5sCQvcgUBP4jBaa2tvChjf5g&#xA;65q2ieWbi/0yJZJ0ZUeRt/SR/h9QLT4iGI6/PMXWZZQx3F2fZGlx584hkO33+T5xmmlnmeaZzJLI&#xA;xeR2NSzMakk5zRNvpkYiIocgsxS+kvy6/wCUI0j/AIwf8bHOl0P91F8y7Z/xrJ72R5lOsfMPm/8A&#xA;5SzW/wDmPuv+TzZy2o/vJf1j976p2d/i+P8AqR+4JRlLmOxV7h+SmvT32hXOmTVY6Y6ek5/33PyK&#xA;r/sWRs3nZmUmBif4f0vCe02lEMwyD+P7xX63oubN5p5d+eGvTQWVnosVVS7rPct4pGaIn/Bbn5DN&#xA;T2plIAh8Xq/ZfSCUpZT/AA7D4vG80z2rsVdirsVdirsVdir2H8hv949Y/wCMkH/EXzcdlfxfD9Lx&#xA;ntX9WP3H9D1TNu8kxfzZ+Yei+WLyG0v4LmWSeP1UMCxsoXkV35um+2YmfWQxGiC7XQdj5dVEygYg&#xA;A1vf6iwnWvz0leJo9G0/0nIoLi5YMR8o12r82zAydqE/SKd7pvZYA3llfkP1/sSP8u4tR8y+f4dQ&#xA;1GV7l7Wt3PK++8e0YHYUdloBlGkBy5gTvW7n9sShpdGYQHDxekfHn9j3rOhfPkBrWu6Voll9d1Of&#xA;6vbchH6nF3+Jq0FEDN28Mry5Y4xcjQcjTaXJnlwYxcvx3pD/AMrX8gf9XT/khc/9U8x/z+H+d9h/&#xA;U7D+QNZ/M/2Uf1sos7u3vLSG7tnElvcIssMgqOSOKqaGh6HMqMhIWORdVkxyhIxltIGiq5Jg858o&#xA;6N+ifzR1+BV4wzW/1mCnThNKrbfJqr9GavTY+DUSHl+p6XtDU+NoMR6iVH4Av
 Rs2jzTEvN+ufojz&#xA;H5alduNvcyz2tx2HGURgE/J+JzB1WXgyQPTf9DuOztL42DMBziIyHwv9FstzOdOoX9jbX9jPZXK8&#xA;7e5jaKVf8lhQ098jOAkCDyLZiyyxzE484m3y9rWlXGk6tdabcD97ayNGT/MB9lh7MtCM5XJAwkYn&#xA;o+q6bURzY4zjykEFkG99Jfl1/wAoRpH/ABg/42OdLof7qL5l2z/jWT3sjzKdY+YfN/8Aylmt/wDM&#xA;fdf8nmzltR/eS/rH731Ts7/F8f8AUj9wSjKXMdir1v8AIT/pe/8ARp/zOzb9lfxfD9Lx/tZ/k/8A&#xA;O/3r1rNw8e8Y/Pb/AI7Omf8AMO3/ABPNH2p9Y9z2/sr/AHU/636HmOax6l2KuxV2KuxV2KuxVnn5&#xA;Z+fdH8rwX8eoQ3ErXTRtH9XVGACBgeXN0/mzP0Wqjivivd5/tvsrLqjEwMRw3zv9RZr/AMry8p/8&#xA;sl//AMi4f+q2Z38qY+6X2frdH/oX1H86HzP/ABLzz8yfN2m+Z9Vtbuwjmijgg9JxOqKxbmzbcGfb&#xA;fNbrNRHLIEdz0nYvZ89LjlGZBJle3u9wYjmI7hnf5a+dvL3leK9kv4LmW8umRVaBI2VY0BNKvIhq&#xA;WbfbwzP0WphisyBsug7a7MzaoxEDERj33z+RZt/yvLyn/wAsl/8A8i4f+q2Z38qY+6X2frdF/oX1&#xA;H86HzP8AxLDvzK/MXTfM1hZ2enRXEUcMrTT/AFhUWpC8U48Hev2mzC1usjlAEbd12L2PPSzlKZiS&#xA;RQq/jzA8nn+a96J6r5L/ADb0XR/Ldppmo291JcWvJBJCkbKULFl3aRDsDTpm10uvjCAjIHZ5LtP2&#xA;fy5s8skDECXff6inn/K8vKf/ACyX/wDyLh/6rZkfypj7pfZ+twP9C+o/nQ+Z/wCJQDfm95Q/T0eq&#xA;raXwf
 6q9rL+7hqR6iyJT972+Pv3yr8/j8TjqXKun63IHs9qfBOPih9XFzPcQf4fcj/8AleXlP/lk&#xA;v/8AkXD/ANVst/lTH3S+z9bj/wChfUfzofM/8Swv8yvP2keZ4dPTToriF7R5Gczqi/bC048Hf+XM&#xA;HW6qOWuG9nedi9k5NKZcZieKuV/pAZZp353+X0sLZL61vWvFjRbho0iKGQABipMqmhPtmZj7TgIj&#xA;iBv8ebqM3sxmMyYGHDe3Pl8kR/yvLyn/AMsl/wD8i4f+q2S/lTH3S+z9bV/oX1H86HzP/EvO/wAx&#xA;vMugeY9Tg1HS4biGf0/TuhOiKG4n4GBR33oaH5DNbrM0MkuKN+b0nY2izabGYZDEi7FX8egYlmI7&#xA;h635U/Nzy3pHl2w025trx57WPhI0aRFCak7FpVPfwzb6fXwhARINj8d7x+v9n8+bPLJEwqR6k/qT&#xA;b/leXlP/AJZL/wD5Fw/9Vsu/lTH3S+z9bh/6F9R/Oh8z/wAS8c12+h1DXNRv4Qyw3dzNPGrgBgsk&#xA;hcBgCRWh8c02WQlMkdS9rpcRx4oQPOMQPkEDlbe7FWc/ll550nyt+kv0hDcS/XPQ9L6uqNT0vU5c&#xA;ubp/OKZn6LVRxXxXvToe2+y8mr4OAxHDfO+tdwPczj/leXlP/lkv/wDkXD/1WzO/lTH3S+z9bof9&#xA;C+o/nQ+Z/wCJef8A5lecdM80X9ncWEU8SW8TRuJ1RSSWrtwZ812t1EcsgR3PRdi9nZNLCUZkGz0/&#xA;sDDsw3dOxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2&#xA;KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2K&#xA;uxV2KuxV2KuxV2KuxV2KuxV2KuxV2K
 uxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2Ku&#xA;xV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2Kux&#xA;V2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV&#xA;2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxVVtLS7vLhLa0hkuLiSvCGJS7tQV&#xA;NFUEmgFcMYkmhuWGTJGA4pEAd52TL/CHmz/qyX//AEizf805b+XyfzZfIuN/KOn/ANUh/ph+t3+E&#xA;PNn/AFZL/wD6RZv+acfy+T+bL5Ff5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8A&#xA;VIf6Yfrd/hDzZ/1ZL/8A6RZv+acfy+T+bL5Ff5R0/wDqkP8ATD9aGvtD1vT41lv9PubSJzxV54ZI&#xA;lLUrQFwN9shPFKPMENuLVYshqEoyPkQUDkG92KuxVNIfK3meeFJodIvZYZVDxyJbSsrKwqGUhaEE&#xA;ZaMGQixE/JxZa/BEkHJAEf0gv/wh5s/6sl//ANIs3/NOH8vk/my+RY/yjp/9Uh/ph+t3+EPNn/Vk&#xA;v/8ApFm/5px/L5P5svkV/lHT/wCqQ/0w/W7/AAh5s/6sl/8A9Is3/NOP5fJ/Nl8iv8o6f/VIf6Yf&#xA;raPlHzYBU6LfgDqfqs3/ADTj+XyfzZfIr/KGn/1SH+mH60uubS7tX4XMMkD/AMsilDt7MBlRBHNy&#xA;YZIyFxIPuUsDN2KuxVNIfK3meeFJodIvZYZVDxyJbSsrKwqGUhaEEZaMGQixE/JxZa/BEkHJAEf0&#xA;gv8A8IebP+rJf/8ASLN/zTh/L5P5svkWP8o6f/VIf6Yfrd/hDzZ/1ZL
 /AP6RZv8AmnH8vk/my+RX&#xA;+UdP/qkP9MP1qVx5Z8yW0Dz3Ok3kEEYrJLJbyoijxLMoAwSwzAsxNe5lDW4JGozgSe6QS3KnKdir&#xA;sVdirsVdirsVdirsVdir038jdG9bVr3VnX4bSMQwk9PUlNSR7hVp9ObPszHczLueW9qNTw444x/E&#xA;bPuH7fue0ZvHiHYq7FXYqxf8y9G/Svk2/iReU1souofHlD8TU+achmJrsfHiPlu7XsXU+FqYnpL0&#xA;n4/tp85Zzb6W7FXYq+n/ACh/yieif8wFr/yZXOp0/wDdx/qj7nyvtH/GMn9eX3lNsucN2KuxV2Kq&#xA;VzaWt1EYbqFJ4W6xyqHU/QwIyMoiQoi2cMkoG4kg+TBPM35OaBqKPNpP+4286hVq0DH3Q7r/ALH7&#xA;s1+fs2Et4+k/Y7/Re0ebGayeuP2/t+PzeN695f1bQr5rLUoDDKN0bqjr/MjftDNNlxSgakHtdLq8&#xA;eeHHjNj7vel2VuS+n/KH/KJ6J/zAWv8AyZXOp0/93H+qPufK+0f8Yyf15feU2y5w3Yqx38xP+UJ1&#xA;f/jAf+JDMXW/3UnZdj/41j/rPmzOafTnYq7FXYq7FXYq7FXYq7FXYq+iPys0b9GeTbPkvGa9rdy/&#xA;89Psf8kwudFoMfDiHnu+b9u6nxdVLuj6flz+22W5mundirsVdirTKrKVYBlYUIO4IOJCQafL3mbS&#xA;G0fX7/TWG1tMyx17xn4oz9KEHOUzY+CZj3Pqui1HjYYz/nD7ev2pZlblOxV9P+UP+UT0T/mAtf8A&#xA;kyudTp/7uP8AVH3PlfaP+MZP68vvKbZc4bsVdirsVdirsVSjzP5Y03zFpb2N6grQmC4ABeJ+zKf1&#xA;jvlGfBHLGi5mh109NkE4fEd75w1zRr3RdVuNNvV4z27UJH2WU7q6+zDcZzWTGYSMTzD6ZpdTDPjG&#xA
 ;SPIvpDyh/wAonon/ADAWv/Jlc6bT/wB3H+qPufM+0f8AGMn9eX3lNsucN2Ksd/MT/lCdX/4wH/iQ&#xA;zF1v91J2XY/+NY/6z5szmn052KuxV2KuxV2KuxV2KuxVH6Dpcmq61ZacnW6mSMnwUn4m+hanJ44c&#xA;UhHvcfV5xixSmf4Q+pIo44o0ijULHGAqKOgAFABnVgUKD5RKRJs812FDsVdirsVdirxf88dGMOr2&#xA;WrIP3d3EYZSP9+RHYn5q34Zo+08dTEu97j2X1PFjljP8Jv4H9v3vMs1j1DsVfT/lD/lE9E/5gLX/&#xA;AJMrnU6f+7j/AFR9z5X2j/jGT+vL7ym2XOG7FXYq7FXYq7FXYq8z/O3y6txpUGuRL+/smENwR3hk&#xA;Pwk/6rn/AIbNV2nhsCY6PU+zGs4chwnlLce8fs+5m3lD/lE9E/5gLX/kyuZ+n/u4/wBUfc6LtH/G&#xA;Mn9eX3lNsucN2Ksd/MT/AJQnV/8AjAf+JDMXW/3UnZdj/wCNY/6z5szmn052KuxV2KuxV2KuxV2K&#xA;uxV6P+SOjG51+51R1/d2EXGM/wDFs1VFP9gG+/Nl2ZjufF3PM+0+p4cIxjnM/YP209uzevCuxVbL&#xA;LHDE8sjcY41Lux6BVFScBIAspjEk0OZQ2kalBqml2mowAiK7iSVVPUchXifcdMjiyCcRIdW3UYTi&#xA;ySgecTSLybS7FWI/mpox1TybdlF5TWRF3FT/AIrrz/5Js2YWvx8WI+W7uewdT4WpjfKXp+fL7afP&#xA;Gc6+juxV9P8AlD/lE9E/5gLX/kyudTp/7uP9Ufc+V9o/4xk/ry+8ptlzhuxVJfOeo3mneVtSvrKT&#xA;0rqCIvFJRWo1QK0YEH6RmPqpmGMkc3O7Nwxy6iEJC4kvGLP83/PME6yTXkd0gO8MsMSqR841jb8c&#xA;0se0MwPO/gHt8ns9pJChEx8w
 T+m3snk3zbZ+Z9IF9AvpTI3p3VuTUxuBXrtVSNwc3Wm1Ayxvq8V2&#xA;l2fLS5OA7joe8J7mQ692KpV5rskvfLOqWrioktZePswQsp+hgMo1MeLHIeTl6DKYZ4SHSQa8of8A&#xA;KJ6J/wAwFr/yZXDp/wC7j/VH3J7R/wAYyf15feU2y5w3Yqx38xP+UJ1f/jAf+JDMXW/3UnZdj/41&#xA;j/rPmzOafTnYq7FXYq7FXYq7FXYq7FX0D+UmjHTvJ0ErrSbUHa6fx4tRY/o4KD9OdD2dj4cd9753&#xA;7QanxNSQOUPT+v7WaZnOjdirF/zM1X9HeS9RdWpJcILaOnjMeLf8JyOYeuycOI+eztexMHiaqA6D&#xA;f5ftSz8mdV+ueURas1ZNPmeKnfg/7xT97EfRlfZuS8ddxcv2kwcGp4ukxf6Gd5sHn3YqtmijmieG&#xA;VQ8UilHU9CrChGAgEUUxkYkEcw+Wtd0uTStZvdOfc2szxhvFQfhb6Voc5TJDhkY9z6xpc4y4ozH8&#xA;QtA5BvfT/lD/AJRPRP8AmAtf+TK51On/ALuP9Ufc+V9o/wCMZP68vvKbZc4bsVY7+Yn/AChOr/8A&#xA;GA/8SGYut/upOy7H/wAax/1nzZnNPpz1v8hoLkDWJ6EWzeggPYyLzJp8g2/zzb9lA+o9Nnj/AGrl&#xA;H92P4t/ls9azcPHuxVDapKsWmXcrfZjhkZq7CgQnK8pqBPk24I3kiPMILyh/yieif8wFr/yZXI6f&#xA;+7j/AFR9zf2j/jGT+vL7ym2XOG7FWO/mJ/yhOr/8YD/xIZi63+6k7Lsf/Gsf9Z82ZzT6c7FXYq7F&#xA;XYq7FXYq7FUXpOnTalqlpp8P95dSpEp8ObAV+jrkoRMiAOrTqMwxY5TPKIt9TW1vFbW0VvCOMUKL&#xA;HGvgqCgH3DOrjERAA6Pk85mUjI8yqZJi7FXk357ar8OmaSrdS
 91Kvy/dxn8XzT9qZOUfi9h7K4Pr&#xA;yf5v6T+hLfyO1T0NdvdOZqJeQCRB4yQn/ml2yrszJUzHvDk+1GDiwxn/ADT9h/aA9rzevDOxV2Kv&#xA;EPzt0YWvmC31NBSPUIqSH/i2Cin/AIQrmh7Tx1Pi/nPd+zGp48Jxn+A/Yf2285zXPSvp/wAof8on&#xA;on/MBa/8mVzqdP8A3cf6o+58r7R/xjJ/Xl95TbLnDdiqWeZtJk1jQL3TIpFikuo/TWRgSAag1NMp&#xA;1GMzgYjq5Wh1Aw5o5CLES8zsvyIuPWU3uqoIAfiEMZLkeALEAfcc1cey5XuXqMvtVGvRDfzL1HRN&#xA;E07RdNi07T4/Tt4q0ruzMdyzHuTm2xYo448MXldVqZ55mczcijsscd2KsY/MrV10zyZqMnKktyn1&#xA;WEdy03wmnyTkfozE12ThxHz2dr2Lp/F1UB0ieL5ftTHyh/yieif8wFr/AMmVy3T/AN3H+qPucbtH&#xA;/GMn9eX3lNsucN2Ksd/MT/lCdX/4wH/iQzF1v91J2XY/+NY/6z5szmn052KuxV2KuxV2KuxV2KvQ&#xA;fyW0b655nk1B1rFpsRYHqPVlqif8LzP0ZsOzcfFkv+a877S6ngwCA5zP2Df9T3TN+8C7FXYq7FXY&#xA;q7FXYq7FWF/m5ow1DyfPMq1m091uUp14j4ZB8uLV+jMDtHHxY77neez2p8PUgdJ7fqfP2c++iPp/&#xA;yh/yieif8wFr/wAmVzqdP/dx/qj7nyvtH/GMn9eX3lNsucN2KuxV2KuxV2KuxV4T+bnm9NY1ddMs&#xA;35WGnEhnU1WSc7Mw9l+yPpzn9fqOOVD6Yvf+z3Zxw4/EkPXP7B+17B5Q/wCUT0T/AJgLX/kyubrT&#xA;/wB3H+qPueM7R/xjJ/Xl95TbLnDdirHfzE/5QnV/+MB/4kMxdb/dSdl2P/jWP+s+bM5p9Odirs
 Vd&#xA;irsVdirsVdir3v8AJ3RvqHlJbt1pNqMjTGvX01+BB/wpb6c3/ZuPhx3/ADnz72j1PianhHKAr48z&#xA;+PJnWbB0DsVdirsVdirsVdirsVU7q2huraa2mXlDOjRyL4q44kfccjKIkCD1ZwmYSEhzBt8sarp8&#xA;unandWE395ayvE3vwYiv05yk4mJIPR9YwZhkxxmOUhb6V8of8onon/MBa/8AJlc6fT/3cf6o+58w&#xA;7R/xjJ/Xl95TbLnDdirsVdirsVaZlVSzEKqipJ2AAxJSBbyj8xfzVi9KXSPL0vNnBS51BD8IB2KR&#xA;Huf8r7vHNPrNffph8/1PXdj9gmxlzD3R/X+r5vIs1D2L6f8AKH/KJ6J/zAWv/Jlc6nT/AN3H+qPu&#xA;fK+0f8Yyf15feU2y5w3Yqx38xP8AlCdX/wCMB/4kMxdb/dSdl2P/AI1j/rPmzOafTnYq7FXYq7FX&#xA;Yq7FVewspr6+t7KEVmuZUhj/ANZ2Cj9eGMSTQ6teXIMcDI8oi31PYWUNjY29lAKQ20aRRj/JRQo/&#xA;VnWQgIxAHR8ny5DkmZHnI2r5JrdiqG1HUrHTbN7y+mW3tY6c5X6DkQo/E5CeQQFnk24cM8shGAuR&#xA;Sb/lYnkn/q7wfe39Mo/O4v5zm/yPqv8AU5O/5WJ5J/6u8H3t/TH87i/nL/I+q/1OSbaVrGmatbG5&#xA;064S6gDGMyJ0DAAkb/MZdjyxmLibDiZ9Nkwy4ZjhKMyxodirsVeFfnRo31PzQl+i0i1GIOSOnqxf&#xA;A/8AwvE/Tmg7Rx8OS/5z33s1qePT8B5wP2Hcfpev+UP+UT0T/mAtf+TK5udP/dx/qj7nje0f8Yyf&#xA;15feU2y5w3YqhNV1O10vTp9Quywt7ZecpUcjTpsMhkyCETI8g3afBLLMQj9UmIP+c/ktVqGuXPgI&#xA;t/xYZg/ynj83cj2b1X
 9H5pPqX57aeqkabpksr/svcusYHvxT1K/eMqn2qP4Y/NzcPsrM/wB5MD3b&#xA;/fTz/wAyfmB5m8wBory59K0J/wB5IB6cX+y3LN/sic12bVZMnM7dz0Wi7IwafeIuXedz+z4MczHd&#xA;k7FX0/5Q/wCUT0T/AJgLX/kyudTp/wC7j/VH3PlfaP8AjGT+vL7ym2XOG7FWO/mJ/wAoTq//ABgP&#xA;/EhmLrf7qTsux/8AGsf9Z82ZzT6c7FXYq7FXYq7FXYqzr8nNGF95tW6daw6dE02/T1G+BB/wxYfL&#xA;M7s/HxZL7t3Qe0ep8PTcI5zNfDmfx5ve86F8+dirsVeb/njqfoaBZ6epo95PzYeKQrv/AMM65q+1&#xA;J1ER7y9P7L4OLNKf82P3/wBheJZpHuXYq9a/IjU99U0tj/JdRL/wkh/4hm27KnvKPxeP9qsH0ZPf&#xA;H9I/S9bzcvHuxV2KsE/OPRvr3lI3aLWbTpVmqOvpt8Dj/hg30Zr+0sfFjv8Amu/9nNT4eo4TymK+&#xA;PMMl8of8onon/MBa/wDJlcytP/dx/qj7nWdo/wCMZP68vvKbZc4bsVY7+Yn/AChOr/8AGA/8SGYu&#xA;t/upOy7H/wAax/1nzZnNPpzsVdirsVdir6f8of8AKJ6J/wAwFr/yZXOp0/8Adx/qj7nyvtH/ABjJ&#xA;/Xl95TbLnDdirHfzE/5QnV/+MB/4kMxdb/dSdl2P/jWP+s+bM5p9OdirsVdirsVdirsVZn5E/MOH&#xA;ypZ3UI0z65NdSB3m9f0vhRaKvH036Esa175m6XVjCDtd+bpO1exzq5RPHwiI5Vf6Qyj/AJX3/wBq&#xA;L/p7/wCvOZX8q/0ft/Y6r/Qn/tn+x/487/lff/ai/wCnv/rzj/Kv9H7f2L/oT/2z/Y/8ed/yvv8A&#xA;7UX/AE9/9ecf5V/o/b+xf9Cf+2f7H/jzCvPfnaXzXfW
 1wbX6nFbRGNYfU9X4mYlm5cU6igpTtmDq&#xA;tT4sgap3nZXZg0kDHi4jI86r9JYzmM7R2Kp55N80S+WdbTU0g+sqI3ikg5+nyVx/NxelGAPTL9Pn&#xA;8KfFzcDtLQjVYvDJ4d7vmz//AJX3/wBqL/p7/wCvObD+Vf6P2/see/0J/wC2f7H/AI87/lff/ai/&#xA;6e/+vOP8q/0ft/Yv+hP/AGz/AGP/AB53/K+/+1F/09/9ecf5V/o/b+xf9Cf+2f7H/jyH1D87ob6x&#xA;uLKbQaw3MTwyf6V+y6lT/un3yM+0xKJBjz8/2NmH2YOOYkMu8Tf0/wDHlPR/zs/R2k2Wn/ob1fqd&#xA;vFb+r9Z48vSQJy4+kaVp0rjj7T4YiPDyHf8AsZaj2Z8TJKfiVxSJ+nvN/wA5Gf8AK+/+1F/09/8A&#xA;XnJfyr/R+39jT/oT/wBs/wBj/wAed/yvv/tRf9Pf/XnH+Vf6P2/sX/Qn/tn+x/48lvmL85P0zol5&#xA;pf6I9D63H6frfWefHcGvH0lr08cqz9o+JAx4avz/AGOTo/ZzwcscniXwnlw/8eebZrXp3Yq7FXYq&#xA;7FXp+j/nZ+jtJstP/Q3q/U7eK39X6zx5ekgTlx9I0rTpXNrj7T4YiPDyHf8AseV1Hsz4mSU/Erik&#xA;T9Peb/nIz/lff/ai/wCnv/rzkv5V/o/b+xp/0J/7Z/sf+PO/5X3/ANqL/p7/AOvOP8q/0ft/Yv8A&#xA;oT/2z/Y/8eS3zF+cn6Z0S80v9Eeh9bj9P1vrPPjuDXj6S16eOVZ+0fEgY8NX5/scnR+zng5Y5PEv&#xA;hPLh/wCPPNs1r07sVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirs&#xA;VdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdi
 rsVdirsV&#xA;dirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVd&#xA;irsVdirsVdirsVdirsVdirsVdirsVdirsVf/2Q==</xmpGImg:image>
-               </rdf:li>
-            </rdf:Alt>
-         </xmp:Thumbnails>
-      </rdf:Description>
-      <rdf:Description rdf:about=""
-            xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
-            xmlns:stRef="http://ns.adobe.com/xap/1.0/sType/ResourceRef#"
-            xmlns:stEvt="http://ns.adobe.com/xap/1.0/sType/ResourceEvent#">
-         <xmpMM:InstanceID>uuid:48d7dac6-a6c2-f34d-8497-b10b25305818</xmpMM:InstanceID>
-         <xmpMM:DocumentID>xmp.did:F77F1174072068118083DC2D0C045B5E</xmpMM:DocumentID>
-         <xmpMM:OriginalDocumentID>uuid:5D20892493BFDB11914A8590D31508C8</xmpMM:OriginalDocumentID>
-         <xmpMM:RenditionClass>proof:pdf</xmpMM:RenditionClass>
-         <xmpMM:DerivedFrom rdf:parseType="Resource">
-            <stRef:instanceID>uuid:830e67ab-b668-fd42-8824-d82a4db061be</stRef:instanceID>
-            <stRef:documentID>xmp.did:F77F1174072068118083BFB0448CE18C</stRef:documentID>
-            <stRef:originalDocumentID>uuid:5D20892493BFDB11914A8590D31508C8</stRef:originalDocumentID>
-            <stRef:renditionClass>proof:pdf</stRef:renditionClass>
-         </xmpMM:DerivedFrom>
-         <xmpMM:History>
-            <rdf:Seq>
-               <rdf:li rdf:parseType="Resource">
-                  <stEvt:action>saved</stEvt:action>
-                  <stEvt:instanceID>xmp.iid:F77F1174072068118083BFB0448CE18C</stEvt:instanceID>
-                  <stEvt:when>2013-05-04T20:16:01-07:00</stEvt:when>
-                  <stEvt:softwareAgent>Adobe Illustrator CS5</stEvt:softwareAgent>
-                  <stEvt:changed>/</stEvt:changed>
-               </rdf:li>
-               <rdf:li rdf:parseType="Resource">
-                  <stEvt:action>saved</stEvt:action>
-                  <stEvt:instanceID>xmp.iid:F77F1174072068118083DC2D0C045B5E</stEvt:instanceID>
-                  <stEvt:when>2013-05-04T20:19:16-07:00</stEvt:when>
-                  <stEvt:softwareAgent>Adobe Illustrator CS5</stEvt:softwareAgent>
-                  <stEvt:changed>/</stEvt:changed>
-               </rdf:li>
-            </rdf:Seq>
-         </xmpMM:History>
-      </rdf:Description>
-      <rdf:Description rdf:about=""
-            xmlns:illustrator="http://ns.adobe.com/illustrator/1.0/">
-         <illustrator:Type>Document</illustrator:Type>
-         <illustrator:StartupProfile>Print</illustrator:StartupProfile>
-      </rdf:Description>
-      <rdf:Description rdf:about=""
-            xmlns:xmpTPg="http://ns.adobe.com/xap/1.0/t/pg/"
-            xmlns:stDim="http://ns.adobe.com/xap/1.0/sType/Dimensions#"
-            xmlns:stFnt="http://ns.adobe.com/xap/1.0/sType/Font#"
-            xmlns:xmpG="http://ns.adobe.com/xap/1.0/g/">
-         <xmpTPg:HasVisibleOverprint>False</xmpTPg:HasVisibleOverprint>
-         <xmpTPg:HasVisibleTransparency>False</xmpTPg:HasVisibleTransparency>
-         <xmpTPg:NPages>1</xmpTPg:NPages>
-         <xmpTPg:MaxPageSize rdf:parseType="Resource">
-            <stDim:w>512.000000</stDim:w>
-            <stDim:h>512.000000</stDim:h>
-            <stDim:unit>Pixels</stDim:unit>
-         </xmpTPg:MaxPageSize>
-         <xmpTPg:Fonts>
-            <rdf:Bag>
-               <rdf:li rdf:parseType="Resource">
-                  <stFnt:fontName>Meloriac-Regular</stFnt:fontName>
-                  <stFnt:fontFamily>Meloriac</stFnt:fontFamily>
-                  <stFnt:fontFace>Regular</stFnt:fontFace>
-                  <stFnt:fontType>Open Type</stFnt:fontType>
-                  <stFnt:versionString>OTF 1.200;PS 001.001;Core 1.0.29</stFnt:versionString>
-                  <stFnt:composite>False</stFnt:composite>
-                  <stFnt:fontFileName>meloriac.otf</stFnt:fontFileName>
-               </rdf:li>
-            </rdf:Bag>
-         </xmpTPg:Fonts>
-         <xmpTPg:PlateNames>
-            <rdf:Seq>
-               <rdf:li>Cyan</rdf:li>
-               <rdf:li>Magenta</rdf:li>
-               <rdf:li>Yellow</rdf:li>
-               <rdf:li>Black</rdf:li>
-            </rdf:Seq>
-         </xmpTPg:PlateNames>
-         <xmpTPg:SwatchGroups>
-            <rdf:Seq>
-               <rdf:li rdf:parseType="Resource">
-                  <xmpG:groupName>Default Swatch Group</xmpG:groupName>
-                  <xmpG:groupType>0</xmpG:groupType>
-                  <xmpG:Colorants>
-                     <rdf:Seq>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>White</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>Black</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>100.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Red</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Yellow</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Green</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Cyan</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Blue</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>CMYK Magenta</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=15 M=100 Y=90 K=10</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>14.999998</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>90.000000</xmpG:yellow>
-                           <xmpG:black>10.000002</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=90 Y=85 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>90.000000</xmpG:magenta>
-                           <xmpG:yellow>85.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=80 Y=95 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>80.000000</xmpG:magenta>
-                           <xmpG:yellow>95.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=50 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>50.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=35 Y=85 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>35.000004</xmpG:magenta>
-                           <xmpG:yellow>85.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=5 M=0 Y=90 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>5.000001</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>90.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=20 M=0 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>19.999998</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=50 M=0 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>50.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=75 M=0 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>75.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=85 M=10 Y=100 K=10</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>85.000000</xmpG:cyan>
-                           <xmpG:magenta>10.000002</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>10.000002</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=90 M=30 Y=95 K=30</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>90.000000</xmpG:cyan>
-                           <xmpG:magenta>30.000002</xmpG:magenta>
-                           <xmpG:yellow>95.000000</xmpG:yellow>
-                           <xmpG:black>30.000002</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=75 M=0 Y=75 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>75.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>75.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=80 M=10 Y=45 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>80.000000</xmpG:cyan>
-                           <xmpG:magenta>10.000002</xmpG:magenta>
-                           <xmpG:yellow>45.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=70 M=15 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>70.000000</xmpG:cyan>
-                           <xmpG:magenta>14.999998</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=85 M=50 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>85.000000</xmpG:cyan>
-                           <xmpG:magenta>50.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=100 M=95 Y=5 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>95.000000</xmpG:magenta>
-                           <xmpG:yellow>5.000001</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=100 M=100 Y=25 K=25</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>25.000000</xmpG:yellow>
-                           <xmpG:black>25.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=75 M=100 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>75.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=50 M=100 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>50.000000</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=35 M=100 Y=35 K=10</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>35.000004</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>35.000004</xmpG:yellow>
-                           <xmpG:black>10.000002</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=10 M=100 Y=50 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>10.000002</xmpG:cyan>
-                           <xmpG:magenta>100.000000</xmpG:magenta>
-                           <xmpG:yellow>50.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=95 Y=20 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>95.000000</xmpG:magenta>
-                           <xmpG:yellow>19.999998</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=25 M=25 Y=40 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>25.000000</xmpG:cyan>
-                           <xmpG:magenta>25.000000</xmpG:magenta>
-                           <xmpG:yellow>39.999996</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=40 M=45 Y=50 K=5</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>39.999996</xmpG:cyan>
-                           <xmpG:magenta>45.000000</xmpG:magenta>
-                           <xmpG:yellow>50.000000</xmpG:yellow>
-                           <xmpG:black>5.000001</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=50 M=50 Y=60 K=25</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>50.000000</xmpG:cyan>
-                           <xmpG:magenta>50.000000</xmpG:magenta>
-                           <xmpG:yellow>60.000004</xmpG:yellow>
-                           <xmpG:black>25.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=55 M=60 Y=65 K=40</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>55.000000</xmpG:cyan>
-                           <xmpG:magenta>60.000004</xmpG:magenta>
-                           <xmpG:yellow>65.000000</xmpG:yellow>
-                           <xmpG:black>39.999996</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=25 M=40 Y=65 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>25.000000</xmpG:cyan>
-                           <xmpG:magenta>39.999996</xmpG:magenta>
-                           <xmpG:yellow>65.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=30 M=50 Y=75 K=10</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>30.000002</xmpG:cyan>
-                           <xmpG:magenta>50.000000</xmpG:magenta>
-                           <xmpG:yellow>75.000000</xmpG:yellow>
-                           <xmpG:black>10.000002</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=35 M=60 Y=80 K=25</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>35.000004</xmpG:cyan>
-                           <xmpG:magenta>60.000004</xmpG:magenta>
-                           <xmpG:yellow>80.000000</xmpG:yellow>
-                           <xmpG:black>25.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=40 M=65 Y=90 K=35</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>39.999996</xmpG:cyan>
-                           <xmpG:magenta>65.000000</xmpG:magenta>
-                           <xmpG:yellow>90.000000</xmpG:yellow>
-                           <xmpG:black>35.000004</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=40 M=70 Y=100 K=50</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>39.999996</xmpG:cyan>
-                           <xmpG:magenta>70.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>50.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=50 M=70 Y=80 K=70</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>50.000000</xmpG:cyan>
-                           <xmpG:magenta>70.000000</xmpG:magenta>
-                           <xmpG:yellow>80.000000</xmpG:yellow>
-                           <xmpG:black>70.000000</xmpG:black>
-                        </rdf:li>
-                     </rdf:Seq>
-                  </xmpG:Colorants>
-               </rdf:li>
-               <rdf:li rdf:parseType="Resource">
-                  <xmpG:groupName>Grays</xmpG:groupName>
-                  <xmpG:groupType>1</xmpG:groupType>
-                  <xmpG:Colorants>
-                     <rdf:Seq>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=100</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>100.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=90</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>89.999405</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=80</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>79.998795</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=70</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>69.999702</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=60</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>59.999104</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=50</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>50.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=40</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>39.999401</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=30</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>29.998802</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=20</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>19.999701</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=10</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>9.999103</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=0 Y=0 K=5</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>0.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>4.998803</xmpG:black>
-                        </rdf:li>
-                     </rdf:Seq>
-                  </xmpG:Colorants>
-               </rdf:li>
-               <rdf:li rdf:parseType="Resource">
-                  <xmpG:groupName>Brights</xmpG:groupName>
-                  <xmpG:groupType>1</xmpG:groupType>
-                  <xmpG:Colorants>
-                     <rdf:Seq>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>R=255 G=67 B=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.003099</xmpG:cyan>
-                           <xmpG:magenta>87.389900</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.003099</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=75 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>75.000000</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=0 M=10 Y=95 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>0.000000</xmpG:cyan>
-                           <xmpG:magenta>10.000002</xmpG:magenta>
-                           <xmpG:yellow>95.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=85 M=10 Y=100 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>85.000000</xmpG:cyan>
-                           <xmpG:magenta>10.000002</xmpG:magenta>
-                           <xmpG:yellow>100.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=100 M=90 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>100.000000</xmpG:cyan>
-                           <xmpG:magenta>90.000000</xmpG:magenta>
-                           <xmpG:yellow>0.000000</xmpG:yellow>
-                           <xmpG:black>0.000000</xmpG:black>
-                        </rdf:li>
-                        <rdf:li rdf:parseType="Resource">
-                           <xmpG:swatchName>C=60 M=90 Y=0 K=0</xmpG:swatchName>
-                           <xmpG:mode>CMYK</xmpG:mode>
-                           <xmpG:type>PROCESS</xmpG:type>
-                           <xmpG:cyan>60.000004</xmpG:cyan>
-                           <xmpG:magenta>90.000000</xmpG:magenta>
-                           <xmpG:yellow>0.003099</xmpG:yellow>
-                           <xmpG:black>0.003099</xmpG:black>
-                        </rdf:li>
-                     </rdf:Seq>
-                  </xmpG:Colorants>
-               </rdf:li>
-            </rdf:Seq>
-         </xmpTPg:SwatchGroups>
-      </rdf:Description>
-      <rdf:Description rdf:about=""
-            xmlns:pdf="http://ns.adobe.com/pdf/1.3/">
-         <pdf:Producer>Adobe PDF library 9.90</pdf:Producer>
-      </rdf:Description>
-   </rdf:RDF>
-</x:xmpmeta>
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                                                                                                    
-                           
-<?xpacket end="w"?>
endstream
endobj
3 0 obj
<</Count 1/Kids[8 0 R]/Type/Pages>>
endobj
8 0 obj
<</ArtBox[0.0 0.0 512.0 512.0]/BleedBox[0.0 0.0 512.0 512.0]/Contents 270 0 R/LastModified(D:20130504202656-07'00')/MediaBox[0.0 0.0 512.0 512.0]/Parent 3 0 R/PieceInfo<</Illustrator 271 0 R>>/Resources<</ColorSpace<</CS0 272 0 R>>/ExtGState<</GS0 273 0 R>>/Font<</T1_0 267 0 R>>/ProcSet[/PDF/Text]/Properties<</MC0 268 0 R>>>>/Thumb 274 0 R/TrimBox[0.0 0.0 512.0 512.0]/Type/Page>>
endobj
270 0 obj
<</Filter/FlateDecode/Length 155>>stream
-H\ufffd<\ufffd\ufffd
-\ufffd@D\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd\u0774\ufffdh\ufffd"
-\u0142\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd
-�\ufffdy0\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd�\ufffdd\ufffd\ufffd#\ufffd\ufffd\ufffd
v\ufffd\ufffd1@a\ufffd\ufffdt\ufffd]<\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffdO*\u07ac\ufffd,\ufffdpb\ufffdfA}\ufffd9\ufffdsf\ufffdn\ufffd\ufffd_t\ufffd\ufffd$\ufffd@!\ufffd4T\ufffde\ufffdg\ufffd~\ufffd\ufffdZ\ufffd\ufffd\ufffd[\ufffdp\ufffd'\ufffd
endstream
endobj
274 0 obj
<</BitsPerComponent 8/ColorSpace 275 0 R/Filter[/ASCII85Decode/FlateDecode]/Height 64/Length 503/Width 64>>stream
-8;Z]!;/X<+#Xn-2J`STbiY9+%]B]I7J0V2o;cSYg-+1"5iN6g9W9D&L.c]SR;qE2Q
-V'l#Jr`KEMe5afLs474"n=T$(pDBAL1LDn"f(e"LY[A<;nMWmRR/#.emjG0U<hGf(
-56?RPd]H<5!rpTf$R9Xb_=9BWr-`K@QQoD9WiT=G1\$M/4\6L&oN1A^pWe7i.X/I?
-GjL/LU5E]uA*bXNOcI1XhmH1&YODDfG6$t_?1B;\14OaB&QAWkjuNH;s*sek2fWg4
-ms2n5H/]@nCFo43k^M@r14KR9A)'dHo/uP5rM14/Gs:ht:iIARp=Ack]8[8%+'Gmu
-e(-[Zj%itd]&eniroOV/Jm1-2q:j2s5$MargWiUrE*Mt&s"shj++A&j"rS$QU>#+/
-2uH<b;tV+/Fnr-:A^A+o?]3L+5PP<>Mt4VEs4q_jKUI33R=Di_\D<eWUf,dq1J7Rn
-7J[opc?#%[^Ah6.S%c5Xs',I%q>^K^rA+G7.([C~>
endstream
endobj
275 0 obj
[/Indexed/DeviceRGB 255 276 0 R]
endobj
276 0 obj
<</Filter[/ASCII85Decode/FlateDecode]/Length 428>>stream
-8;X]O>EqN@%''O_@%e@?J;%+8(9e>X=MR6S?i^YgA3=].HDXF.R$lIL@"pJ+EP(%0
-b]6ajmNZn*!='OQZeQ^Y*,=]?C.B+\Ulg9dhD*"iC[;*=3`oP1[!S^)?1)IZ4dup`
-E1r!/,*0[*9.aFIR2&b-C#s<Xl5FH@[<=!#6V)uDBXnIr.F>oRZ7Dl%MLY\.?d>Mn
-6%Q2oYfNRF$$+ON<+]RUJmC0I<jlL.oXisZ;SYU[/7#<&37rclQKqeJe#,UF7Rgb1
-VNWFKf>nDZ4OTs0S!saG>GGKUlQ*Q?45:CI&4J'_2j<etJICj7e7nPMb=O6S7UOH<
-PO7r\I.Hu&e0d&E<.')fERr/l+*W,)q^D*ai5<uuLX.7g/>$XKrcYp0n+Xl_nU*O(
-l[$6Nn+Z_Nq0]s7hs]`XX1nZ8&94a\~>
endstream
endobj
268 0 obj
<</Intent 277 0 R/Name(Layer 1)/Type/OCG/Usage 278 0 R>>
endobj
277 0 obj
[/View/Design]
endobj
278 0 obj
<</CreatorInfo<</Creator(Adobe Illustrator 15.0)/Subtype/Artwork>>>>
endobj
267 0 obj
<</BaseFont/TLLWZT+Meloriac-Regular/Encoding/WinAnsiEncoding/FirstChar 65/FontDescriptor 279 0 R/LastChar 116/Subtype/Type1/Type/Font/Widths[825 0 0 0 0 0 0 0 281 0 0 0 0 0 0 636 0 0 0 0 0 0 0 0 760 0 0 0 0 0 0 0 825 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 669 0 679]>>
endobj
279 0 obj
<</Ascent 1036/CapHeight 759/CharSet(/A/I/P/Y/a/r/t)/Descent -228/Flags 196640/FontBBox[-221 -228 1358 1036]/FontFamily(Meloriac)/FontFile3 280 0 R/FontName/TLLWZT+Meloriac-Regular/FontStretch/Normal/FontWeight 400/ItalicAngle 0/StemV 256/Type/FontDescriptor/XHeight 759>>
endobj
280 0 obj
<</Filter/FlateDecode/Length 541/Subtype/Type1C>>stream
-H\ufffd\ufffd\ufffdOLQ\ufffd\ufffdC\ufffd\ufffd\ufffdvi\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd
-\ufffd\ufffdT\ufffd\ufffd4$\ufffd&P\ufffdD\ufffdP\ufffd\ufffdd	\ufffd\ufffd\ufffdB\ufffdf+L\ufffd(\ufffd\ufffdD\ufffd\ufffd	\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdD=x\ufffdb\u6b6f
\ufffdH\ufffd^\ufffd\ufffd\ufffdd\ufffd|3\ufffd\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd7o\ufffd\ufffd\ufffdI\ufffd\ufffd\u024e!u|j2a\ufffd\u058e\ufffdf\u031a\ufffdY\ufffd(\ufffd\ufffd^\ufffdp\ufffdgY\ufffd\u0646\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd4\ufffd\ufffd\ufffd<\ufffd\ufffd(\ufffd\ufffddE5Sz\ufffd\u018c\ufffd\ufffd\ufffd\ufffd+MU\ufffde\ufffdcS\ufffd\ufffdCj\ufffd0-\ufffd\ufffd\ufffdDr\ufffdZ\ufffd^\ufffdk\ufffd#I#\ufffd7\ufffdn\ufffd\.\ufffdW\ufffd\ufffd\ufffd\ufffd;vIc\ufffd\ufffd\ufffd^r\ufffd\ufffd\ufffda@\ufffd\u7a22j\u020d\ufffd\ufffdB\ufffde4\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffdFQ
-=Go\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffde\ufffdX|6\ufffd\ufffdV\ufffd\ufffdzeVa\ufffdj\ufffd#},O\ufffd\ufffd\ufffdf\ufffd[\ufffd_\ufffd_\ufffdX%\ufffd\ufffd`\ufffd\ufffd\ufffdn\ufffd"\ufffd([\ufffd7\ufffd5!L\ufffd\ufffdc\ufffdp\ufffdJ\ufffd\ufffdKD\ufffd\ufffd\ufffd"[#\ufffd\ufffd\ufffdb\ufffd\ufffd\ufffd\ufffd\ufffdB|\ufffd@\ufffd\ufffd.C\ufffd\ufffd\ufffdkmtD\ufffdFB\u0493?.Xp\ufffd\ufffdC\ufffd\ufffd \ufffdU\ufffd\u0155nP\ufffdE`\ufffdZ\ufffd\ufffd\ufffd\ufffd_Dy\ufffd\ufffd\ufffd\ufffd�\ufffd\ufffd_\ufffd\ufffd\u01bd\ufffd\ufffdm\ufffd\ufffd\ufffd"\ufffd.C\ufffdg\u03ebecBO!\ufffdMs\ufffd\ufffd\ufffd\ufffd|\ufffd\ufffd\u03c3F\ufffd\ufffd%\ufffd^"\ufffd\ufffdhrG\ufffdxN\ufffd\ufffdL\ufffd\ufffdT\ufffd\ufffd\ufffdQgN\ufffd%\ufffdr\ufffd
endstream
endobj
273 0 obj
<</AIS false/BM/Normal/CA 1.0/OP false/OPM 1/SA true/SMask/None/Type/ExtGState/ca 1.0/op false>>
endobj
272 0 obj
[/ICCBased 281 0 R]
endobj
281 0 obj
<</Filter/FlateDecode/Length 389757/N 4>>stream
-H\ufffd\ufffd\ufffduT\ufffdK\ufffdtK\ufffd\ufffd\ufffdKJI,\ufffd\ufffdt(\u074b\ufffd4\ufffdK\ufffd\ufffd\ufffd%\u04b9\ufffdH\ufffd4J#\ufffd\u0492\ufffd(H
-w\ufffd\ufffd\ufffdq\ufffdy\ufffdy\ufffd\ufffd~\ufffd3\ufffd\ufffd\u0319g\ufffd<3\ufffd\ufffd\ufffdY9El
-@\ufffd ]\ufffd\ufffd!O\ufffd\ufffd-@\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd+BVKK
\ufffd\ufffd:\ufffdOX\ufffd~\ufffd\ufffd\ufffd\ufffd\ufffdWCa\ufffd\ufffd\ufffdiHKL\ufffd\ufffd\ufffd0\ufffdq\ufffdY\ufffd\ufffd\ufffd	`\ufffd5\ufffdc\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd
-X\ufffd]\ufffdx=\ufffd\ufffd\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffd	\ufffdX\ufffd\ufffd\u013f\u05fd\ufffd>\ufffd.\ufffdf\ufffd\ufffd\ufffd#aP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd		\ufffdD^{y8\ufffd\ufffd\ufffd\ufffd\ufffd	\ufffdd\ufffdpH\ufffd\ufffd	st\ufffd\ufffd:Y\ufffd\ufffd\ufffd\ufffd\u05eccxc
I\ufffdV\ufffd?S\ufffd\ufffd!\ufffd:\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd9[\ufffdYbQ\ufffdP\ufffd~\ufffd+rA
-S\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdHh\ufffd\ufffd\ufffdt^\ufffd\ufffd
\ufffd'0\ufffd\u07c5\ufffd�kY\ufffdX\ufffd\ufffdY9\ufffdYq\ufffdq\ufffdp\ufffd\ufffdl\ufffd'\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdz\ufffdE\ufffd\ufffd\ufffd\ufffdE$\ufffd%D>,\ufffd\ufffd^|t*K)\ufffd%/\ufffd`\ufffd\ufffd\ufffd\\ufffd\u04ab\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd&D\ufffd\ufffd\ufffd\ufffd[\ufffd7\ufffd\ufffddplDa5\ufffd|\ufffdmb\ufffd\ufffd\ufffd4\ufffd,\ufffdy\ufffdy\ufffd\ufffd{\ufffde\ufffd\ufffd5\ufffd
\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffd\ufffd\ufffd\u2685,t+w\ufffd\ufffdh\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdA
\ufffd\ufffd
\ufffd	\ufffdmk
-\ufffd\ufffdxYU\ufffd\ufffd\ufffd\uf4c0H\ufffd&%\ufffd\ufffd\u0224
-\ufffdq\ufffd\ufffdO'M\ufffdz\ufffd3\ufffdK\ufffdT\ufffd@v[NUnn^\\ufffdo\ufffd]\ufffda\ufffdb\ufffdTr\ufffd\ufffdt\ufffdl\ufffd\ufffdmE]e~U\ufffd+\ufffdj\ufffd\u05d0\ufffdZ\ufffd:\ufffdz\ufffd\ufffda\ufffdq\ufffdi\ufffd\ufffd\ufffd\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd};\ufffdC\ufffdS\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffd\_\ufffd\u06c6w\ufffd\ufffd\ufffd\ufffd\ufffdC\ufffda\ufffd\ufffdQ\ufffd1\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;>\ufffdL$Lz}4\ufffd\ufffd:%8M7\ufffdl\u030e\ufffd\ufffd\u03a7/\ufffd}\ufffdXT^\ufffd]\ufffdX>\\ufffdYm[\ufffd\ufffd\ufffdn\ufffd!\ufffdycsk\ufffd\ufffdk\u01b6\ufffd\u02b7;\ufffd\ufffdv{\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffdI\ufffds\ufffd\ufffd\ufffd0\ufffd\ufffd\ufffdX\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u076f\ufffd3\ufffds\ufffd\U000dd2d2\ufffd&\ufffd$\ufffd\ufffdW\ufffdWW\ufffd*\ufffd\ufffd)\ufffd\ufffd\ufffd!\ufffd$\ufffd$\ufffd%\ufffd!e$c\ufffd\ufffdHNOAKIMEq\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0195;KL\ufffdw\ufffd@\ufffd\ufffdY\ufffdX;\u061a\ufffd\ufffd8^\ufffd+\ufffdDsp\ufffd\ufffd\ufffd\ufffdf\ufffd\ufffd\ufffdK\ufffdO\ufffd\ufffdTC\ufffdP\ufffdp\ufffdJ%\ufffd\ufffd\ufffdD=\ufffd\ufffd+\ufffd+\ufffd\ufffd\ufffdO%$*\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd8\ufffdI\ufffdZ\ufffd\\ufffdZ\ufffd^\ufffdU\ufffdK\ufffd_wL\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd"d\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd9\ufffd=\ufffd;\ufffd\ufffds\ufffd\ufffd\ufffd_G\ufffd8/\ufffd\u0339N!G\ufffdz\ufffd[<\ufffd=\ufffd\ufffd2\ufffd|B}\ufffd\ufffd\ufffd\ufffdP\ufffdQ\ufffdz\ufffdl\ufffdH0Wc(E\ufffde\ufffdn\ufffd|\ufffdPds::5&8
 9\ufffdy\ufffdF\ufffdT"o\ufffd\ufffdd\ufffd\u4cd4\ufffd\ufffd\ufffdi\ufffd/Z\ufffdK^&gd:fg\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdl\ufffd
\ufffd\ufffdkJ\u0425\ufffde\ufffd\ufffd\ufffd\ufffdJ\ufffd*\ufffd+\ufffd\ufffd\u7bcdk\ufffdj5\ufffd\ufffd\ufffdU\ufffd\ufffd\ufffd[\ufffdZU\ufffd\ufffd\ufffdh\ufffd\ufffd0\ufffd|\ufffde\ufffdm\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd6\ufffd]B\ufffd@\ufffd`\ufffdP\ufffdp\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd?QM1Ms\u03c8\ufffd*\ufffdi\u03db.\ufffd\ufffdZ[JY\ufffdZ)X-]\ufffd\ufffdR\ufffd\u07b8\u047a\u067e\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffd\ufffd@\ufffd\ufffd?\ufffd\ufffd5\ufffd \u01d6'v\ufffdN\ufffd\ufffdg\ufffd\ufffd\ufffd\ufffd
-\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffdg\ufffd\ufffd\ufffd\ufffdL\ufffdC#u!\ufffd\ufffdM\ufffdM\ufffdM\ufffdE\ufffdvAms\u02d4F\ufffdV\ufffdN\ufffd\ufffd\ufffdA\ufffd\ufffd\ufffd\u031dGL\ufffdw\ufffdA\ufffd\u032c,\ufffd\ufffdl\ufffdl\ufffd\u063fs\ufffd\u075b\ufffd\ufffd\ufffd\ufffdn\ufffd\ufffd\u037d\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd!B\ufffd�"\ufffd\ufffd<b\ufffd\ufffd4$\ufffd\ufffd\ufffd\ufffd\u0747kR\ufffd\u0493\ufffd\ufffde\ufffdd\ufffd\ufffd\ufffdk*\ufffdJ\ufffd\ufffdY*/TS'<\ufffdS\ufffdV\ufffd\u0488\u050c\u040a\u040e\u0509\u040d\u040b\u040f0\ufffd4\ufffd2\ufffd\ufffd\ufffd\ufffd?M4I~\ufffdf\ufffd\ufffd\ufffd\ufffd\ufffds-\ufffd,\U000e1170"+\ufffdu\ufffdM\ufffdm\ufffd]\ufffd}\ufffdC\ufffdc\ufffdS\ufffdQ\ufffd\\ufffdR\ufffdZ\ufffd\ufffds\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdG\ufffd\ufffdi\ufffd\ufffdH\ufffd\ufffd\ufffd\ufffd3G\ufffdF\ufffdFaG\ufffdD\ufffd\u01ac\ufffd\ufffd\u010d\ufffd\ufffd&\ufffd$V''g\ufffd$\ufffdF\ufffd\ufffd\ufffdLG\ufffd\ufffd\u02f0\ufffd4\u0342d\ufffd\ufffd\ufffd\ufffdj\ufffdi\ufffdkh\ufffd\ufffdC\ufffdf%V\ufffdNe\ufffd\ufffdAq\ufffdYU\ufffd\u06aaG^/\ufffd\ufffd\u0543\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffdZ{\ufffdV\u06b1:\ufffd;\ufffd`\ufffd\ufffd=\ufffdc}\ufffd\ufffdn\ufffdK\ufffd
\ufffd\ufffd\ufffdFv\ufffd(\u0783\ufffd\ufffd> 'R&k?\ufffd\ufffd\ufffd3\ufffd?\ufffd4+:\ufffd6o\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffd\\ufffd\u04b1\u06bf6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffd\ufffd\u029d\ufffdo\ufffd\ufffd\ufffdF?L\ufffd\ufffd\ufffd\ufffdT;\ufffd:\ufffd>\ufffd::>\ufffd:\ufffd;\ufffd\ufffdeq\ufffdvx^sa\ufffd\ufffd\ufffdw\u0765\ufffd\ufffd\u0295\ufffd\ufffd'\ufffd_\ufffdE\ufffdF\ufffdO\D\ufffdK\ufffdLtAnF\ufffdF)F\ufffd
 |\ufffd\ufffd\ufffd\ufffd\u052d6\ufffd\\ufffd`\ufffd@z?\ufffdm+F\ufffd;\ufffdL\ufffdwiAh\ufffdy\ufffd\ufffd\ufffd\u0356\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffdg\ufffdw\ufffd~_
\ufffd@\ufffd\ufffd\ufffdZH_XA,\ufffd"F)\ufffd%\ufffd/\ufffd*9\ufffd\ufffd\ufffda\ufffdZ:\ufffdQ\ufffd\ufffd\ufffd,\\ufffdB^_AU\U000614802\ufffd
-\ufffd*\ufffd\ufffd\ufffd\ufffd'[j\ufffd\ufffdo5[\ufffd\ufffd\ufffd\ufffduR1u\ufffd\ufffdh`f\ufffdm$1\ufffdxJgBdr\ufffdl\ufffdt\ufffdl\ufffdy\ufffdy\ufffdE\ufffde$\ufffdfe\ufffdg-g#`\ufffddGbwj\ufffd\ufffd0\ufffd\ufffd\ufffdTOC9;\ufffd\ufffd\ufffd \ufffd\u0728\ufffd\ufffd\u077fx\ufffdz6z\ufffdx\ufffd\ufffd8\ufffd\ufffdI\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd=A\ufffd\ufffd\ufffd!.\ufffd\ufffda\ufffdAx\u06d1\ufffd\ufffd\u03ca\ufffd\ufffd\ufffd\ufffd}\ufffdb\ufffdG\ufffd-\ufffd\ufffd\ufffd\ufffd\u0792\u0113\ufffd\ufffd\ufffd\ufffdx\ufffd`\ufffdG\ufffd/\ufffd\ufffd\ufffd\ufffd\u051c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffd_\ufffdO\ufffd?\ufffd0\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u06ec\u056d\u042e\u02ef\u01f0\u0131�\ufffd\ufffd\ufffd\ufffd�\u0176\u0237\u0378\u04f9\u06fa\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \ufffd0\ufffd@\ufffdR\ufffdf\ufffdz\u018f\u01e6\u023e\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd*\ufffdG\ufffdc\u0400\u045f\u04bf\ufffd\ufffd\ufffd\ufffd'\ufffdL\ufffds\u065b\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdF\ufffds\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffd6\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffdZ\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffd?\ufffd~�\ufffd\ufffd~i\ufffd\ufffd~L}\ufffd\ufffd~cbA\ufffd~\ufffdDa\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffd~t\ufffdy\ufffd~W\ufffd\ufffd\ufffd\ufffd~O\ufffd\ufffd>~\\ufffd\ufffd\ufffd/~\ufffd\ufffd\ufffd|\ufffd~\ufffd\ufffd\ufffd`\ufffd\ufffd\ufffdC\ufffd\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}%\ufffd\ufffdH}\ufffd1\ufffdX}%\ufffdz\ufffd\ufffd}K\ufffd\ufffd\ufffd}\ufffd\ufffd
{N}\u05cb<_\ufffd~7\ufffd\ufffdA\ufffd~\ufffd\ufffd-\u03c8\ufffd\ufffd|
 \ufffd\ufffd\ufffd|\ufffd\ufffd\u01f2|+\ufffd\ufffdE|[\ufffd\ufffd\ufffds|\ufffd\ufffd\ufffdz}\ufffd\ufffd^\ufffd}w\ufffdO@\ufffd}\ufffd\ufffd-\ufffd~\u010b\ufffd\ufffd	{G\ufffdu\ufffd\ufffd{D\ufffdz\ufffd{]\ufffd\u012c\ufffd{\ufffd\ufffdf\ufffd{\ufffdZx\ufffd|[\ufffd\ufffd]\ufffd|\u03d5M?\ufffd}R\ufffd\ufffd<}\u018e\ufffd\ufffd\ufffdz\ufffd\ufffd]\ufffdYz\ufffd\ufffdH\u0127z\ufffd\ufffd\ufffd\ufffd|z\ufffd=\ufffd\ufffd{L\ufffdNw\ufffd{\ufffd\ufffd\ufffd\\ufffd|=\ufffd\ufffd>\ufffd|\ufffd\ufffdv|\u06d0I\ufffd8z/\ufffdr\ufffd
z\ufffd;\ufffdbz'\ufffds\ufffdMzd\ufffd6\ufffd\ufffdz\u026cqv\ufffd{D\ufffd[\ufffd{\ufffd\ufffd0>|;\ufffd|\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffda\ufffdIy\ufffd�\ufffd?y\ufffda\ufffd\ufffdzY\ufffd\ufffdvz\u076e\ufffd[{^\ufffd\ufffd=c{\u0424\ufffdI{R\ufffd\ufffd*y\ufffd\u07c4\ufffd\ufffdyf\ufffd\ufffd\ufffdUy`\ufffd\ufffdVy\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffduKz\ufffd\ufffdZi{\ufffd\ufffd<\ufffd{z\ufffd%\ufffdz\u020e\ufffd\ufffd\ufffd~+\ufffd~\ufffd}\ufffd\ufffd\u0347}W\ufffd\ufffd\ufffd0}3\ufffd\ufffd\ufffd}Ht\u0404\ufffd}\ufffdZk\ufffd\ufffd}\ufffd=\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffdz\ufffd\ufffd\u0247\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd!\ufffd~\ufffd\ufffd\ufffd\ufffd\u0404d\ufffd*s}\ufffd\ufffdY\ufffd\ufffd\ufffd<9\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffdS\ufffdw\ufffdu\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffdVrU\ufffd\ufffd\ufffdW\ufffd\ufffd\u0608|;,\ufffd\ub1d4\ufffd\ufffd{\ufffd\ufffd\ufffdR\ufffds\ufffd\ufffd\u0472\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;\ufffd\ufffd\ufffd\ufffd:\ufffd8\ufffd\ufffd\ufffd\ufffdq)\ufffdP\ufffdCV\ufffd\ufffd\ufffd:4
 .\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffd\ufffd\u0204\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\U000610a1?\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffdV\ufffdu\ufffd\ufffd9S\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffd\ufffdb\ufffd\u0583\ufffd\ufffd\ufffd\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffd\u0541N\ufffd\ufffdn\ufffd\ufffd	\ufffd\ufffdU\ufffd\ufffd38\ufffd\ufffd\ufffd8\ufffd\ufffd\ufffdA\ufffd/\ufffd\ufffd\ufffd\ufffd\u036c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u03b4z\ufffd\ufffd6\ufffd\u07c6\ufffd\u04e9\ufffdn1\ufffd\ufffd\ufffd\ufffdT\\ufffde\ufffd\ufffd7\u0740t\ufffdXT\ufffd\ufffd\ufffd\ufffd)\ufffd$\u0315\u032f\ufffd6\ufffd;\ufffd\ufffd\ufffde\ufffdC\ufffd\ufffd\u02b7\u02c6	\ufffdi\ufffd\ufffdmw\ufffd3\ufffd\ufffdS\u0180\ufffdV7M\ufffd
-\ufffd\\ufffd\ufffdl\ufffdG\ufffdN\ufffd\ufffd\u063b\ufffd\u0681\ufffd\ufffdN\ufffd\u0101\ufffda\ufffd5\ufffdt\ufffd\ufffdN\ufffd\ufffdzl\ufffd\u07f4\ufffdS<\ufffd\ufffdH6\ufffd\ufffd\ufffd*\ufffd\ufffd\ufffd<\ufffda|\ufffd\ufffdk\ufffdz|C\ufffdV\ufffd\ufffd|\ufffd\u01cd|\ufffd\ufffd\ufffd\ufffd|Ik\ufffd\ufffd\ufffd|\ufffdRu\ufffd\ufffd}26\ufffd\ufffd'~2\ufffd\ufffd\ufffd\ufffdF\ufffd-\ufffd\ufffd\ufffd\ufffdB\ufffd\ufffd\ufffd*\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffd\ufffd\ufffd\ufffd\ufffdQ^\ufffd\ufffd\ufffd@5z\ufffdI\ufffd`\ufffd\ufffd\ufffd\ufffd\u0673\ufffd\ufffd$\u011d\ufffd"\ufffd\ufffd\ufffd\ufffdc\ufffd\u07d8\ufffd\ufffd\ufffd&\ufffdU\ufffd\ufffd\ufffd\ufffdij\ufffd\ufffd\ufffd|PJ\ufffd\u02c7v4v\ufffdy\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd.\ufffd2\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u843ehS\ufffd\u63bcO[\ufffd\ufffd\ufffd3\ufffd\ufffd�\ufffd(\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\u044cx\ufffd&\ufffd$\ufffd\u051es\ufffd\u0489h\ufffd
-~\ufffd2\ufffd\ufffdgK\ufffd>\ufffd-N}\ufffdo\ufffd\ufffd2\u0646\ufffd\ufffd
N\ufffd%\ufffd\ufffd\u0567\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffdw\ufffd\ufffd\ufffd\u05a3A}\u21e4\ufffd\fX\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\u0758\ufffd2,\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdK\ufffd\ufffd\u0510\ufffd3\ufffd\ufffd\ufffd\ufffd\ufffdg\ufffd\ufffd\ufffd�\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffd}
-\ufffd0\ufffde\ufffd\ufffd6\ufffd\ufffdM\ufffd_\ufffd\ufffd1\ufffd\ufffd\ufffd?\ufffd\ufffd\ufffd1\u04e3\ufffd\ufffd\ufffd\u01fe\ufffd\ufffd\ufffdI\ufffd\ufffd^\ufffd\ufffd\ufffd\ufffdI|B\ufffd\u032fd\ufffd\ufffd\u072awL\ufffd\ufffd\ufffde1$\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdr\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd
\ufffd\ufffd1\ufffd\ufffd\ufffdS{\ufffd\ufffdz\ufffd|di\ufffd\ufffd\ufffd\ufffdL
\ufffd\ufffd\ufffdg0\ufffd\ufffd\\ufffd\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd{[\ufffd\ufffd\ufffdG{!\ufffd\ufffd\ufffd\ufffd{	\ufffd\u0794`{&y\ufffdE{xbi\ufffde{\ufffdJr\ufffd\ufffd|\ufffd/c\ufffd5}~
-~\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffdf\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffdKx+\ufffdC\ufffd\ufffda|\ufffdu\ufffd\ufffdI~\ufffd\ufffd\ufffd\ufffd.y\ufffdW\ufffd\ufffd	\u03ce\ufffd\ufffd\ufffd\u04d9\u07ce\ufffd\ufffd\ufffd%\ufffd�\u5518\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffdw!\ufffd^\ufffdT`\ufffd\ufffd\ufffd\ufffd^H\ufffd\ufffd*\ufffd\ufffd-\ufffd\ufffd\ufffd\ufffd\ufffd	5\ufffdG\ufffd\ufffd\u0228\ufffd\u760e\ufffd\ufffd=\ufffd\u03a0\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd\ufffdr\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd_\ufffd\u048dRG\ufffd\ufffdf\ufffd\ufffd,\u078b\u030b\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffd,\ufffd\ufffd\ufffd\u0195\ufffd\ufffd\ufffd\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0498\ufffdt\ufffd\u0655\ufffd^\ufffd\ufffd1\ufffd\ufffdF\ufffd\u0151\ufffd,;\ufffd'\ufffd\ufffd<\ufffd!\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffdl\ufffd~\ufffdJ\ufffd\ufffd\ufffdJ\ufffd\ufffdt\ufffdS\ufffd#]\ufffd\ufffd\ufffd\ufffd'FA\ufffd4\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd;\u06caL\ufffdP\ufffdf\ufffd&\ufffd\ufffd\u0254\ufffd\ufffd\u079d\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0568\ufffds@\ufffd\u590f]\ufffd0\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffd+:\ufffd\ufffd\ufffd\u0587SS	\U00027828\ufffd\ufffdjVPp,<XQ)\ufffdXVl\ufffd(Js\ufffd&\ufffdJ!\ufffd\ufffd\ufffd\ufffdK{\ufffd@B\ufffd\ufffdE\ufffd.\ufffde\ufffd\ufffd\ufffdWqQ\u4193\ufffd\ufffd\ufffd~3\ufffd\ufffd7\ufffd\ufffd\ufffdF\ufffdHI^\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u04e1\ufffd\ufffd\ufffd+j&Y\ufffd\ufffd\ufffdb\ufffddML\ufffd\ufffd\ufffd{#\ufffd\ufffd\ufffd\ufffd\ufffd)F\ufffd\ufffd\ufffdA\ufffd;q\ufffd\ufffdT0\ufffd\ufffd_\ufffd
^\ufffd\ufffd9I\u0764\ufffdx\u05ba\ufffd\u01a2YFh\ufffd9\u0545\ufffdhX;J\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd
 n+j\ufffd\u0121\ufffd(\ufffdm,\u05bcJ\ufffd\ufffd\ufffd\ufffd\ufffd(Va\ufffdV/\ufffd\ufffd\ufffda\u0611\ufffd@\ufffdQ~.\ufffd8_]\ufffd\ufffd\ufffd7]\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdg\ufffd|\ufffdF\ufffd)-\ufffd/\ufffd\ufffdMH\ufffd|\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd8\ufffd%\ufffdoFx\ufffd\ufffdC\ufffd\ufffd<\ufffd\ufffdR\ufffdl\ufffdA\ufffd^\ufffd\ufffd\ufffd\ufffdQ\ufffdl\ufffd\ufffdz\ufffdrJAU\ufffdU\ufffd\ufffd\ufffd\ufffdd*\ufffd\ufffd\ufffd\ufffdN\ufffd$i\u070f\ufffd
#\ufffdv
b7F\ufffd*4\u0782\ufffd\ufffd\ufffd
-
\ufffd\ufffd\ufffdpv\ufffdi\ufffdx\u0596\ufffd\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffdJ\u06f1\ufffd#\ufffd
-\ufffd\ufffdW\ufffd\ufffdh\ufffd\u0509\ufffdl\ufffd"\ufffdkxwVjG\ufffdDz\ufffd\ufffd\ufffd*\ufffd\ufffd\u07dcx\ufffdW\ufffd\ufffd\ufffd:\u01a9d\ufffd\ufffdP\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffd4W\ufffdM\ufffd\ufffd[\ufffd\ufffd,]\ufffd\u02ab$\ufffd\ufffd\ufffdW\ufffd\ufffd$I\ufffd&\ufffd\ufffdN\ufffd\ufffd\ufffd}\ufffd7�
s\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd1@\ufffd9\ufffdT\u024e.\ufffdE\ufffd\ufffdzN\ufffdDf\ufffd\ufffd*uwr \ufffd\ufffd\ufffd\ufffd	\ufffd*\ufffd#\ufffd\ufffd\ufffd\ufffd,\ufffdh\u0605\ufffd\ufffd"\ufffd8=\ufffd\ufffd\ufffdN\ufffd
\ufffd%\ufffd=(\ufffdp\ufffd\ufffd\ufffdQu\ufffd9s\ufffdL\u04d3(\ufffd&\ufffd\ufffdw\ufffd\u06be\ufffd?\ufffd\ufffdER\ufffdAHi.R\ufffd~	\u0504\ufffd6\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd*t\u04143*\ufffd\ufffd\ufffd\u06f1\ufffdx#\ufffdm?r~3\ufffd\ufffd2\ufffd+\ufffdw\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd6\ufffdyXa\ufffdTO\ufffd#\ufffd\ufffd
-U\ufffd�<\ufffd_)\ufffdI\ufffd(\ufffd\ufffd}\ufffd\ufffdW2S\ufffdX U\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd
M\ufffd\ufffdf\ufffd_T\ufffd)\ufffd\ufffd\ufffd\ufffd?k\ufffd\ufffdYYF\ufffd\ufffdK8\ufffd\ufffdu;J$\ufffd\ufffd�*1T\ufffd>,\ufffd\ufffd#h\ufffd%T\ufffd,\ufffdQ\u06e5{[\ufffd\ufffds\ufffd:\ufffd\ufffd9\U000c5f13\ufffd&^!\u0553\ufffda\ufffd\ufffd@\ufffd!\ufffd\ufffd"y\ufffd
-\ufffd\ufffd.\ufffd\ufffdJl6m\ufffdHj\ufffdu\ufffd,b\ufffdU6\ufffd+s\ufffd\ufffd\ufffdh\u0738d\ufffd-\u02a5\ufffd}\ufffdwi\ufffd\ufffd-s\ufffdun=0\ufffd\u013d\ufffdi-_\ufffd*)U\ufffd\ufffd_\u02c8\ufffd\ufffd\ufffd\ufffdb$\ufffd\ufffdna+;\u03e7T\ufffd;p\ufffdpA7\ufffd\ufffd\ufffd\ufffdC\ufffd4\ufffd\ufffd.*\ufffdI\u07e5\ufffda\ufffd8\ufffd\ufffdM\ufffd\ufffdm\ufffd.\ufffd\ufffd\ufffdACi\ufffd\ufffd\ufffd7\ufffd\j|fi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u052b)\ufffd\ufffd]\u07ad\ufffdj\ufffd\ufffd\ufffd\ufffd\u0284\ufffd\ufffd\ufffdU\ufffd]\ufffd3(�\ufffd\ufffdwh\ufffdJ\ufffd\ufffdc\ufffdh-\ufffd4x7\ufffd\ufffd\ufffdh\u05ff*P0\ufffdH\ub40eL\ufffd\ufffd\ufffd\ufffd\ub787\u06a1u\ufffd\ufffd�\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd,\ufffd{\ufffdBz}\ufffd\ufffd8\ufffdv\ufffdg\ufffdg\ufffd\u04b2\ufffdd[\ufffd!XTZ\ufffdZ.\ufffd\ufffdvl\ufffdA\ufffd\ufffd\ufffdg\ufffd\ufffd
-{;S\ufffdm\ufffd`v\ufffd\ufffd\u063f`~\ufffd?g\ufffda.\ufffd
-3\ufffd�\ufffd{\ufffd\ufffd\ufffd\ufffdL\ufffd^\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffde\ufffd4\ufffd\ufffd]\ufffdL\ufffd<pq\u07b4\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd!\ufffd\ufffdG\ufffd\ufffd]\ufffdlv\ufffd\ufffd\ufffd:DeH\ufffd\ufffdXq\ufffd\ufffdE\ufffd\ufffdK4kHoS|\ufffdX\ufffd\u05bdO\ufffd7\ufffd\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd*\ufffd*\ufffd+\ufffd\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffdh\ufffd`\ufffd\ufffd\ufffd?\ufffd\ufffd\ufffdk6\u0764g\ufffd\ufffd\ufffd,\ufffdM{ST3\ufffd\ufffd`\ufffdb5\ufffd\ufffdXE\ufffd#*\ufffd\u0456}\ufffdz\ufffd#C\ufffd//\ufffd\ufffd\ufffd\ufffd\ufffd7\ufffd\ufffd}\ufffd\ufffdV;\ufffd9\ufffdT\ufffd\ufffd)?\ufffd\u0788\ufffd\ufffd\ufffd2[\ufffd\u064f\ufffd]\ufffdn\ufffd$\ufffd~\ufffd\ufffd\ufffd\ufffdf\ufffd\u040c,\ufffdd\ufffd\ufffd\ufffdp,\ufffd\ufffdB\ufffdAdrH\ufffd\ufffd]`u\ufffd\ufffdP\ufffd\ufffdV\ufffdk\ufffdaEV\ufffdvYN\ufffd\ufffdU5/y\ufffdfD.\ufffd\u0761\ \ufffd1\ufffd\ufffd\ufffd\ufffdQ\ufffda#K\ufffd\ufffdE\ufffd:\ufffd|\ufffd\ufffdN[k\ufffd=\ufffd&[],\ufffd\ufffd\ufffd\ufffd1$\ufffd\ufffd\u03be\ufffdB\ufffd\ufffd\ufffd0Y\ufffd(\ufffd\u07caq$\ufffd\ufffd\ufffd]\ufffd!{Ik5\ufffdU\ufffd3\ufffdj\ufffd=Or\ufffd\ufffd\ufffd)\ufffd<V\ufffd\ufffd
A8H\ufffd\ufffd:YjD!\ufffd\ufffdL_\ufffd\ufffd|O\ufffd\ufffd\ufffd\ufffdl\ufffdxE{EY[\ufffd\ufffd9\ufffd\ufffd#Ev\ufffdx\ufffd\ufffd\ufffd2\ufffdE\ufffd\ufffdas=\ufffd[R\ufffd\ufffd\ufffdQ\ufffd\ufffdi\ufffd\ufffd*\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd66\ufffd`\ufffd\ufffd\ufffd\ufffd\ufffd\u03ce,\ufffd\ufffd+\ufffd#\ufffd,i\ufffd\ufffd1\ufffd\ufffd\ufffd\ufffdA2\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffd
 \ufffd\u01aa\ufffdW\ufffd\ufffd\ufffdm\ufffd\ufffd\ufffdH\ufffdXJ\ufffdNP\ufffd+\ufffd)\ufffd\u0327\ufffd+\ufffd\ufffd=l\ufffd\ufffd$\ufffdzU\ufffdkb\ufffd\ufffd]\ufffdi\ufffd\ufffd[:\ufffd\ufffd<\ufffd\u65f0\ufffd\ufffdA\ufffd\ufffdr)<\ufffd\ufffd\ufffd\ufffd\ufffd+e.\ufffd\ufffd
-\ufffd%\ufffd\ufffd\ufffd\u04c2\ufffdB\ufffds\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\u010f[\ufffd\ufffd~\ufffd}F.+}W\ufffd\ufffd\ufffd\ufffdt\ufffd=\ufffd\ufffd 
-\ufffd\ufffdK\ufffde&\ufffd\ufffd,\ufffd^\ufffd\ufffd-\ufffd\ufffdv\ufffda\ufffd(0\ufffd\ufffd\ufffd\ufffd\ufffdt\ufffdtz\ufffdS\ufffd\ufffd\ufffdw\ufffd0D\ufffd\ufffd6j\ufffd\ufffdtl\ufffd\ufffd.\\ufffdlV\u0564\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd-g\ufffd	[\u046d\ufffd'\ufffd\ufffdx\ufffd|\ufffd|D\ufffdD\ufffd\u07f5\ufffd\ufffd\ufffd\ufffd\ufffdv\ufffd\ufffdwi\ufffd\ufffd\ufffd8\ufffd\u01b0=\ufffd\u074b\ufffdbY\ufffd\ufffd
-\ufffd\ufffd\ufffdTC7j\ufffdKI\ufffd\ufffd\ufffdX\ufffd7\u043e\ufffds\ufffd{\ufffd\ufffdW|}\ufffd\ufffd&\u9977MR\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffdrs\ufffd%5\u052f1\ufffdG\ufffd\ufffd\ufffd*=\ufffd\ufffdV\ufffdDM\ufffd\ufffd\u9da2l\ufffd\ufffd\ufffd`JY\ufffd\ufffd\ufffd\ufffdKe\ufffd\ufffd\ufffd\+\ufffd\ufffdkl\ufffd=\ufffd\ufffd\u05bcsr\u034c\ufffd
-\ufffd\ufffd\ufffd\ufffd_L\ufffd\ufffd\\ufffdE\u070b\u02ae\u0724H)\ufffdB\ufffd\ufffd\ufffd"\ufffdn\u0115)J\ufffd\u06d9\ufffd\ufffd3g\ufffd\ufffdY\ufffdi&M{&M\u0374I\ufffd\ufffdB+!%\ufffd\ufffd,O\ufffd\ufffd\ufffd=Y>7o\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd\ufffd!w\ufffd\ufffd\ufffd\ufffdI\ufffd~\ufffdIr\ufffda^=\ufffdC\ufffd#Z\ufffd\ufffdh\ufffd\ufffd`W\ufffdu}p\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd"\ufffdz\ufffd7ff&\ufffd3\ufffd\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffd\ufffd\ufffdJ8\u04b65\ufffd\ufffd\ufffdm\ufffd
-u\ufffd\ufffdR\ufffd_,^V\ufffd\ufffdS&\ufffdaR\ufffd~Pf\ufffd\ufffdLL_Dw\ufffd\ufffd*\ufffd\ufffd`\\ufffd-\ufffd9]q\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffdI\ufffd6)\ufffd>u6	D\ufffd`e\u0362/\ufffd\ufffd\ufffdxq\ufffdY%\ufffd9\ufffd\ufffd\u029c\ufffd;\ufffd�O\ufffd\ufffdd\\u02fe\ufffdP\ufffd&eR\ufffdz\ufffd\ufffd;\ufffd]\ufffd\ufffd\ufffd\ufffd.\ufffdR\ufffd<o\ufffd\ufffd\u03a1\ufffd]\ufffdP{?\ufffd:\ufffdr\u0328\\ufffd\ufffd\ufffd\u02bbb	\ufffd\u04a4\ufffd3|\ufffd\ufffd\ufffd\ufffdm \ufffds\ufffd\u061f\ufffd\ufffd\ufffdW\ufffd9\ufffd\ufffd\ufffd\ufffdoZt]Rn\ufffd\ufffd�\\ufffdc\ufffdW\ufffd#+\ufffdn\ufffdI&\ufffdg\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffdAjs\ufffdN\ufffd06\ufffdHiD\ufffd\ufffd\ufffd\ufffd'@\ufffd\ufffd\ufffd\ufffdJ+\ufffd\ufffda5V~\ufffdcR\ufffdI\ufffd\ufffd\u032b\ufffdvwtU\ufffd\ufffdc[3+?F|l(\ufffd\ufffdi\ufffd\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffd^+O\ufffd?R\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\ufffd1\ufffdHqil\ufffd\ufffd$W�h\ufffd\ufffd\ufffd\ufffd=\ufffd\ufffd\ufffd(\ufffdRE
-\ufffd\ufffd1\ufffdB\ufffd\ufffdv\u045f\ufffd\ufffdn\ufffd\ufffdF/\ufffd\ufffd
Bs\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffdY\ufffd\ufffd\ufffd\ufffd9>\ufffd\u07163\ufffd\ufffd\u0217qI\ufffd\ufffd
\u06a3\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd_\ufffd1\u0223\ufffd\u03b2\ufffd\ufffdi\ufffd\ufffdJiX\ufffd0\ufffdWV\ufffd\ufffd\ufffdH[8g\ufffd\ufffd_\ufffd/\ufffd\ufffd\ufffd
-n3\ufffd`\ufffd	\ufffd\ufffd\ufffd38A.|\ufffdf|\u04580I\ufffd\ufffd6\ufffdb\ufffdv\ufffd%\ufffd&\ufffd ;Y\ufffd\ufffd\u3fdc\ufffd\u0484#\ufffdd\ufffd\ufffdD.)\ufffd\ufffd.p\ufffd'\ufffd\ufffd3\ufffdJ\ufffd12K[D\ufffdu\u0265$s8\ufffdI<\ufffdR\ufffdi\ufffdm\ufffdJ\ufffd\ufffd8\ufffd}\ufffd\ufffdf\ufffd\ufffd \ufffd\ufffd\ufffdDJ\ufffd\u0180\u0e83ws\ufffd!\ufffd\u02ab\ufffd\ufffd\ufffdr\ufffd\ufffdRX\ufffd\ufffd-\y^\ufffd*\ufffd\u030fLd'\ufffd\u96f29?)
"\ufffdq\ufffd\ufffd^\ufffd\ufffd5\ufffd/<4\ufffd\ufffdi
-\ufffd\ufffdQ<\ufffd\ufffd\ufffd\ufffd
-\ufffd\ufffd;/\ufffd\ufffd\u0531\ufffdJB"\ufffd\ufffd\ufffd7\ufffd\ufffdt\u035a\ufffd\ufffd,m\ufffd\ufffdXd\u06be^\ufffd;\ucd1e\ufffd\ufffd&s\ufffd`\ufffdY\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffd\ufffd\ufffd\ufffd\ufffd{>\u018a\ufffd.\ufffd\ufffd\ufffdz^48\ufffd\ufffde!\ufffd\ufffdR\ufffd6}\ufffd\ufffdvc\ufffd\ufffd\ufffd\ufffdMi\ufffdoz\ufffd\ufffd\ufffdo\ufffd0\ufffd'\ufffd=\ufffd~\ufffd\ufffd\ufffdi,3\ufffd:?-\ufffd\ufffd\ufffd?oS,\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd#\ufffd\ufffdR\ufffdOa\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;\ufffd	?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffdB\ufffd\ufffd\ufffd\ufffd
-\ufffd\u059eI\ufffd\ufffd\ufffd\ufffdO\ufffd\u075f\ufffde#}\u052f\ufffdN$\ufffd\\ufffdl?\ufffd]\ufffd,\ufffd\ufffd\ufffd\ufffdy,\ufffd\ufffd>&\u0420\ufffd\ufffd\ufffd\ufffdq]\ufffdyh\ufffd0Aq\ufffd\ufffdK)\u011dB\ufffdF\ufffd\ufffd\u048dcH:\ufffd\ufffd-h-\ufffd\u01dfc\ufffd\ufffd\ufffdf)\ufffdK9T\ufffd\ufffd127]\ufffd\ufffd\ufffd\ufffdq\ufffd\ufffdEjL\ufffd\ufffd\ufffd<>h\ufffd\ufffd;\ufffd|\ufffdU
-\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdd\ufffdp\ufffdG
-\u01ab\ufffd`\ufffd&!\ufffd\ufffd\ufffd8a\ufffd\ufffdl\ufffd\ufffd\ufffd`83>\ufffd.\ufffd\ufffdq\ufffd\ufffd\u0242\ufffdn\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdA\ufffd9
-;\ufffd\uf821\ufffd\ufffd\ufffd`\ufffd\ufffdH\ufffd\ufffdB\ufffdy\ufffdg\ufffd\ufffd\ufffdKB\ufffd\ufffd\ufffd*k\ufffd\u3c172fF\ufffd=#\ufffd\ufffdOM\ufffd\ufffd \ufffdeT?
-m\ufffd\ufffdTm\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffdOB\u06caV\ufffd\ufffd<\u0246F('\ufffdn3u\ufffdG~\ufffd\u022e#\ufffd7\u040a\ufffd9\ufffd\ufffd[\ufffd\ufffd\u0661`N\ufffds\ufffd.\ufffdP..\ucf64'Knp\ufffd\ufffdF\ufffd\ufffd\\ufffd?
\ufffdB>\ufffd\ufffd\ufffd-\ufffd\ufffd\ufffd\ufffd`\ufffd\ufffd\ufffd\ufffdN\ufffd\ufffdW\ufffdO\ufffdOW\ufffdB\ufffd\ufffd\ufffdl\ufffdf\ufffd\ufffdx\ufffd\ufffdW\ufffd^\ufffd<x==\ufffd\ufffd\ufffdZ/~\ufffd4/\ufffd.*g�\ufffdP\u02b2\ufffd<*V-}&\ufffd\ufffd\ufffd\u065f\ufffdw\ufffdz\ufffd\ufffdWq=g?:\ufffd\ufffd;[\ufffd\ufffd\ufffd-\ufffd(\ufffdZ6*<\ufffd\u0208\ufffd\ufffd`p?\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffdeQ\ufffdy\u045e>\ufffdb\ufffd\ufffd\ufffd-_\ufffdx&*/\ufffd\ufffd(\ufffdj\ufffd\ufffd\ufffd\ufffd_\ufffd=\u07c6\U000d12a2\ufffdzF\ufffd\ufffd\ufffd`\ufffdLd\ufffd\ufffdE:\ufffd\ufffd\ufffdSN\ufffd\ufffd\u0294@S\ufffd 0\ufffd\ufffd\ufffd3\ufffd|T\ufffdO\ufffdKo\ufffdk\ufffd\ufffdt\ufffd\ufffdo}bF\ufffd\ufffd\ufffdz$4\ufffd\ufffd\ufffd-\ufffd\ufffd\ufffd,\ufffd.m\ufffd\ufffd'j*J\ufffd\ufffd\ufffd|)J\ufffd6\ufffdB\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdP^\ufffd3ew\u072bpX\ufffd\ufffd\ufffd.\ufffd\ufffd*\ufffd\ufffd,0\ufffd\ufffd7xP\ufffd\u06b3\ufffd:2\ufffdX\ufffdOT\ufffd21|"7\ufffd\ufffd=<J}|\ufffdwl\\ufffd\ufffd}vGic\ufffd\ufffdQ\ufffd\ufffd\ufffd\ufffdS\ufffd]\ufffd<\ufffdC\ufffdj\u0239*	@8\ufffd-f\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0742={�(
\ufffd\ufffd\ufffd\ufffd]\ufffdx\ufffd\u0468\ufffdn\ufffd\ufffd\ufffd?\ufffd\u03d1]\ufffdq\ufffdO\ufffd\ufffd\u02cf\ufffdExyU\ufffd\ufffd\ufffdc\ufffd0\ufffd\ufffdt\ufffdM\ufffd]\ufffd\ufffdu3\ufffd\ufffd\ufffdj \ufffdo)(Co\ufffd\ufffd~2\ufffds\ufffd
 l\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd\ufffd\u0599\ufffd\ufffd
\ufffd{\ufffd\ufffdL\ufffd7z<\ufffd\ufffd"\ufffd!s\ufffd\ufffd\ufffd[\ufffd\ufffdH\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd*\ufffd{\ufffd\ufffd\ufffd1\ufffd\ufffdl\ufffd\ufffd1\ufffd\ufffd,V\ufffd\ufffd&I*[\ufffdv\ufffd$\ufffd#1/\ufffd\ufffd5\ufffdZ\ufffd\ufffd\ufffdp(3\ufffd\ufffd]\ufffd8\ufffd\ufffdi2|(\ufffd2\ufffd| z\ufffdD\ufffd\ufffd5 N\ufffds\u05ac\uf13f\ufffd\ufffd\ufffd\ufffdviV\ufffd`D\ufffd0�\ufffd\ufffd\ufffd]\ufffd\ufffd\ufffdR)L\ufffd!'n\ufffd\ufffd"\ufffd <v~\ufffdx\ufffd\ufffd)\ufffd~\ufffdif\ufffd\ufffd
-wnK\ufffd\u0711QV\ufffdB\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\u053dp\ufffd\ufffd *\ufffd+\u062a\ufffdED\ufffd\ufffd\ufffd*\ufffd \ufffd\ufffd\ufffd\ufffd\ufffd(\ufffd\ufffd\ufffdo	B\ufffd'{p\ufffd\ufffd\ufffdwH\u0606\u02b4*J\u046amA-n\ufffd\ufffdWjGE\ufffd\ufffd\ufffd\u07af\ufffdy~\ufffd~?r\ufffdI^WO\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffdl)\ufffd\ufffd\u01b6\ufffdW\ufffd\ufffdgiX\ufffd\ufffd\ufffd"\ufffdC\ufffd#\ufffdk\ufffd\ufffdnA\ufffd\ufffd\ufffd\ufffd\u02fb\ufffdr\ufffd\ufffd\ufffd)b\ufffd!\ufffdU\ufffd\u06b2I\ufffd\ufffd\ufffdb=\ufffd\ufffd>\ufffd0\ufffd\u07f4\ufffd\ufffd\ufffdy}\u0138B)H\ufffd[\ufffd\ufffd\ufffd\ufffd\ufffdFs\ufffd\ufffd\ufffdV\ufffd+\ufffd\ufffd\ufffd\u032f+Y(I\ufffd\ufffd\ufffd(\ufffd\ufffd\ufffd\ufffdx&\ufffd\ufffd9JAI\ufffd\ufffd\ufffd'tXm\ufffdy\ufffdG\ufffd=\ufffdX[8\ufffdTK\ufffd)\ufffd2\ufffd<\ufffdTSR\ufffdv\ufffdx\ufffd\ufffdl\u0213GO\ufffd|\ufffdg\ufffd/\ufffd{\ufffd>\ufffd\ufffd\ufffd4\ufffd\ufffd/\ufffdg\ufffdR\ufffd\ufffdF\ufffd\u0236\ufffd\ufffd&\ufffdA\ufffd5\ufffd\ufffd\ufffd2\ufffdu\u042f*B<\ufffdi\ufffd\ufffd\ufffd0\ufffdg\ufffdr+O\ufffd\ufffdA\ufffd\ufffd,0\ufffd\ufffd\ufffd-\ufffdb\ufffdu\ufffdg[\ufffd\~\ufffd-\ufffd\ufffd\ufffd\ufffd4:I>\u5e43A\ufffd\ufffduF\ufffd\u01de\u0467\ufffd\ufffdu\ufffdD\ufffd\ufffd\ufffd)B\ufffd,\ufffd*\ufffd?n\ufffd`	'qQIz\ufffd\ufffd\ufffdK\u0597\ufffd4\ufffd{\ufffd\ufffdB_g\ufffd6\ufffd8\ufffd#\ufffd\u02892.A\ufffd$69\ufffd!\ufffd\u0312\ufffdub1&D\ufffd3Q\ufffdx\ufffd\ufffd"\ufffd>\u024fn\ufffd\ufffd\u03bdx\ufffdVG\ufffd&\ufffd\ufffdT\u06e8\ufffd\ufffd\ufffd\ufffd�)\ufffdsx\ufffdd-5\ufffd\ufffdKx\ufffd\ufffd\ufffd\ufffd\ufffd\u07e3D&\ufffd\ufffd1\ufffd\ufffd\ufffd�\ufffd\ufffd\ufffdj\ufffdd\ufffd\ufffdG
 jJ\ufffd\ufffd|\ufffdJ\ufffd\ufffd{\ufffd\ufffdZ\ufffd\ufffd\ufffd\u07b2\ufffdf6\ufffd/vT\ufffdp\u0304ub\ufffd\ufffd
\ufffd\ufffdP\ufffd\ufffdmBU#g\ufffd\ufffd\ufffdB\ufffdg\u02f7\ufffd)\ufffd\ufffd-*\ufffdE
-ar\ufffd\ufffd\ufffd>\ufffd>\u01b5rn\ufffd[\u026d\ufffdF\ufffd-I\ufffd\ufffd\ufffdBy\u0478P\ufffd=\ufffd\ufffd\u0136K\ufffdUC
w\ufffd\ufffdG\ufffdD\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd"\ufffd\ufffdvN\ufffd\ufffd.p\ufffd]\ufffd]Q\ufffd\ufffd8u\ufffdY\ufffd\ufffd{\ufffd#q\ufffd\ufffdC\ufffd\ufffdv}sa\ufffd\ufffd\ufffdx_o\ufffd\ufffdy\ufffdiN\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffd
d8a\ufffdw\ufffd2C\ufffdQ\ufffd}V\ufffd8\ufffdUWO\\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffdyk\ufffd@\ufffd\ufffdd\ufffd\ufffd\ufffdc\ufffd\ufffdZ\ufffdt\ufffd\ufffd\ufffd9$\ufffd\ufffdu
-p\ufffd\ufffd-\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffdz(\ufffd=\ufffdf)
-\ufffdv\ufffd\ufffd\ufffd\u011b9\ufffd\ufffd\ufffd\ufffd2\ufffd w	u\ufffd\ufffd\u717c\ufffd\ufffd\u05ea\ufffd\ufffd#\ufffd\ufffd\ufffd\ufffd{P6\ufffd+D\ufffd\ufffdq3HIi\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffdB\ufffdC\ufffd\ufffdb\ufffd!\ufffd\ufffd\ufffdkc5\ufffd&U	):X\ufffd$\u070e\ufffd\ufffd\ufffd[\ufffd\ufffdb\ufffd2\ufffd*@\ufffdPkc\u04d8\ufffdd\ufffdoT\ufffdB_L1Uwi"\ufffd)\ufffd\ufffd=\ufffd2#\ufffd\ufffd\ufffdpI9,\ufffdR\ufffdO>\ufffdT@>\ufffd;\ufffdbn\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffdPuC\ufffd\ufffd\ufffd\ufffdfk\ufffd\ufffd\ufffd^\ufffd^\ufffd\ufffd\\ufffd\ufffdG~\ufffd
 \ufffd\ufffdo\ufffdL\ufffdRc\ufffdHq\u072e=-8^5O\u0144\ufffdy*9\ufffd\ufffd:-\\ufffdg8:T<\ufffd\ufffd?*\ufffd\ufffd\ufffd\ufffdC;\ufffd\ufffd[\ufffd\ufffd\ufffdy\ufffdX\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffdI\ufffd;\ufffd\ufffdlRL\u07ed\ufffd$D\ufffd\ufffdvY\ufffdTQ6\ufffdDy\ufffd\ufffdVm\ufffd\ufffdfy%/sIs\ufffd\ufffdmXP1\ufffdL\u057c\u022d\ufffd\ufffd\ufffd\ufffdvow)\ufffdQB\ufffdb\ufffd\ufffd\ufffd\ufffd_L\ufffdV\ufffdwu\ufffdp\ufffd\ufffd\ufffd\ufffde\u0117\ufffd\ufffd\ufffdO*\ufffd\ufffd|\ufffd+\ufffd]\ufffd(uH\ufffd\u05f04\ufffdW\ufffdU\ufffd\ufffd.\ufffd{ \ufffd4\ufffd\\ufffdm.Q\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffdR~MAi\ufffd\ufffd\ufffdRz+%\ufffdB\ufffd\ufffd\ufffd\ufffdK\ufffd\ufffdz\ufffd?'\ufffd{\ufffd\ufffd\ufffd\ufffdk\ufffd\u0489\ufffda\ufffd\ufffda\ufffd{\ufffd\ufffd\ufffdH]\ufffd\ufffdsX}d\ufffd\ufffd\ufffd\ufffda~\ufffd3\ufffd\ufffd_\ufffdau\ufffd\ufffd\ufffdQz\ufffd	\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdVM\\u0135v5I0\ufffdL\ufffdM\ufffd)\ufffd\u01c4\ufffdp\ufffd\ufffd\ufffd1\ufffd\ufffd:5\ufffd
 \ufffd,\ufffd&\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd%\ufffd\ufffd\ufffd!$}o\ufffd\ufffd\ufffdc\ufffd\ufffd\u07a4\ufffdA\ufffd]R^x\ufffd\ufffd\ufffdT\u25ecM&/B\ufffd:D\ufffdwA\ufffd\ufffd2\ufffd4\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffdc\ufffdd&g]5\ufffdb\ufffd\ufffd\ufffd4\ufffd\ufffd\ufffda?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdi\ufffd\u01d0\ufffd\ufffd  \ufffd\ufffd\u0108\ufffd\ufffd.OA
6\ufffdvfv\ufffds\ufffdd\ufffd\ufffd(5yT\ufffd\ufffdH\ufffd\ufffd\ufffd/P\ufffd\ufffd=\ufffd(\ufffda\ufffd\ufffd;zUs\ufffd\ufffdb\ufffdW\ufffd\ufffdx\ufffdDa\ufffd)E\ufffd\u02bc\ufffd	$\ufffdsg\ufffdPJ\ufffdr\ufffde\ufffdY\ufffd3\ufffdw\ufffd\ufffd`\ufffdc\ufffd\ufffdF\ufffdo\ufffd0|U[j5k\ufffd\ufffd.\ufffd5\ufffdJ\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffd\ufffde\ufffdT\ufffd\ufffdo\ufffdr	\ufffd\ufffdÈ´\ufffd\ufffd}I	l\ufffdp\ufffdjC\ufffd\ufffd\ufffd8c\ufffd\ufffd\ufffd5\ufffdJ=g\ufffd%U\ufffd\ufffdo\ufffd|L5\ufffd\ufffd8E"
-\u0650\ufffd\ufffd\ufffd[Ak]\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\u0346\ufffdVB\ufffdM\ufffd"{\ufffdN\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdih\u0426@\ufffdY?\ufffd\ufffd6\ufffd\ufffd^\u07ebZW\u066f\ufffd]\u0630\ufffd\ufffd\ufffdc\u060bh\ufffdKS\u01c8:>\ufffdO
\u0272\ufffd\ufffd\ufffd.\ufffd\ufffd\ufffd\u0770\ufffd\ufffdQ\ufffd{5mm<\u0677?^\ufffdv"\ufffd\ufffd}\ufffd\u044aw\ufffd\ufffd9\ufffd\ufffdO\ufffd\ufffd&\ufffdv\ufffd\ufffdX\ufffd7\ufffdkm[	\ufffd,70n\u03927|\ufffd\ufffde\ufffd\ufffdP\ufffd\ufffd\I;<\ufffd\ufffdu\ufffd^`u\ufffd!\ufffd\ufffd$P\ufffd\ufffd\ufffd\ufffdB
-ET9\ufffd\ufffd\u0672F\ufffd\ufffdW\ufffd\ufffdc\ufffd\ufffd\ufffd\ufffdm$\ufffd\ufffd="G
-}K\ufffde\ufffd\ufffd6\ufffd~\u0594G_\ufffd\ufffd\ufffdM\ufffdD\u053f\ufffds`\ufffd g\ufffd]\ufffdv\ufffdp-9\ufffd\N\ufffdd{:\ufffd:\ufffdgv\ufffdH\ufffd_3fC;}\ufffd\u0193P\ufffd\ufffd\ufffdN\ufffd\ufffd\ufffdp\ufffdH\ufffd\ufffd\ufffdd\ufffdU9u\ufffd;\ufffd\ufffd\ufffd9$8w\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffdr\ufffd#\ufffdA\ufffdF\ufffdiD1\ufffdn\ufffd\ufffd\ufffd\ufffd\ufffd-}\ufffd\ufffdt\ufffde\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffdH\ufffd!5$\ufffd\ufffd,I\ufffdQ:\ufffd\u0216R\ufffd\ufffd\ufffd1\ufffd3\ufffd\ufffd<\ufffd7\ufffd\ufffd\ufffdj\ufffd1\ufffd[\ufffd\u040aT\ufffd\ufffdm\ufffd\ufffd\ufffdWwzU\ufffdx\ufffd\ufffd|\ufffd\ufffd\ufffd\ufffd\u057e+\u0584{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\ufffd>\ufffd\ufffdp\ufffd\ufffd\ufffd:\u02a4\ufffdJRqY\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffd`\u01ef\ufffd<\ufffd~\ufffdj\ufffd\ufffd!m\ufffdr.\ufffdB\ufffd+\ufffd\ufffd'\ufffd\ufffd\ufffdOyY+\ufffd\ufffdfN*\u017ct
\ufffdW\ufffd$\ufffd\ufffdW\\ufffd2\ufffd\ufffd\ufffd\ufffdM_\ufffdc[\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdjj\ufffd%WuU{{\ufffd,_\ufffd\ufffdp\ufffdW\ufffd\ufffdn%}P\ufffdI^\ufffdW\ufffd|n�;c!\ufffdp\ufffd\ufffd\ufffdu\ufffdc\u02a8\ufffdN!k#\ufffd\ufffd\ufffd)k\ufffd\ufffdsd\ufffd\ufffd5n\ufffd�\ufffd6Q{H10\ufffd\ufffd\ufffdU\ufffd
-\ufffd\ufffd\ufffd-\ufffd"{\u2807TZG \ufffdR\ufffd,\ufffd\ufffd\u0247j\u08f6Zw8j	ICF\ufffd\ufffd\ufffd:\ufffdb[	\ufffd\+\ufffd?\ufffd
-\ufffd\ufffd\ufffdoA
n'a
-
-\ufffd\ufffdO\ufffdj0\ufffd\ufffd\ufffd`\ufffd%\ufffd\ufffd|\ufffd^\ufffd/si\ufffd_\ufffdX\u01e3\ufffdLqi\ufffdw]\ufffdI\ufffd\u03ad\ufffdD"J\ufffd\ufffd\ufffd!y\ufffd!\ufffd\u0536\ufffdn\ufffd\ufffd0\ufffdR\ufffd	z\ufffdWC\ufffd\ufffdc\ufffdc\ufffdh\ufffd\ufffd\ufffd\u016bK\ufffd_R
[\ufffd\ufffd*)!
OSo\ufffd\ufffdu\ufffd\ufffd\ufffdO\u0577\ufffd\u070cW\ufffd\ufffd\ufffdze\ufffdW\ufffdC\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\u03dd\ufffdL\ufffd\ufffd\ufffd/\ufffdQB\ufffdo\ufffd_\ufffd\ufffdk\ufffd/cg\ufffd\ufffd\ufffd&MV?\ufffd\ufffd\u05ab5z\ufffd\ufffd !g\ufffd\ufffd\ufffd\ufffd"?w\ufffd\ufffdP\u035a\ufffdI\ufffdQ"\ufffd\ufffd\ufffd\ufffdP\ufffdAdtE)q4\ufffd\ufffdj\ufffd\ufffd\ufffdG\ufffds\ufffd\ufffd\ufffdn\ufffd{"\ufffd\ufffd\ufffd\ufffd}e\ufffd\ufffdUM\ufffdrk\ufffd\ufffdzvi89C}\ufffd\ufffd\ufffdX\ufffdLB1W\ufffd".\ua55d^M\ufffd\ufffd\ufffd\ufffd\ufffdt?WK\ufffdL\ufffdw\ufffdDP]t\ufffdU\ufffd\u63ca1r\ufffdJ\ufffd\ufffd\ufffd\u0578K\ufffd\ufffdV\ufffd\ufffd\ufffd\ufffdGM;ph\ufffd\u0577m\ufffd \ufffdv>\ufffd\ufffd-wg\ufffd\ufffd\ufffd\ufffdFN\ufffd\ufffd\ufffdcI\ufffdP\ufffd#q\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffd;\ufffdN\ufffd\u0676\ufffd\ufffdA\ufffd)\ufffd\ufffd\ufffdH~\ufffd7i\ufffd t\ufffdhl\ufffd~\ufffd\ufffd~\u01f3\ufffdY\ufffd
C\ufffd\ufffd\ufffd\ufffdx\ufffd2>*c&\ufffdm\ufffdb\ufffd\ufffd\ufffd\ufffd{9f\ufffd1X*\ufffdL\ufffd\ufffd	\ufffd#>\ufffd\ufffd\ufffd
-
V@\ufffd\ufffd\ufffdg\u84bc]7n249=M\ufffd\ufffd\ufffd\ufffdK%
\ufffd;\ufffd\ufffd,\ufffd\ufffd\ufffd\ufffdF\ufffd\j\ufffd\ufffd1\ufffd\ufffdkl\ufffdZ\ufffdi\ufffd\ufffd\ufffd\u060a\ufffd\ufffd\ufffd\ufffd\ufffd\u0390\ufffd.|Q\ufffd\ufffd9\ufffd\ufffd\u0430\ufffd$_.!\ufffd\ufffd;\ufffd\u033f\ufffdl\ufffd\ufffd\ufffdE\ufffd,\ufffd\ufffd\ufffd\ufffd\u0265Di\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}D\ufffd\ufffd3^\ufffda`Y5\ufffdg{J=m\ufffd\ufffd\u0273\ufffd\ufffd\ufffdy\ufffd3\ufffd\ufffd\ufffdC\ufffdM'\ufffdjM\ufffd-i\ufffd\u0426\ufffdm\ufffd\ufffd\ufffdn5?	\ufffdSJ\ufffdE+U~ \ufffd;\ufffd\ufffd\ufffd\ufffdq.t\ufffdXd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd~p*Q\ufffdeS\ufffd\ufffd%\ufffd.\ufffd\ufffd\u040b\ufffd"\u01b0\ufffd\ufffdBs\ufffd\ufffd\ufffdZ\ufffd6-\ufffd\ufffd\ufffd\ufffd\ufffd6[\d;\ufffd^z4\ufffd`;64\u85f8\ufffd\ufffd\ufffd\ufffd\u0371w\ufffd\ufffd\ufffd;\ufffd\ufffd\ufffd\ufffd|\ufffd+&\ufffdA\ufffdf\ufffdLU\ufffd3\ufffd\ufffd\ufffdX\ufffdT\ufffd\ufffdm\ufffd\ufffd\ufffd)l\ufffdF\ufffd'l
\ufffdV\ufffd\ufffd\u027a\ufffdgcG\ufffdOb\ufffdb\u025c9\ufffd;v\\ufffdC\ufffd\ufffdL,\ufffd>B?\ufffdKGC\ufffd\ufffde"\ufffdz-@\ufffd\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd</\ufffds\ufffd=/\ufffd\u144dY\ufffd\ufffd\ufffd{\ufffd\ufffdP\ufffd\ufffdw\L\ufffd1A\ufffd|U{\ufffd_\ufffd\ufffd\ufffd\ufffd"\u0489w\ufffd+Gm\ufffd
\ufffd$\ufffd#\ufffdn\ufffd\ufffdo\ufffd\ufffd\ufffdx\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd}M\ufffd9\ufffdMb\u03a5\ufffd_@T\u0732\ufffd'1 \ufffd,\ufffdq\ufffd\ufffd$;\ufffd\ufffd!\ufffd\ud5c1h1kb\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdBo
-\ufffd\\ufffd\ufffdw\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffduY/|\u03d5d<w\ufffd\ufffd\u03a4c\ufffd~\u03ce\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd�\ufffd#d\ufffd\ufffdg3\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd\ufffdg\ufffd�\ufffd xT2\ufffd\ufffd\u0235\ufffd\ufffd6s3\ufffdi75\ufffd\ufffd\u01bb\ufffdZ\ufffdE\1\ufffd\\ufffd\u027a\ufffdW\ufffdA' \u05f2\ufffd\ufffd M	}?;\u0282\ufffd8|R\ufffd0S\ufffd#\u2763\ufffd\ufffd\ufffdC\u06ffU\ufffd\ufffdb0\ufffd\ufffd\ufffdL7\u05bd`\ufffd\ufffd\ufffdhcEk\ufffdT\\ufffdm\ufffd+	6\ufffd&\ufffd=\ufffd\ufffd\ufffd\ufffdB\ufffd9)\ufffd\ufffd\uaccc\ufffd\ufffd\ufffd\ufffd
\\ufffd@\ufffd^jk\ufffd\ufffda\ufffd\u019a\ufffd\ufffdPh\ufffd<\ufffd\ufffd=T\ufffd\ufffd6\ufffdK^MK\ufffd\u034b=\ufffd\u074a\ufffd$\ufffdQ\ufffd\ufffd\ufffd\ufffd-\ufffdU\ufffd&\ufffd>ILp<\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd'\ufffd\ufffd\u0489\ufffd\ufffd\ufffd\ufffd\ufffd$>\ufffd\ufffd8#\ufffdg\ufffdL\ufffd2\ufffdm\ufffd	\ufffd\ufffdc\ufffd\ufffd\ufffd\ufffd\ufffd1
\ufffd\ufffdc\ufffd\ufffd\ufffdF\ufffdw)\ufffdP\ufffd\ufffd+\ufffdr\ufffdkC
q\ufffdp/\ufffd\ufffdu8#\ufffd!\ufffd*g\ufffd\ufffd�\ufffdPa\ufffd`v\ufffdu\ufffd\ufffd@\ufffd\ufffdo\ufffdH\ufffd`"\u017d\ufffd\ufffd:\ufffdz\ufffd\ufffd\ufffd_\ufffd\ufffdQ<,D\ufffd>'\u04c5\ufffd\ufffdWP\ufffd\ufffd\ufffd .\ufffd\ufffd\ufffd\ufffd`\ufffdx\ufffdW\ufffd\ufffd3\ufffd|!6\ufffd\ufffd	\ufffd
-\ufffd5\ufffd\ufffd\ufffdEl\ufffd["\ufffd,0\ufffd	e\ufffd\ufffd\ufffd[Oz\ufffd\ufffd0~l\ufffdU\ufffdO\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd&x\ufffd\ufffdkP\ufffd\ufffdc|u\ufffd\ufffd$k\ufffd.\ufffd?\ufffd{Qp""k\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdr\ufffd6\ufffd\ufffdisV\ufffda\ufffd\ufffd\ufffd=~\ufffd@\ufffdW\ufffd_\ufffd
-.<\ufffd7\ufffd
-\ufffd\ufffd2\ufffd#h?c~\ufffdm'r\ufffd\ufffdE\ufffd_\ufffdxs\ufffd\ufffd6\ufffd\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdG\ufffd+\ufffd\ufffd\ufffdK1\ufffd\ufffd4\ufffd\ufffd\ufffdL^kUp\ufffd^^\ufffd\ufffd_\ufffd\ufffdm\ufffdS^d\ufffd\u0428\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd}\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd$:\u03c4!E\ufffd\ufffd[\ufffdb\ufffdJx&\ufffdn\ufffd t\ufffd(\ufffd\ufffdm\ufffd;Z\ufffd\ufffds\ufffdF5u\ufffdq\ufffdX\ufffd.\ufffd\u0542\ufffdBqKP\ufffd\ufffd\ufffd *\ufffd\ufffd\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd%{\ufffd\u0653{\ufffd'\ufffd\ufffdf';\ufffd,TT,\ufffdb\ufffd\ufffd\ufffdh\ufffdUq\ufffd2Z\ufffd\ufffd\ufffd3\ufffd\ufffd\ufffd;\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffdT9\ufffdvw\ufffd\ufffdR\ufffdR;GD\ufffd
-K\ufffd*\ufffd\ufffd/@hUv\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$\ufffdj\ufffd!\ufffd@\ufffd
\ufffdvy\u05d1m\ufffd\ufffd\ufffd,W\ufffd|-\u0362	\ufffd^\ufffd
\ufffd~\ufffdD\ufffd_\ufffd\ufffd\U00106b4d\ufffd"\ufffd\ufffd\u0109\ufffd\ufffd\ufffd\ufffd#c\ufffd\u7998\ufffd*\ufffdX/\ufffd\ufffd\u03dc\ufffde>\ufffd|\ufffdXH\ufffd\ufffd;\ufffd:\ufffd\ufffd)\ufffd\ufffd\ufffdd9g\u0196\ufffd4\ufffdaB\ufffd\ufffd\ufffd\ufffdQ4\ufffdE\ufffd\ufffdw\ufffd,C
-\u06efB\ufffdU\ufffd#\ufffd>\ufffdSV\ufffd$L\ufffd-\ufffd\ufffd5g\ufffdV	\u03ef*\ufffdB\ufffd\ufffd\ufffd\ufffd#\ufffd\ufffd}\ufffdnp\ufffd�\ufffdtd\ufffd\ufffd\ufffd\ufffd\ufffdU\ufffd$D\ufffdb&$^\ufffd\^\ufffd&Z"/\u02fa+\ufffd-}\ufffd\ufffd%\ufffdZ\ufffd\ufffd\ufffd:}\ufffd\ufffd9\ufffd\ufffd\ufffdA\ufffd\ufffdYu\ufffd\ufffd	\ufffd\ufffdrT\ufffdlP0\ufffd"\ufffd\ufffd\ufffd~!	\ufffd\u035a*@5K\ufffd?\ufffd\u07ebZ\ufffd-\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd=j\ufffd>\ufffd\ufffd\u0708\ufffd[\ufffd\ufffdO?)\ufffda5\ufffd
-\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffd\ufffdW\ufffd\ufffd\ufffdUs\ufffd\ufffd\ufffd\ufffdy\ufffd5^(ge\ufffd${C\ufffd\ufffd\ufffd\ufffdm>\ufffd	"\ufffd\ufffd\ufffdG\ufffd\u0563+\ufffd$\ufffd\u8e3f\ufffd\ufffd\u03eb&\ufffd\ufffd
Xw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd8?\ufffd\ufffdg\ufffd\ufffd,'\u014d\ufffd=\ufffd"\ufffd\ufffd\ufffd\ufffd/x\ufffd\ufffd\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffdM)\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdEF\ufffd\ufffdq\ufffdrf\ufffd
C\u012fQ9ZY\ufffd$r!\ufffd\ufffd\ufffd6m<YZ\u0421.\ufffd<\ufffd\ufffdV^\ufffdz{U\ufffdS=\ufffdP
-k\ufffdX%3\ufffdx\ufffd\ufffdfj\ufffd\ufffdn%^\ufffd\ufffd\ufffd\ufffd\ufffdi\U00034d7b\ufffd\ufffd\ufffds\ufffd\ufffd\ufffd3\ufffd0\ufffd\ufffd\ufffdq\ufffdh\ufffd$\ufffd\ufffd`k\u072f\ufffdD&\ufffd\ufffd!\ufffdM\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffdW\ufffd}\ud6cc1r\ufffd\ufffd\ufffd\ufffd=2N\ufffd\ufffdSd\ufffdk\ufffdb\ufffd\ufffd\\ufffd\ufffd\u0140\ufffdp\ufffd\ufffd\ufffdd\ufffdW}^\ufffd'\ufffdS^}\ufffd+P\ufffd0iC\ufffd\ufffd1\ufffdR\ufffd 0hDz[P\ufffd\ufffd\ufffd&!\ufffd\ufffdv@\ufffdB\ufffd\ufffd]P]V< \ufffdS\u0712G\ufffdL\ufffdO\ufffdNgK]+&\ufffd\ufffd-A
-\ufffd2\ufffd\ufffd\ufffd#\ufffdsL4\ufffdj\ufffd\ufffd&\ufffdD\ufffd\ufffd\ufffdi\ufffdb&,\ufffdA\ufffd\ufffdMS\ufffd\ufffd\ufffdU\ufffdD\ufffd\ufffd9\ufffd\ufffd\ufffdy\ufffd
-v\ufffd\ufffd\ufffd98\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffdc7MI\ufffd~\ufffd(\ufffdsL#\ufffd}\ufffd3\ufffd\ufffd\ufffd(M\ufffd^N\ufffdi\ufffdE\ufffdK\ufffdE8\ufffdmi\ufffd	u\ufffdzI\ufffd$N\ufffdr|}*\ufffd\ufffd+\ufffd'\ufffd4\ufffd\ufffdw\ufffd\ufffd\ufffd{\ufffdy%\ufffd\ufffdF $\ufffd\ufffd8\ufffd\ufffd@\ufffdN\ufffdz\ufffd\ufffd^G.g\ufffd\ufffd\ufffd\ufffd-1Vfk\ufffd)\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffdu\ufffd6K"\ufffd\ufffd\ufffdK\ufffd\ufffd\ufffd1\ufffdp\ufffd\ufffd\u039b\ufffdP\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffdr\ufffd\ufffd\ufffd>\ufffd)\ufffd4\ufffd
\ufffd\ufffdV\ufffd9\ufffdk\ufffdJ\ufffd$#\ufffd\ufffdF\u044c\ufffdX\ufffd\ufffd\u0665\ufffdC\ufffd\ufffdp\ufffd[\ufffd\ufffdg\u0327)C\ufffd\ufffd\ufffdS\ufffd;rFP#\ufffdI\ufffdm\ufffdK\ufffdG<\ufffd\ufffdh/\ufffd\ufffdU\ufffd-,C\ufffd\ufffdO\ufffdkOK\ufffdYY\ufffd;\ufffdMH-\ufffdt\ufffd\ufffd%\ufffd^N\ufffd\ufffd\u03be\ufffdB\ufffd\ufffd\ufffd7"
-\ufffd\ufffd\ufffdO\ufffdaj\ufffd\ufffdX\ufffd_84\ufffdV(N\ufffd\ufffd-{D)\ufffd\ufffdF\ufffd0\ufffd$\ufffd!\ufffdo\ufffdJ\ufffd\ufffdd\ufffdv/_\ufffd\ufffd(\ufffd\u01c0\ufffd\ufffdU\ufffdH8\ufffdB\ufffdc\ufffd1\ufffd\ufffd\ufffd\ufffdf\ufffdb5u\ufffd\ufffd&\ufffd*\ufffd\u04bd\ufffdn\ufffd2s\ufffd\ufffd\ufffdG40:\ufffd\=Y2\ufffd\u07ef	\ufffd$bi\ufffd8\u4eb5M\ufffd$\u0499:ut\ufffdN\ufffd)\ufffd\ufffdEh\ufffd\ufffdDh\ufffd\ufffdd\ufffdj\ufffd21|\ufffd*T\ufffd\ufffdV\ufffd\u02f0\ufffd\ufffd\ufffdT\ufffd5\u022eM7-\ufffd^\ufffd\ufffdS\ufffd\ufffd\ufffd84Te\ufffd\ufffdhR\u04a8j\ufffd[\ufffdU\ufffdG\ufffd\ufffdU\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffdK{\ufffdNh6v\ufffdg\u05a8\ufffd+\ufffd\ufffdG?\ufffd\ufffd\ufffd`
l\u0754$Rq-\ufffd.\u07a62\ufffd\ufffdS\ufffde\ufffd8pS\u0556\ufffdk!\ufffdX\ufffd\ufffdC\ufffd\\ufffdz0\ufffd0	nlh\ufffd\ufffdj\ufffd<~I\ufffd\ufffd\ufffd\ufffd\ufffd,K\ufffd\ufffd\ufffdr\ufffdL\ufffd)\ufffdIM\ufffd\ufffd\ufffd\ufffd9M\ufffd_\ufffd\ufffd\ufffdc+"v\u049c\u0764\ufffdL\ufffd\ufffd\ufffd$>\u027a\ufffd\ufffdz\ufffd\ufffd\ufffdj>>\ufffd\ufffdX\ufffd9,\ufffdZL-j\ufffd\ufffdIb\ufffdk\ufffd\ufffd\u02098\ufffd\u02da?v\ufffdt\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdP\ufffdIO}\ufffd_ay@\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd|Ve\ufffd6\ufffd\ufffd\ufffd\ufffd\ufffdubd/e\ufffd3<\u05ad\ufffdz\ufffdt\ufffd\ufffde\ufffda\ufffd\ufffd'\ufffdc\ufffdLaM
-\ufffdlz&,f^\ufffd_!\ufffd\ufffd?\ufffdl\ufffd\ufffd\ufffd\ufffd2x2\ufffdX\ufffdy\ufffd\ufffd\ufffd\u0144\ufffd3D\ufffd\ufffd\ufffd\ufffd)\ufffd\?\ufffdy\ufffde\ufffd~\ufffd\ufffd4\ufffd\ufffdO\ufffd+9$\ufffd
\ufffd
-\ufffd\ufffd\ufffdE\ufffdV\ufffdD<\ufffdO0\ufffdVbj&\ufffd\ufffdmLB\ufffd2Z\u0708\ufffdb9\ufffd\ufffdU\ufffd\ufffd;n\ufffd\ufffd\ufffd6L0	\ufffd+\ufffd\ufffdo\u02c7Cr\ufffdE.~\ufffd>T\ufffdS\u0613\ufffd7X\ufffd\ufffd\ufffd\ufffd?MM\ufffd!\ufffd\ufffd\ufffd\u053cu\ufffdO\ufffd\ufffdt\ufffd\ufffd\ufffd\ufffdPCbt;\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd\u07b0\ufffd\ufffda\ufffd\ufffd@gW\ufffd\ufffd#\ufffd@\ue7d6\ufffd\ufffd4c\ufffd9.D\ufffd\ufffd\ufffdo\ufffdz2>M\ufffd5\ufffd\ufffdi\ufffd~\ufffdu0\ufffd\ufffdq\ufffds\ufffdw\uebb4Q\ufffd9\ufffd\u01f8Lt\ufffd\ufffd\uc09f\ufffdMz)>\ufffd\ufffd\ufffdk\u025d\ufffd\ufffd\ufffdI\ufffd;\ufffd\ufffd\ufffdio\ufffd"\ufffd\ufffd\ufffdU)\ufffd\ufffd]$Y\ufffd\ufffd\ufffdL
>\ufffd$\ufffd\ufffd\ufffd\ufffd$T\ufffd\ufffd\ufffd\ufffd:gUo$\ufffd\ufffd\ufffdUK\ufffd\ufffd\ufffd,\ufffdC\ufffd`sCMAJM�\ufffd\ufffdK\ufffd\ufffdC(\ufffd\ufffdg]\ufffd\ufffd\ufffd\u066e9\ufffds\ufffdU\ufffdG\ufffd0?\ufffd\ufffd\ufffd\ufffdL\ufffd5\ufffd\ufffd\ufffd\ufffdQM%\ufffd\ufffd0O\ufffdl\ufffd\ufffd5&\ufffd\ufffd\ufffd`\ufffd\u01911,\ufffd\ufffdx\ufffd'\ufffd\ufffd\ufffd{\ufffd\ufffdk+\ufffdmY\ufffd}\ufffd\ufffd\ufffd\ufffd-J\ufffds#\\ufffd\ufffdd\ufffd\ufffd\ufffd:\ufffdi/\ufffdN\ufffdK\ufffd\ufffd\ufffd\ufffd\ufffd\8\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffdstQ#\ufffd\ufffd-\ufffdND\ufffd)\ufffd.s*\ufffdZ\ufffd\ufffd\ufffdy\ufffdm\ufffdn\ufffdf\ufffd\ufffd\ufffd\ufffd\\ufffd1l\ufffd\ufffd\ufffd\ufffd{\ufffd\ufffd(E\ufffd=\ufffdVGW\ufffd\ufffd9\ufffd\ufffds\ufffd:\ufffd\ufffd?\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\u01df\ufffdQ\ufffdZ\ufffdsC\ufffd\ufffd6\ufffd\ufffdA\ufffd1\ufffd\ufffd\ufffd\u0183\ufffd\ufffd6K\ufffd@\ufffd8\ufffd\ufffdO\ufffdUY\ufffd^\ufffd\ufffd`\ufffd\ufffd
 \ufffd7\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdj6\ufffd@\ufffd9?,y\ufffd\ufffd\ufffd\ufffdt4&\ufffd}"\ufffdT\ufffd\ufffd-
-\ufffd\Y&k\ufffd\ufffd\ufffdV\ufffd\ufffdx\ufffd\ub1633\ufffd\ufffd9\ufffd\ufffd1\u0675qQ\ufffd=\ufffdb\ufffdeMq\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd`/n\u0146|\ufffd\ufffd\ufffd2\ufffd\ufffd\u034cJkz\ufffdD\ufffdm\u036b\ufffdIR4\ufffd\~5Nl\ufffd\ufffd\u0585\ufffd\ufffd\ufffdK\u0241Z]T\ufffdC\ufffd3\ufffdl\ufffd\u0305\ufffd\ufffdD\ufffd3jSS\ufffd)\ufffdt\ufffd\ufffdWw$IX\ufffd[\ufffdw\ufffdV\ufffd\ufffd
-WT\ufffd\ufffd\ufffdU\ufffdw^P\ufffdeU\ufffd\ufffd\ufffd\ufffdh\ufffdWE\ufffd^\u0613~W\ufffdc\ufffdh\ufffd\ufffd\ufffds\ufffds\ufffd\ufffdI\ufffd\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd`\ufffd\ufffdw\ufffd\ufffdg\ufffds
(\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdmr\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd\ufffd\ufffdB`7Jf\ufffdA\ufffd\ufffd\ufffd\ufffdaA\ufffd3\u0193\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd?{\ufffdO[\ufffd?\ufffdx\ufffdj\ufffd/\ufffd\ufffd\ufffd\ufffdZ\ufffd*7\ufffde\ufffdx\ufffd\ufffdX\ufffdz\ufffd
\u0386\ufffd\ufffd})\ufffd\ufffdC\ufffd\ufffd\ufffd?`\ufffd\ufffdK\ufffdc\ufffdM\ufffd\ufffd\ufffd\ufffd\u054c\ufffd\ufffd&)\ufffd\ufffd\ufffd\ufffdY\ufffd5\ufffd\ufffd\ufffd\ufffdJ]q':]$\ufffd\u061e\ufffd]Yvx\ufffd(\ufffd\ufffd\ufffd\ufffd\ufffd\u0131\ufffd\ufffdH1\ufffd\ufffde\ufffdU\ufffd\ufffd\ufffd\ufffd>\ufffd_0\ufffdb\ufffd?*\U00078a0e\ufffdb\ufffd\ufffd\ufffd\ufffd�\u060c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffd\ufffd;W\ufffdxm]|N\ufffd7U\ufffd\ufffd13*\ufffd;\ufffd\ufffd.\ufffd=\ufffd\ufffd>\ufffd\ufffd\ufffdS\ufffd�j)\ufffd\ufffdCM\ufffd\ufffd>\ufffd\ufffd.\ufffd\ufffde\ufffdI\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffd/\ufffdQ\ufffdv\ufffd\u041d\ufffd\ufffd\ufffd6T\ufffdkk+\ufffd\u019cn\\\ufffdF\ufffdF\ufffd\ufffdV#\ufffd\ufffd\ufffdXd\ufffd\ufffd\ufffde\ufffd&~\ufffdWE\ufffd\ufffd7\ufffd"\ufffdbj\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffd^I@\ufffdj@\ufffdbQ\ufffdW\ufffd\ufffdk\ufffd\ufffd8\ufffd\ufffd\ufffdw\ufffd\ufffd_\ufffdD\ufffd\ufffd^\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd
x\ufffdZ\ufffdKA\ufffd_`\ufffdT}\ufffd]
-x\ufffd}\ufffd\u0401\ufffdM0S\ufffd,r\ufffd\ufffd\ufffd\ufffdV+	K\ufffd\ufffdO&\ufffd\u0188\ufffd`\ufffd;\ufffdE{irf0F\ufffd]\ufffd\ufffd w86f\ufffd\ufffd\ufffd\ufffd\ufffdfm_8\ufffd\ufffd\ufffdc3\ufffd\ufffd\ufffd\ufffdV\ufffd<)\ufffdr1\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffd +h\ufffd\ufffds|p\ufffd\ufffd!Q\ufffd\ufffdP'\ufffd\u0542\ufffd\ufffd\u029b\ufffd\ufffd\ufffd\ufffd2\ufffdr\ufffd\u04e4e\ufffd\ufffdj4Y\ufffd
r\ufffd\ufffd\ufffd,
\ufffdr\ufffd?4\ufffd! U\ufffd\ufffdq\ufffd]f\ufffd(\ufffd\ufffd*&umM+\ufffd;\ufffd1\ufffd
--\ufffd\ufffd\ufffdc\ufffd8\ufffdC\ufffd\ufffd\ufffdj\ufffdL=L\ufffd\ufffd1\ufffdTDJ\ufffd\ufffd\ufffd7\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd\ufffd)BH\ufffd*\ufffdc\ufffdHY}~\ufffdxI,{\ufffd\ufffd7\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdjW\ufffd\u07a7\ufffd\u0287\ufffd\ufffdh\ufffdg\ufffd_\ufffd\ufffd\ufffdYov\ufffdMKi\ufffd\ufffdN>\ufffd\ufffd\ufffdQ\ufffd\ufffdR\ufffd\ufffd\ufffd\u01e7}\ufffd\ufffdA\ufffd\ufffdQ\ufffdj^\ufffd\ufffdG\ufffds\ufffd\ufffdyJG"\ufffd?txt,L\ufffd\ufffd>\ufffd\u058dp\ufffd\ufffd_\ufffd\ufffd>\ufffdPo$\ufffd\ufffd^<\ufffd%}\ufffd\ufffd\ufffdK\ufffdD\ufffd\ufffdS4\ufffd
-\ufffd*S\ufffd<\u0716\ufffdy\ufffdd;\ufffd\ufffd\ufffd�IJ\ufffd\ufffd~J\ufffdM\ufffdn>\ufffd\ufffd\u0238cI6\ufffd\ufffdu\ufffd\ufffd\ufffd\u0256\u0698\ufffd\ufffd\u4a4ai77\ufffd_\ufffd5W\ufffd2'	9\ufffd\ufffdt\ufffd^}/\ufffd\ufffd8%wd\ufffd\ufffd\ufffd0k\ufffd\ufffd)\ufffd\ufffd\u0366\ufffdF9\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd\ufffdih\ufffd\ufffd3\ufffdSh\ufffd\ufffdPB\ufffdU\ufffdLz\ufffd\ufffds\ufffd\ufffd\ufffd'0\ufffd$Y\ufffd/L3\ufffd\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd|\ufffd\ufffdf\ufffd\u026a\AW#\ufffdsi\ufffd\ufffdS\ufffd-\ufffdO^\ufffdI\ufffd\ufffd+\ufffd3\ufffd\ufffd6\ufffd\ufffd\ufffdxas\ufffd\ufffd \ufffd\ufffd\ufffd@M\ufffd\ufffd
-\ufffdAh\ufffd\ufffdm\ufffd4\ufffd5V\ufffd-\ufffd\ufffd'\u0475\ufffd1\ufffd\ufffd\ufffdS+\ufffd\ufffd~*\ufffd\ufffd%~k\ufffd\ufffd\ufffd\u02dd\ufffd\ufffd\u0289l
\ufffd*\ufffd
-\ufffdl\u0643\ufffd=\ufffd3\ufffd\ufffd\ufffd_2~\ufffd\ufffd\ufffdOgP\ufffd\ufffds
-\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd[\ufffda\ufffd\u06d2{<\u0425\ufffd\ufffdj\ufffdA	{! \u07f2\u06d3\ufffd\ufffd\ufffd;O'\ufffd\ufffd9+wEH\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffd&\ufffdJ\ufffd\ufffdV\ufffd?f\ufffdi\u04fa j0\ufffd5\u7036bhW\ufffdZx\ufffdo=\ufffd\ufffd\u01ba0\ufffd\ufffd\ufffdz\ufffd\ufffd\ufffdhK5\ufffdm\ufffd\ufffd\ufffdo\ufffd\ufffdv(Y\ufffdOu\ufffd\ufffd\ufffdt\ufffd;\ufffd\ufffd\ufffde=\ufffd\ufffdR\ufffd*\ufffd\ufffdyMV\ufffdn\ufffd,\ufffd$v:\ufffd\ufffdQ\ufffd\u06b3E\ufffd\ufffd.\ufffdy\ufffdVl\ufffd;\ufffd\ufffdsvn\ufffd\ufffd,\ufffd\ufffdWi.[\ufffd\ufffd\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffd34S\ufffd\ufffdD_!\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffdF\ufffd>J\u67e3ND \ufffd\ufffd@$\ufffdY\ufffd~\ufffd-\ufffd\ufffd\ufffd\ufffdC\ufffdMu(+lBp\u0411\ufffd\ufffd^\ufffd\ufffd#$\ufffd~\ufffd2�
/@\u0323\ufffd6 3\ufffdn\ufffdh\ufffd
-\ufffd;\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u06ea.\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3F\ufffd\ufffdq3\ufffd\ufffd\\u064ev\ufffdZn\ufffdZ"/\ufffd\ufffdvNF\ufffd\ufffd\ufffd\ufffdN\ufffdJ2V{\ufffd#\u039aV\ufffds\ufffd\ufffd\ufffd\ufffde_\uc46e\ufffdT\ufffd\ufffda\ufffd8C�\ufffd!\u0397\ufffd\ufffd>F\ufffd\ufffdL\ufffd\ufffd\\ufffd\ufffdM{\ufffd\ufffd\ufffd5\ufffd\ufffdeH~7;F\ufffd\ufffd	\ufffd	\ufffdA\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdB?\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdY\ufffd=\u06e9\ufffd\ufffdQ i9\ufffdJ.s\u04ffc%\ufffd\ufffdFVb\ufffdd\u0565iL\ufffd\ufffd`\ufffda)kD\ufffd\ufffd\ufffd=W\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \n\ufffd\ufffd\ufffd\ufffde\ufffd>\ufffdN\ufffdX7\u0191�2I\ufffd\ufffdYf-\ufffdto7\ufffd\ufffd\ufffd/\ufffd~\ufffd\ufffdU\ufffd\ufffdas[\ufffd\ufffd`W\ufffd\ufffd*v3_\ufffd`~\ufffd\ufffd\ufffd\ufffd:k\ufffd\ufffd\ufffd\ufffdj\ufffdR("\ufffdE
-*\ufffd\ufffd\ufffd
-\ufffd\ufffde)DDI\ufffd\ufffdss\ufffd\ufffd,\ufffdf_n6\ufffd"\ufffd\ufffd\ufffd:hm\ufffdh+\ufffd]Aq�\ufffd\ufffdQq\ufffd\ufffdS\ufffda\ufffd\ufffd\ufffd\ufffd9\ufffd{~8\ufffd|\ufffd~b\ufffdh6\ufffdG\ufffd\ufffd\ufffdZ\u0120\u05ddN\\ufffdh\ufffd\ufffd+\ufffd\ufffd(E3\ufffd0\ufffd~\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdk\ufffdT\ufffdMG\ufffd\u03b2\ufffd\ufffd\ufffd\ufffd1\ufffd:zk\ufffda'L\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd2\ufffd>\ufffd\ufffd\ufffd\ufffd,gt\ufffd\ufffd\ufffdX&\ufffd@\ufffd?e%\ufffd
-\ufffd\ufffd\ufffd\ufffd\ufffd=@\ufffd\ufffdIh\ufffds\ufffd\ufffd\ufffd\ufffd)H\ufffd\ufffdU\ufffdOeX^m\ufffd\ufffd7R7\ufffd~\ufffd,\ufffd\ufffd\ufffd,\ufffd\ufffd\j\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\u050cf\ufffd\u036c\ufffd\ufffd\ufffd\ufffd\ufffd8!*\ufffd]\ufffdJR:\ufffd\ufffdW\ufffdR\ufffd]\ufffdM\ufffd\u025a\ufffd\ufffdP\ufffd\ufffdZ\ufffd\ufffd;\ufffd\ufffdJ\ufffdN\ufffd.8\u0266\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd,\ufffd[\ufffdr*\ufffd\u0391\ufffd]M\ufffd\ufffdM"wa\ufffdX)Lbjd\ufffd`\ufffd>:\ufffd?\ufffd\ufffd\ufffd\ufffd|:?u\ufffd\ufffd>^\ufffd\ufffdG\ufffd\ufffd\ufffd$\ufffd\ufffdfa\ufffd\ufffd.\ufffd
-\u02a5_\ufffdS\ufffd\ufffd%\ufffdED\ufffd8\ufffd\ufffdJ\ufffd\ufffd=\ufffd\u0115K\ufffd\ufffd\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd6rz\ufffdG\ufffd\ufffdG\ufffd\ufffd \ufffd\ufffd\ufffd\ufffd\ufffdU\ufffdi\ufffd<\ufffd\ufffd\ufffd\ufffdK\ufffdg\ufffd\ufffd"\ufffd\ufffd\ufffd^ \ufffdq\ufffd
-\ufffd\ufffd\ufffd\ufffdI6\ufffd\ufffd\ufffd\ufffdvP\ufffd\ufffd\ufffd\ufffdW\ufffdy^,\ufffd\ufffdu\ufffdc/5\ufffd\ufffd@\ufffd:\u01f9+[\ufffd\ufffdN\ufffd\ufffd+\ufffdl\ufffdi\ufffd{\ufffd\ufffdP\ufffd#^\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffdv\ufffd,�\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd-\ufffd\ufffdN\ufffd\ufffd\ufffd\u0473H\ufffd\u2ea3<\u05a1g\ufffdx\ufffd\ufffd\ufffdV\ufffd</\ufffd\ufffd\ufffdnb\ufffd\ufffd\ufffd6\ufffd\ufffd\ufffd\U000f4cdc\ufffd\u03a1 \ufffd+nhB\u02fe\ufffdP\ufffd\ufffdoT(\ufffdW\ufffd\ufffd#\ufffd#\u0109Tw\ufffdZU}\ufffd w-\ufffd\ufffdv\ufffd\ufffdT\ufffd\ufffd\ufffd\ufffd-9O\u1b7aHI\ufffdz)\ufffd\ufffd\ufffd\ufffd\ufffd \ufffdz\ufffd9\ufffd\ufffdR'\ufffdd\ufffdI5\ufffd\ufffda\ufffd\ufffdZ\ufffd\ufffdGS\u02df\ufffdag\ufffd\ufffdW=\ufffd\ufffd.\ufffdP1\u065c y?\ufffd\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffd\ufffdX\ufffd)r\ufffd4VaG\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffd\ufffd\ufffd\ufffdBe\ufffd`9\ufffdQ1\ufffd\ufffd\u035a@8\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffdW?\ufffdD\ufffd}\ufffd\ufffdz\ufffd\ufffd2\ufffd*\ufffd
-\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffdt\ufffd+\ufffd\ufffd\ufffd\ufffd;Br\\u0715\ufffd'>\ufffd\ufffd\ufffd-\ufffd\ufffdv\ufffd\ufffdC\ufffdNe\u0294\ufffd\ufffd\ufffd\ufffd\ufffdL-\u028c\ufffdq\ufffd\ufffdK\ufffdH\ufffd\ufffd\ufffdr\ufffd7\ufffdI\ufffd
d<\ufffd\ufffd\ufffd\ufffd\ufffdB\ufffdgNelB^\u0583R\u03b3F2\ufffd\ufffdA\ufffdqCR\ufffd&\ufffdt\ufffd\ufffd\ufffd7\u07c4\ufffd\ufffd{"D9\ufffd\ufffd\ufffd\ufffdu)\ufffd\ufffdC\ufffd\ufffdw\ufffd\ufffd\ufffd1\ufffd\ufffdt\ufffd}?"\ufffd\ufffd\ufffd'\ufffd[\ufffd7o\ufffd\u0329\ufffd~\ufffd1\ufffd{\ufffd>R\ufffdu*\ufffd\ufffd\ufffd\u0296d\ufffdC\ufffd\ufffdl\ufffd\ufffd\ufffdu\ufffdtqf\ufffd2[\ufffdl\ufffd~{S4\ufffd>\ufffdJ$\ufffd\ufffd\ufffd\ufffd.nQ\ufffdnl\ufffdP\ufffd#\ufffdx\ufffd\ufffd])By`r+\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffdLH?\ufffd\ufffd\ufffd\ufffdVD:\ufffd|\ufffd\ufffdiU\ufffdG\ufffd\ufffd~\u056a\ufffd+\ufffd\ufffd&+R\ufffd\ufffdb\ufffd gP\ufffd\ufffd>\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\u0539\ufffdk\ufffdQ\u01d6]WSkq\ufffdw\ufffd\ufffd\ufffdZ
-\ufffdD\ufffdQ\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdd\ufffd24\ufffd\ufffd\ufffd\ufffdK\ufffdG\ufffdM\ufffdv\ufffd\ufffd\ufffdU35\ufffd\ufffdK\ufffdJ~\ufffd4&j\ufffd\ufffdw\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffd*\ufffd\ufffdy\ufffd;\ufffd\ufffdX\ufffd\u07c9\u02d4\ufffd\ufffdO\ufffd\ufffd\ufffd@\ufffd\ufffd5\ufffdhw)\ufffd\U00058d15\ufffdo\ufffd-9E:\ufffd\ufffd_\ufffd\ufffd\u0302\ufffdo\ufffd\ufffd\ufffd\ufffd&\ufffd6#\ufffdV\ufffd\ufffd(\u047dS\ufffd-te$\ufffd\u05e4p}\ufffd4\ufffd%\ufffd4m\ufffdrn\ufffdz\ufffd\ufffd\ufffd\ufffdhe4\ufffdKX*\ufffd\ufffdK�\ufffd\ufffd\ufffd\ufffd2\ufffd9\ufffd\u02a9\ufffd~\ufffd\ufffd\ufffd'\u01e4\ufffdl|O5�B\ufffd
-\ufffd;\ufffd^\ufffd\ufffdj\ufffd\u36d1Q\ufffd`\ufffdexH\ufffd\ufffd;\ufffdJ\ufffd\*\ufffd`l\ufffd\ufffd\ufffd\u02f4K\ufffdh\ufffd\ufffdk
-&\ufffd\ufffd\ufffd\ufffdt\ufffd\ufffd\ufffdF|(\ufffd\ufffd8V\u01e1\ufffd\u0737\ufffdR\ufffd\ufffd\ufffd:\u03f3\ufffd\ufffdo\ufffdG*UjSKk\ufffd\ufffdnR\ufffd\ufffd\ufffdgl\ufffd\ufffd\ufffd\u0785-\ufffd6\ufffd\ufffd\ufffd&\ufffd\ufffdN\u0157\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7O\ufffd4\ufffd\ufffdrGm\ufffd\ufffdO[du_T\ufffd\ufffdvY\ufffd{\ufffd\u030fIy\ufffd\\ufffdaR\ufffdKy\ufffd\ufffd&\ufffdP\ufffd7\u076aJ)\ufffdl\ufffd\ufffd\ufffd"\ufffdW\ufffd5\ufffd{K\ufffd\ufffd \ufffd\ufffd\ufffdS_\ufffd\ufffd\ufffd\ufffdj0WSW;\ufffdw\ufffdix\ufffd\ufffdF1\ufffd^l\ufffd\u041e\u4f34^\ufffd'\ufffd1\ufffd\ufffd\ufffdb\ufffd%\ufffdOA\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffdhq)L\ufffd7\ufffd\ufffdj\ufffd}=\ufffd9PX\ufffd\ufffd=\ufffd\ufffdn\ufffd\ufffd`\ufffd\ufffd\u0257KX#C�\ufffdA
*7{\ufffd \ufffdj\ufffd\ufffdW\u0734T\ufffdBy\ufffd\ufffd\ufffd\ufffd\ufffduf\u05db\ufffd\ufffd\ufffdd=\ufffdA\ufffd\ufffdf\ufffd\ufffd]\ufffd\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffd=\ufffd_u*`\ufffdq\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd+\ufffd_i\u074b\\ufffd^`BaE\ufffd|\ufffdS&\ufffd\ufffd\ufffd\ufffd%Z\ufffd\ufffda\ufffd8\ufffd\ufffd\ufffd\ufffd+Q\ufffd\ufffdg\ufffdQ\ufffd[\ufffdIK\ufffd\ufffd-\ufffdj\ufffd\ufffdIKr2T\ufffdcju\ufffd=A\ufffd\u02a7\ufffdQ\ufffd"7\ufffd\ufffd{\u066e\ufffd\ufffd\ufffd\u05dd*\ufffdX|,Y\ufffd\ufffd\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd\u047d\ufffd\ufffd\ufffd\ufffd\ufffd}\ufffd\u0188f:\ufffdjCo[>\ufffd]\ufffd\ufffdx^\ufffd\ufffd\ufffdh\ufffd\ufffd\ufffd\ufffdlhNr\ufffd\u03f3EDk\ufffd\ufffdc\ufffdC\ufffd\ufffd\ufffd\u01ea
\u05ea9\ufffd\ufffdc	\ufffd\ufffd\ufffdH\ufffdt<)\ufffd\ufffd}\ufffdz\ufffd\ufffd!\ufffdhE~DB\u04f3\ufffd2\ufffdS\u0346\ufffd\ufffdi{;\ufffdo\ufffd\ufffdu\ufffd
 I\ufffd\ufffdp\ufffd??\u78034\ufffd6\u067a\ufffd\ufffd^"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd1\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd<\ufffd-\ufffd\ufffd65s\ufffd\ufffdj\ufffdp\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdSjqi6\u01f3\u06be\u0130\ufffd\u7d08\ufffd\ufffd4\ufffd\uf2c61\ufffd.\ufffd\ufffd$\ufffd5E\ufffdG\ufffd9\ufffd\ufffd\ufffd:\ufffd\ufffd=\ufffd\ufffdo\ufffd\ufffd\ufffdb\ufffd\ufffd\ucf84v#\ufffd\ufffd[\ufffd\ufffdx\ufffd\ufbe6\ufffdAF\ufffd+T\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(C@RQF\ufffd\ufffd7\ufffd7\ufffd2\ufffd\ufffdI$\ufffd\ufffd^a$\ufffdEq\ufffd\ufffd>\ufffd.\ufffdAE\ufffd\ufffdb\ufffd\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffdO0\ufffd\ufffd\ufffd\ufffd\ufffd]\u0422\ufffdK5\u03abP�\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd
\ufffd\ufffd\ufffd\ufffdZ\ufffdd\ufffd\ufffdJ\ufffd\ufffd\ufffd*\ufffd$d\ufffd\ufffd\ufffd\ufffd^\ufffd}E\ufffd*\u05a4\ufffd>?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0184\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$d\ufffd\ufffdO\ufffd\ufffd\ufffd	\ufffd_t\ufffdl\ufffd%\ufffd\ufffd$^7\ufffd\ufffd[\ufffdK\ufffd\ufffdS\ufffd\ufffdECq\ufffdz\ufffd"$]\ufffd*\ufffd\ufffd\ufffdB]\ufffd\ufffd}\ufffd\ufffdW\ufffd
zT[Rk\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd]\ufffdE\ufffd\ufffdU\ufffdYv\ufffd\ufffdFU\ufffdW\\ufffdB\ufffd\ufffd6\ufffd-RB\ufffd^M\ufffd\ufffde\ufffd2B\ufffd4\ufffd<ZR\ufffdV\ufffd\ufffdjV\ufffdy\ufffd~\ufffd\ufffdO\ufffd\ufffd
-W>\ufffd\ufffd/w\ufffd\u037a\ufffdh\ufffd4E\ufffd\ufffdk\ufffd5\u02d6\ufffd<1\ufffdU\ufffd\ufffd\ufffd[\ufffdt\ufffd\ufffd\ufffdD\ufffd\ufffd>\ufffdQ!\ufffd.kR\ufffd\ufffd\u6da7\ufffd7\ufffdu\ufffdJ\ufffd\ufffdc\ufffd>\ufffdc\ufffd\ufffd
-l\ufffd\ufffd\ufffd/\ufffd\ufffdi^\ufffd\ufffd3;i\ufffd\ufffd\ufffd\ufffd\ufffd\u0690\ufffd0\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\u0100\ufffd\ufffdZ\ufffdn\ufffdS\ufffd
-\ufffd\ufffd\ufffdq\ufffdW7\ufffdN\ufffd\ufffdp:\ufffd([\ufffd\ufffd\ufffd5\ufffd6\ufffd8\ufffd\ufffd\ufffdV\ufffdi\ufffdAF\u079c\ufffd~h\ufffd9\ufffdP\ufffdld�j\ufffd2\ufffddO
-\ufffd+\ufffd\ufffd\ufffd\ufffd6\ufffd\ufffd1\ufffd--\ufffd\ufffd1E\ufffd\ufffd\ufffdwv\ufffd\ufffd	\ufffd=JCH\ufffd\ufffdW\ufffd3\ufffd\ufffd4\u070f&\ufffdx\ufffd\ufffd8,\ufffd\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffd\ufffd#Rc\ufffd3D\ufffdvz\ufffd6\ufffd\ufffdRS\ufffd\ufffdyu\ufffd_N/nm\ufffd\u0643\ufffd\ufffdvT\ufffd\ufffd\ufffd\ufffd\u05a5Y\u02fc?\ufffd\ufffdRF\u05f0Kz\ufffdn\ufffd\ufffd9\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd4\ufffdg\ufffdC\ufffd^\ufffd5l`\ufffdP\\u0732\ufffd\ufffd\ufffd\ufffdG\ufffd&\ufffd\ufffd\ufffd\u07ab`\ufffd\ufffd
\ufffd\ufffd9\ufffdP\ufffd\ufffd\ufffd\ufffd\u049e\u0672X\ufffd\ufffd\ufffdr\ufffd6\ufffd\ufffd\ufffd
-V4,\ufffd\ufffd{\ufffda\ufffd\u0604\ufffd\ufffd\ufffd\tcY`]l\ufffd\u01ff\u053e\ufffda\ufffd\ufffd\ufffdr\ufffd\u9d2f\u060f=b\ufffd\ufffd!\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffdY\ufffdb

\ufffd^[\\ufffdaYt\ufffd$w	
-\ufffd\ufffd\ufffd[\ufffd\ufffdR\ufffd)\ufffd\ufffd\ufffdi\ufffd\ufffd[\ufffd{$\ufffd\ufffd7f"\ufffd\ufffdo\ufffd\ufffd\ufffdX\ufffd\ufffdp
-\ufffd\ufffdz\ufffdBz\ufffd\ufffd\ufffd\ufffd'h\ufffdO|\u014c4\u01d0\ufffd|-\ufffdj\ufffd\ufffd
-:\ufffd\ufffd\ufffd}\u0334a\ufffd%Tv\ufffd\ufffd5\ufffd\ufffdY9QK\ufffd \ufffdd0?\ufffd$\ufffd\ufffd\u0107H|\ufffd#\ufffdu\ufffdD\ufffd3\ufffdp\ufffd\ufffdh\ufffd\ufffd\ufffdr\ufffdd\ufffd@,@Xm\ufffd\ufffdVKY\ufffd\ufffd@o\ufffd\ufffdu\ufffd\ufffd([\ufffd\ufffd\ufffd8#!OM~\ufffd.\ufffd7SoJn%<\ufffd\ufffdI\ufffd\ufffddZ\ufffd\ufffd=\ufffd1\ufffdD3\ufffd!P#4\ufffd\ufffd\ufffd\ufffd(|:]SYd\ufffd\ufffd\ufffd_\ufffd\ufffdkG\ufffd\ufffd\ufffd\ufffd\ufffdRh\ufffd+Ot\ufffdB\ufffd\ufffd\ufffd%\ufffd/e\ufffd\u4c56\ufffd&]\ufffdh\ufffd\ufffdr5\ufffdsl\ufffdor\ufffd\ufffdQ\ufffd\ufffd\ufffd\ufffd"F\ufffd,b\u0553\ufffd*2~\ufffd\ufffd:\u02bc\ufffd\ufffdi\ufffd\ufffd[\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdt\ufffd\ufffd\u02e6\ufffd\ufffd\ufffd\ufffd~M
-\ufffdU\ufffd6\ufffdDU\ufffde\ufffd"udPO:\ufffd\ufffd\ufffd]\ufffdx+\ufffd\ufffd\ufffd\ufffdG\ufffd\ufffdB\ufffd\ufffd\ufffd]\ufffd\ufffdq:\ufffd\u02a5\ufffd'\ufffd:\ufffd-ML3\\ufffdF$\ufffd7\ufffdK\ufffd3\ufffdC\ufffd\ufffd*s\ufffd2\ufffd\ufffdz\ufffdF\ufffds\ufffd'\ufffd�\ufffd\ufffd\ufffd\ufffd\ufffd\u033cK\ufffd\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\ufffd\u04da\ufffd\ufffdw\ufffdER\ufffd\ufffd	\ufffd!`%aT\ufffd\ufffdH\ufffd\ufffdv\ufffdR\ufffdW\ufffd\ufffdSP\ufffd\u0185T\ufffd\ufffd\ufffd}FVArB\ufffd[\ufffd\ufffdSS &\ufffd\ufffd}p\ufffd`\ufffd	\ufffd~\ufffd\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd1{\ufffd,y\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd{\ufffd30\ufffd\ufffd[\ufffdb\ufffdK\ufffd\ufffd\ufffd:w\ufffd3\ufffd\ufffdMn\ufffd\ufffd\ufffd\ufffde6\ufffdsz/0<x\ufffd&\ufffd3\ufffdnj\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd_d
\ufffdK\ufffdB\u0653\ufffd! t\ufffdr\ufffd\ufffd!\ufffd6<\ufffd\ufffdr\u0195\ufffdKjT\ufffd;\u04bd\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffdZ\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd.,\ufffd\ufffd68\ufffdMUl\ufffd\ufffd{D6v\ufffd\ufffd\ufffd\ufffd@)tmp\ufffdy\ufffd_.>OG\ufffd"
-�3N\ufffd\ufffd|\ufffd\ufffd\ufffd/\ufffd'\ufffd\ufffdO\ufffd\ufffd-R_\ufffd1Vh&\u05faN\ufffdPz8de\ufffd\ufffd\ufffd
\u52caZTH;X\ufffd\ufffd\ufffd\ufffdQ\ufffd6\ufffd}\ufffd\ufffd+\ufffd\ufffd\ufffd'h\ufffd\ufffd_\ufffd|\u020b\ufffd\ufffdCc\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffdH\ufffd\ufffdj\ufffdBA\ufffd,\ufffdN\ufffdOS\ufffd\ufffd\ufffd{\ufffd3\ufffd\ufffd\ufffd	L\ufffd\ufffd\ufffd`]\ufffd\ufffd\ufffd1\ufffd\ufffd> A\ufffd\ufffd\ufffd
\ufffd\ufffdrx\u04f4\ufffd*E^\ufffd.\ufffd\ufffd\u0610`\ufffd\ufffd\ufffd\ufffdQ5\ufffdv{`=W6\ubf1f\ufffd\9a\ufffd\ufffd\ufffd\ufffdvGO\ufffd\ufffdXc&
v\ufffd\ufffd1\ufffd\ufffd\ufffdw\ufffd~\ufffd\ufffd\ufffd\ufffd0\ufffdW\ufffd:\u028e~\ufffd\ufffdf\ufffd\ufffd:
0\ufffd/\u02f5\ufffd\ufffd%\ufffdm\ufffdKRK\ufffdA\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffdR\ufffd%\ufffd	\ufffdP\ufffd#CS\ufffd\ufffd\u07e5\ufffdf\ufffdmD\ufffd5\ufffdoEx\ufffd\ufffd1\ufffd7B\ufffd\ufffd\ufffd\ufffd0\ufffd\ufffd\ufffd\ufffd<&\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdYd\ufffd8"1\ufffd\ufffdw\u07215\ufffd\ufffd TaaJ3p\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd7\ufffdA\ueabc>\ufffd\ufffd+\ufffd\ufffdy\ufffd\ufffdI\ufffd\ufffdM\ufffd\ufffd\ufffdc\ufffdu\ufffd\ufffd
Zd?\ufffdB\ufffd\ufffdk1\ufffd\ufffd\ufffdx-\ufffd\ufffd\ufffdr\ufffdsV\ufffd\ufffd9s\ufffdH6p]D\ufffdG\ufffdg\ufffdO|y\ufffd\ufffd5\ufffdS\ufffd$a\ufffdE\ufffd`$\ufffdLs
-[\ufffd\ufffdYm\ufffd
\ufffd~u\ufffd8\ufffd\ufffdp`6*I\u07d5\ufffd`S8\ufffd\ufffd\ufffd8s\ufffdn\ufffd\ufffd9O3nX\ufffdOE/7f\ufffd^\ufffdl\ufffdbN\ufffd[\ufffdPB\ufffdF\ufffdO\ufffd\ufffd.\ufffd9\ufffd\ufffd\ufffd\ufffdZ\ufffd\ufffd_.\ufffd5\ufffd>\ufffdF	\ufffd\ufffd\ufffdS\ufffd\ufffd\u0309\ufffdR\ufffd'}\u03aa\u046c`_d\ufffdX\ufffd|\ufffd{\ufffdd\ufffd\ufffdHX\u053e3\ufffdQlZe7P\ufffdR\ufffd\ufffdq\ufffd\u0634\ufffdO5\ufffd\ufffd\ufffd\ufffdOkZ\ufffd\ufffdr\ufffdx5u`a\u01c2:\ufffd\ufffd*`\ufffdT\ufffd)\ufffd\ufffd,\ufffd
-DPQ\u02ae\ufffd\ufffd\ufffdd\u07d3\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffdRk=H+
-*\ufffd#u)\ufffd\ufffd\ufffdh\ufffd\ufffd) \ufffd\ufffd)B\ufffd6\ufffd\ufffds\ufffd9\u07f9\u778f\ufffd\ufffdH\ufffdZG\ufffdz\ufffdG\ufffd\ufffd\ufffdT\ufffd"9\ufffd\ufffd3h\ufffdD\ufffd\u037a\ufffd\ufffds\ufffd\ufffdr|\ufffd\ufffdb\ufffd4\ufffd\ufffdy	\ufffd$\ufffd\ufffdTK	\ufffd\ufffd\ufffd"\ufffd$\ufffd\ufffdI\ufffd\ufffd~\ufffd$\ufffdv(\ufffdB\ufffd\ufffd#].\ufffd\ufffdqi\ufffd\ufffd?\ufffdC\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\u07b1\ufffd|\ufffd\ufffd\u0737\ufffdLcO\ufffdn\ufffd\ufffd\ufffdT~\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdvxj\ufffd\ufffd\u03265<.\ufffd\ufffdf\K<\ufffd\ufffd2p\ufffd:Cp\ufffd\ufffd\ufffdS\ufffdy,66\ufffd\ufffd>|z\ufffdC
-\ufffd\ufffd\ufffd\ufffdE
-T)\ufffd\ufffdf/\ufffd\ufffd:X1\ufffd}J+\ufffd\ufffd>\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffdQ;\ufffd^\ufffd\ufffd\u31aavs&\ufffd\u06f8>\ufffd.\ufffdk\ufffd7\ufffd\ufffdyZ\ufffd\ufffdS\ufffd\ufffd:\ufffd\u02e9\u370d\ufffdr\ufffd\u0756\u06dc\ufffd\ufffd\ufffdaKa\ufffd\ufffd\ufffd!l\ufffd\ufffd.g5\ufffd\ufffd\ufffd7\ufffdKv\ufffd0\ufffd\ufffd!;\u0697\ufffdf\ufffd\ufffd\ufffd\ufffde\ufffd\ufffd\ufffd%\ufffd]"X\ufffdT\ufffd\ufffdJ3\ufffda\u056a\ufffdlwV\ufffdj=v\ufffd\u59e0\ufffd\u03b1\ufffd\ufffd\ufffde=b\ufffdI/\ufffd\ufffdg\ufffdH&\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffdg,(y	27\ufffd>a\ufffdb\ufffda\ufffd8\ufffd\ufffd\ufffd8f\ufffd\ufffdVV\ufffdq\ufffd\ufffd\u024cT\ufffd\ufffd\ufffd0\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0249B\ufffd\ufffd\ufffd\ufffd\ufffd`(\ufffd_"f\ufffd\ufffdo!\ufffd\ufffdt}Wg\ufffd\ufffd_0}H\ufffd\ufffd\ufffdX\ufffd9\ufffd,\ufffdQ\ufffd\ufffd\ufffdx\ufffd\ufffd\ufffd=\ufffd~J\u0679\ufffdx\ufffd>\ufffd\ufffd\ufffd\ufffd\u04f1e\ufffd9\ufffdM\ufffd\ufffd\ufffd2mF\ufffd\ufffdS\ufffd\ufffd)\ufffdVk\ufffd\ufffd\ufffd\ufffd-eZF\ufffdF\u0665bt\ufffdg0\ufffd\ufffdO?\ufffdD\ufffd\u01d0%7ey\ufffd\ufffd\u069a6\ufffd\ufffdW\ufffd\ufffdS\ufffd\ufffdC\ufffd\ufffdy\ufffde\ufffd\ufffdUS}\ufffd\ufffdl\ufffd`a\ufffd8\uf46ei	\ufffd\ufffdg"1\u043bJ\ufffd"\ufffd|P\ufffdK\u069d\ufffdc\ufffd,\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffd+\ufffd&\ufffd\ufffd\ufffdP\ufffd\ufffd\ufffd\ufffdv\ua5b4GBoj_t4I\ufffdvq\ufffdf\u719a(\ufffde\ufffd\ufffdC\ufffd\ufffd!\ufffd\ufffdb\ufffd\u05fc\ufffd^\ufffdS\ufffd\ufffdb\ufffdYi1\ufffd\ufffd\ufffd�;2\ufffd\ufffdW\ufffd`/7u\ufffdh?4
-\ufffd\ufffd\ufffd\ufffd!\ufffd\ufffdz\ufffd\ufffd@#(\ufffd\ufffd\ufffdT\ufffd\ufffd\ufffd6\ufffd\ufffd^\ufffd\ufffd!\ufffdR	S\ufffd\ufffd#\ufffd>E/\ufffdS\ufffdq9\ufffdz_ /G%\u04c80C\ufffd9\ufffd[\u06fc\ufffd@\ufffd(\u0669\ufffd\ufffdP\ufffd\ufffd\ufffd,\ufffd}\ufffd\ufffdX\ufffdT\ufffdOk\ufffd\ufffdp\ufffd\ufffdQ\u022bU\ufffdG6\ufffd\ufffd
\ufffdx\ufffd2\ufffde,\ufffd\ufffd>\ufffd\ufffd\ufffd
-?\ufffd\u03ed\ufffd\ufffdQ\u07acYz\ufffd/\ufffdT\ufffd\ufffd\ufffd5\ufffdFL\ufffd\ufffd^`\ufffdt\u07a9\ufffd\ufffd3\ufffd\#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u032cD\ufffd:\ufffd,\ufffdv\ufffd\ufffd\ufffdw[mDW\ufffd\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffdTB\ufffd\ufffdZ\ufffd\ufffd\ufffd`0\u0556`3t\ufffdBQ\u02dfkk\ufffd\ufffds4\ufffd1y\ufffd	\ufffd`\ufffd\\ufffd\u07b8\ufffdc\ufffdV\ufffd#\ufffd\ufffdz`X\ufffdHhw\ufffdA\ufffd\ufffd0\ufffd\u0686FTy\ufffd\ufffdq\u04f5\u072b*F\u02ea\ufffd%\ufffd\ufffd*\ufffd\ufffd\ufffd\ufffd/>\ufffd9
-\ufffdgS'\ufffd"b'zL=N\ufffd)c\ufffd\ufffds\ufffd*\ufffd\ufffd\ufffd\ufffdb\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd)W<\ufffd#\ufffdS	\ufffd\ufffd\u765b)K\ufffd\ufffd\ufffd\ufffd
\ufffd\ufffd
-&\ufffd\ufffd\ufffdL\ufffd\\ufffd\ufffd9W\ufffdt\ufffdW!Y1\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7i*\ufffd%\ufffd\ufffd\ufffd\ufffd\ufffdwJ_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u95a5\ufffdn\ufffdWJ\ufffd!p\ufffd\ufffd\ufffd\ufffd\ufffd-0\ufffdT`\ufffd:K6B\ufffd+\ufffd\ufffdS\ufffd\ufffdz\ufffdl\ufffd\ufffdL,~\ufffd\ufffdJ#ZL\ufffdHBEe\ufffd\u07c8E\ufffdq1
-\u06b8\ufffd\ufffdTD}\ufffdbB;\ufffd\ufffd*O\ufffdTC\ufffdn\u054dl\ufffd$OY\ufffd\ufffdQ\ufffd\ufffd0m\ufffd\ufffdz7\ufffdo\ufffd\ufffd9N\u017b\ufffd|h\ufffd\ufffdDV\ufffd[V\ufffd\ufffde\ufffd\u05a9b7\ufffd\ufffd\ufffdY\ufffd\ufffdZ�\ufffdH\ufffd\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd~I\ufffd)\u073b\ufffdJ\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdoO\ufffd\ufffd\u0751\ufffd\ufffd\ufffd%(\ufffd\ufffd,\ufffdh\ufffdZ\ufffd\ufffdG\ufffd\ufffd\u04bcmR\ufffdd\ufffd\ufffd\ufffd!\ufffd\ufffd/NEWutV57z;\ufffdj\ufffd\ufffd\ufffdj\ufffd\ufffds\ufffd\ufffd\ufffd^\ufffd^lD\ufffd\u01fe0-a\ufffd\ufffd\ufffd_a\ufffd\ufffdL\ufffd\u0601\ufffd\ufffdw\ufffd\ufffd\ufffd44\u7c0db^\ufffd\ufffdppi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd&n\ufffdX\ufffd	\ufffd\ufffd\ufffd\ufffdu\u01bb-\ufffd\u0742
\ufffd-c\ufffdY4\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdg	?\ufffdj\ufffdG\ufffdI\ufffdfH\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffdJ\u0482[\ufffd\ufffd%\u03e9\ufffdC6OzvW\ufffdz\ufffd\ufffdoZ\ufffdt\ufffdA\ufffd\ufffd\ufffd\ufffd$\ufffd?z\ufffd\ufffd\ufffd;\ufffd\ufffd\u063c\ufffd\ufffd\ufffdFT2\ufffd/+\ufffd\ufffd0\ufffd\ufffd\ufffd@\ufffd\ufffd@S<@>0b\ufffd\ufffdS\ufffduq\ufffdw;j4S\ufffd'\ufffd/4s\ufffd\ufffd\ufffd\ufffdE\ufffd\u0569(P[\ufffd\ufffd\ufffd\ufffdV\ufffd^\ufffd5\u018aH\ufffd\ufffdk\ufffdg/\ufffd\u06c4\ufffdw\ufffd\ufffd\ufffd\ufffd0\ufffd\ufffd*\ufffd\ufffd\u05ad \ufffda\ufffdj\ufffdyB\ufffd\ufffd5\ufffdTC\ufffd\ufffdJ(\ufffd_\ufffd\ufffdF\ufffd4\ufffd\ufffd\ufffd\ufffd!\ufffdm\ufffd,R\ufffd\ufffdN\ufffd
\ufffd?S\ufffd\ufffd\ufffd\ufffd9\ufffd\ufffd
:\u05f4\ufffd\ufffdO\ufffd\ufffdf\ufffd\ufffdO\ufffdV\ufffd\ufffd"\u0575\u06871\ufffd\ufffd\ufffd,V)S\ufffd\ufffd@\ufffd._
-\ufffd\ufffd\ufffd#\ufffd\ufffdQ\ufffd`\ufffdK\ufffd\ufffd\ufffd|\u0368%c\ufffdj\ufffd\ufffd/&\\ufffd\ufffd:
[\ufffd\ufffdF\ufffdt\ufffd^Z"\ufffd\ufffdq\ufffd\u0664Jm\ufffd\ub64ajMar\u05d7\ufffd`VCg
-\ufffd\ufffdw"\ufffd~><\ufffd\ufffd
\ufffd8\ufffdi\ufffd\ufffd\ufffd\ufffd}\ufffdX\ufffdT8\ufffd\u01f3Q\ufffd\ufffdVY<\ufffd\ufffd<\ufffdJ=\ufffd\ufffdE\ufffd\u06cf7G8v6\ufffd\ufffdZ:\ufffd%\ufffd\ufffd\ufffdhB�\ufffd94^\ufffd\u0525m!1\ufffd\ufffd\ufffdOD>\ufffdp%\ufffdH\ufffd\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd/\ufffd�`rq\ufffd;\ufffd\ufffdN\ufffdm\ufffd~M\ufffd\ufffd\ufffds\ufffd\\ufffd\ufffd/\ufffd\ufffd\ufffdZ\ufffdh\ufffd:\ufffd(\ufffd\ufffdMX\ufffd\u0430^F\ufffd.\ua70b\ufffd.\ufffdY\ufffd\ufffd\ufffd\ufffds}5\ufffd`a\ufffd\ufffd\ufffd\ufffd(\ufffd(X0\ufffdT\ufffd+JS\ufffd\ufffd\ufffd4\ufffd&\ufffd\ufffd~\ufffd\ufffd|iB!!
!)$\ufffd)\u02b0\ufffd\ufffd\ufffd\ufffdWF\ufffdY]E\ufffd\ufffd\ube0e3x,\ufffd\ufffd\u02fd\ufffd}\ufffd\ufffd\ufffd|d\ufffd\ufffdc\ufffd
-\ufffd\ufffd|\ufffdi-\ufffd\ufffd0\ufffdWs\ufffd\ufffd
-Q_G\ufffdpRj\ufffdy\ufffd0\ufffd\ufffd\ufffd\u05ff\ufffdt\ufffd\ufffd\ufffd\ufffdj\ufffd\ufffdT\u030e\ufffd\u050d\ufffd\ue1c9D1\ufffd\ufffd\u0685\ufffd\u068d�N\ufffd:ka?\ufffd\ufffd\ufffd7\ufffde\ufffd\ufffd\ufffdk\ufffd\ufffd_\ufffd%]a;\ufffd\u05d6\ufffd\ufffd\ufffdF\ufffd=\ufffd9\ufffd\ufffd-b=&\ufffd\ufffdMm0-\ufffdvD\ufffd'^\ufffdj\ufffd\ufffd+\ufffd\ufffd/5(er\ufffd^\ufffd+E\ufffd\ufffdL
F1\ufffd$\ufffd1K\ufffd\ufffd\ufffdWE|f\ufffd\ufffdO\ufffd\ufffdFMK\ufffd\ufffd\ufffd\ufffd\ufffdm\ufffd\ufffd:\ufffd:1`\ufffd\u06a5f\ufffd\ufffdX\ufffd\u0429M\ufffd*i\ufffd9\ufffd\ufffd
-l?+Lw?-Nx\ufffd\ufffd\u0348\ufffd\ufffdw\u0273\C0\ufffd\ufffd\ufffd\u7443f	\ufffds\ufffd\ufffd\ufffd\ufffdM;i\u0111`\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffdO\ufffd\ufffd\ufffd0z\ufffd\ufffd*R\u0679\ufffdB9\ufffd@\ufffd"\ufffdk\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdv\ufffd\ufffd~\ufffd.l\ufffdB?\ufffdug\ufffd]\ufffded\ufffd\ufffd\ufffd\ufffd\ufffd8J\ufffdA\ufffdj\ufffd\ufffd\ufffd\u0379um\ufffd.\ufffd\ufffdD\ufffdO\ufffd\ufffd^^\ufffd\ufffdv:\ufffdy;\ufffd\ufffdske\ufffd\ufffd+,L\ufffd�v\ufffd\ufffd\ufffd\u015d\ufffd\ufffd\ufffd\u04bc\ufffd\ufffd\u062e\ufffd\ufffd\ufffd\ufffd\ufffdd\ufffd\ufffd_\ufffd\ufffd5\ufffdZ\ufffd\ufffd\ufffd\ufffd;q\ufffd#\ufffdk>\ufffd\ufffd\ufffd\ufffd \ufffdMU\\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd{l*\u035f\ufffd\ufffd\u0491\ufffd3Do\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd"UDc\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffd#H\ufffd)BP\ufffd\ufffdit\ufffd\ufffd/	v\ufffd`\ufffd_\ufffdS\u029d\ufffd{\ufffde\ufffd5mp\ufffdPpy\ufffd=\ufffd-2\ufffd\ufffd[\ufffd\ufffd\ufffdm\ufffd+v\ufffd\ufffd6*.\ufffdW\u06ff\ufffd\ufffdS\u01d4\ufffd\ufffd]\ufffd
-^DMk\ufffd\ufffd,2\ufffd.#\ufffd\ufffd\u0272\ufffd\\ufffd\ufffd\ufffd!{\ufffd^\ufffd\ufffdI4\ufffd\u0508\ufffd\ufffd.~\ufffd�\ufffdlDc\ufffdBU\b\ufffd"c
\ufffdj\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffdG\ufffd|\ufffdH`_\ufffd\ufffd2\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd\u0465\ufffd
\ufffd\ufffdt\ufffd\ufffdHH\uf8de\ufffd\ufffd\ufffdBaG\ufffd	:\ufffd\ufffd\ufffd\ufffdB\ufffdf\ufffd\ufffd{\ufffd'\ufffd9
-[\ufffdj\ufffd\ufffda\u0427\ufffd\ufffde
-&h\ufffd\ufffdz6F\ufffdd\ufffdy?\ufffd>g\ufffd\u06d1x&\ufffdl$\ufffd\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffdn\ufffd\ufffd\ufffd\ufffdx-'-\ufffd\ufffd\ufffd\ufffd]\ufffdO 5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd@S\ufffd U\ufffd\ufffd\u068fy]\ufffdTu \ufffd_,z\ufffd\ufffdWPT\ufffd|BJ,\u0255}`8\ufffd\u07f4y?p\ufffd7g\u02e2u\ufffd\ufffd\JO(_\ufffd\ufffdvOUue4\ufffd\ufffd\ufffd+Q\ufffd\ufffd\ufffd\ufffdbi\ufffd?A.j\ufffd\ufffd\ufffd\ufffdCxy\ufffd\ufffd\ufffdR\ufffd\ufffd\ufffdJ\ufffd\u99e5\ufffdP\ufffd\ufffdt\u3e32r\ufffd\ufffdT\ufffd\ufffdfd\ufffdd$\u05ba\ufffdFR>P\ufffda\ufffdL\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd2M\ufffd\ufffd\ufffd*\ufffd\ufffd\u05f5\ufffdT\ufffd]`W\ufffd\ufffd*\ufffdcD\ufffd*\ufffd\ufffdh\ufffdA\ufffde#\ufffd"\ufffd\u0246KO9\ufffdJ\ufffd\ufffd\ufffdKL\ufffd\ufffd2\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd(KgK3j\u0509f\ufffd\ufffdZ\ufffd\ufffdnL\ufffd\ufffd5\ufffd\ufffdo\ufffd\ufffdM(\ufffd_\ufffd\ufffd\ufffd>\ufffdFO\ufffd\ufffd\ufffd\ufffd\u04f9Gi}<\ufffd\ufffd\ufffd@w\ufffd\ufffd#Nd\ufffd\ufffd\ufffd\ufffdhoo4\ufffdY\ufffd\u033e\ufffdF\u06782\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffdA\ufffd\ufffdz$\ufffdW\ufffd\ufffd\u059c5\ufffd\ufffdCopl\ufffdi\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd3\ufffd2\ufffdl\ufffd;\ufffd\ufffda\ufffd<;\ufffdS\ufffd?B\ufffd>\ufffd<A\ufffd\ufffda\ufffdrL>\ufffdz\ufffd\ufffdpr\ufffdj\ufffd\ufffds\ufffdm\ufffd\ufffd1t\ufffdZ\ufffdc\u0325\ufffd\ufffd{\ufffds\ufffd/\ufffd\ufffd\ufffdJ{\ufffd\ufffdc\ufffd*\ufffd#\ufffd3\ufffd\ufffd\u0780f\ufffd\u03e1ne\ufffd\ufffd\ufffdh\ufffd\ufffd-\ufffd>Bc9SJ\ufffd\ufffd\ufffd"\ufffd\u0579O8\ufffd'\ufffd8\u0780 `yH
 \ufffd\u03e4u\ufffd-\ufffd*`\ufffd\ufffd	x[c')Oy\ufffd\ufffd\ufffd\ufffd\x!\ufffdQ\ufffd\ufffd\ufffdS9q<o\ufffdc\ufffd\ufffd\ufffdWSR^\ufffd\ufffd[H\ufffd{\ufffde\ufffdU\ufffd\ufffd\ufffd!.$\ufffd\ufffd,]\ufffd\ufffd\ufffd\ufffd(\ufffd\ufffd1
-\ufffdoe\ufffd*\ufffd\ufffd
-\ufffdp\ufffd\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffd
-K\ufffd"G\ufffd*\ufffd
yE\ufffd%\ufffd\ufffdS\\ufffd#\ufffd\ufffd\ufffdV\ufffd9\ufffd\ufffd\u06e62\ufffd4=\ufffd\ufffd\ufffdZH\ufffdW}d\ufffd\ufffdUU\ufffd\ufffd$\ufffdU\ufffd\ufffd\ufffd>*;\ufffd$;\ufffdd'=\ufffdNY\ufffd\ufffd,|\u07363\ufffd4\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffdT\ufffd=\ufffdka%\ufffd\ufffd\ufffdh\ufffds\ufffd\ufffd\u4b3a\ufffd\ufffdU\ufffdX7Fl\ufffd\ufffd[\ufffd\ufffdo\ufffd\ufffd1a\ufffdpuxf\ufffd9\ufffd\ufffdQ\ufffdGk4\ufffd;e
-\u02f8\ufffd7\u8347\ufffd5\ufffd\ufffdxB:\ufffdy\ufffd\ufffd\ufffd\ufffdZd\ufffd\u036b,\ufffd`2\ufffd\ufffd?_\ufffda[0\ufffd~9iYFs\ufffd3\ufffd\ufffd\ufffdg\ufffd\ufffd	\ufffd�9u\ufffd\ufffd\ufffd\ufffd<,yx\ufffd87\ufffd\ufffd\ufffd \ufffd1\ufffd\ufffd\ufffd\ufffd\ufffdJa\ufffd\ufffd\ufffd,O\ufffd@/g\ufffd\ufffd\ufffdO\ufffd\u351b\ufffd9\ufffd4 \ufffd|.]\ufffd1\ufffd6\ufffd\ufffd'\ufffd^\ufffd\ufffd@1'\ufffd\ufffdp:Xt\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdwL,j\ufffd\ufffdV\ufffd\ufffd\ufffdQv@\ufffdwl{\u03ad\ufffd\ufffd\u0331\ufffd\ufffd\ufffd\\ufffd?R^\ufffdUV\ufffd\\ufffdGI\ufffd+\ufffd\ufffd\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd0\ufffd\ufffd\ufffd3o\ufffd\ufffdy\ufffdd\ufffd[R<\ufffd"\ufffd"\ufffd\ufffd"
-.\ufffd\ufffd2\ufffd}\ufffd\ufffd"!<\ufffd4t\ufffdH~(\ufffd\ufffd-r\ufffd\ufffd2\ufffd\ufffd5D\ufffdH@\ufffd\ufffdl\ufffd\ufffd"K\ufffd\ufffd\ufffd\ufffd\ufffd\u6fe3,\ufffd\ufffd/S}\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd"+\ufffd\ufffd\ufffd~w\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdF}V
dR\ufffdz\ufffd,\ufffd\ufffd:\ufffdw&?\ufffd\ufffdC~Fq\ufffd\ufffdJ}J\u0762\ufffd\ufffd\ufffdJ\ufffd\ufffdi\ufffd\ufffd\ufffdrjzE\ufffdgU\ufffd#\ufffd\ufffdp]ZF\ufffd\ufffd\ufffd%\ufffd\ufffd+\ufffd\ufffd\ufffd[\ufffdPje\ufffdw\ufffdVjl\ufffd\ufffd\ufffdW\ufffd7\ufffd\ufffdwR\ufffd\ufffd/*\ufffd\ufffdC%\ufffd%\ufffdj\ufffd\ufffdG\ufffdx\ufffd@EFH)&0_\ufffd\ufffd\ufffd\ufffd\u0555\ufffd|Xu\ufffd
-D\ufffd\ufffd\ufffdRNXA\ufffd\0JS\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd30\ufffd\ufffd7\ufffd\u035b7\ufffd3C\ufffdWc+\ufffd\ufffdU#\ufffdr#aQOL4E\ufffd\u0459?\ufffds~\ufffd{\ufffd\ufffd\ufffds\ufffdI\ufffd\ufffd\ufffdy\ufffd?\ufffdy>\ufffd\u0492L\ufffd\ufffd\u05b8Kd-\u07a3J1\ufffdv\ufffd*fH
\ufffd6\ufffd\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdz\ufffd+~B\ufffdO\ufffd:I\ufffd\ufffdQq\ufffdZ\ufffd\ufffdU\u054d\ufffdP\ufffd[\ufffdU\ufffd\ufffdD#\ufffdBM\ufffd	\ufffd\ufffd>$\ufffd	\ufffdz|\ufffd\ufffd?\ufffd\ufffd^\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd!J0\ufffd\ufffdW8\ufffdN\ufffd	\ufffd\ufffdW\ufffdzX\ufffd\ufffdf\ufffd\ufffd\ufffd\u0449@'h\ufffd\ufffd<\ufffd
-%sd\ufffdR\u06d4e\ufffd[\ufffd$z\ufffd,\ufffd\ufffdZ\ufffd2\ufffdH5\ufffd\ufffd\ufffd\ufffd[&Ht	L\ufffd\ufffd\ufffd
\ufffd\ufffdU\ufffdO\ufffd\ucdef\ufffd<\ufffdu\ufffd\ufffd\u024erE\ufffd\u1f80{i\ufffd,8+\u05dfwM2\ufffd\ufffdO\ufffd\ufffd\\ufffd\ufffd7I8\ufffd\ufffdi\ufffdl\ufffd2\ufffdewkv"9k\ufffdr6�\ufffd\ufffdU\\ufffdR\ufffd\ufffd*\ufffdq\ufffd\ufffdo\ufffdGCxxy\ufffd\ufffd\ufffd;\ufffd:j\ufffd\ufffdY\ufffdE)a\ufffd\ufffd\ufffd\u03b0!Xid\ufffdj\ufffd\ufffd
q(\ufffd\ufffd\ufffd8\ufffdS\ufffd\ufffd=\ufffd\ufffd\ufffdl\ufffd(\ufffdP\ufffd\ufffd9Iue\ufffd&\ufffd\ufffdk)\ufffd\ufffd\ufffdW1\ufffd\ufffd\ufffd\ufffd=k\ufffd\ufffdZ\ufffdb;8\ufffdzB\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd\u0695a\ufffdv\ufffd\ufffd?\ufffdsu\ufffd\ufffdUuP\ufffd\ufffd\ufffd\Vf\ufffd>+\ufffd5\ufffd2\ufffd\ufffdj&\ufffdP\ufffd6\ufffd\ufffd\ufffduR\ufffd\u026e\ufffd!
-a\ufffd+\ufffdr\ufffd\ufffd\ufffdk\ufffd!\ufffdo\ufffd4	\ufffd\ufffd`\ufffd\ufffd\u0717\ufffdP)f\ufffd\ufffd%\ufffd\ufffdV\ufffd\ufffdQ\ufffdT\ufffd\ufffdF\ufffd(Z\ufffd]s\ufffd\ufffd\ufffd,\ufffd\ufffdTR\ufffd|O)O?\ufffd\ufffdh\ufffdo\ufffd# ]\ufffd6y\ufffd\u043b\ufffd)\ufffd\ufffdO\ufffdU\ufffd,F\ufffd\ufffd\u0660\ufffd\ufffd\ufffd\ufffdE})\ufffdg\ufffds\ufffd\ufffd\u0674G\ufffdy\ufffd\u0498p/kw~\u02d6\ufffd\ufffdI'Y\ufffd\ufffd;Td\ufffd\ufffdg\ufffdY\ufffdU\ufffd\ufffd\ufffd'\ufffd\ufffdI8\ufffd@F\ufffd*\ufffd	\ufffd8$\ufffdI\ufffd\ufffd+A2((\ufffd+y\ufffd8O\ufffd\ufffd\u03cbW\ufffd\ufffd\u0217E\ufffd\ufffd
{\u0562\ufffdb\ufffdW\ufffd"@\ufffd}@\ufffdC\u05cc\ufffdt\ufffde\ufffdY\ufffd\ufffdgv\ufffd\u0588\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffdo\ufffdfE`\ufffdea\ufffd<o\ufffdV\ufffd	\ufffdF\ufffdC\ufffd\ufffdk2\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd* ]v%\ub166L\ufffdy|\ufffdKJ\ufffd\ufffd\ufffd3\ufffd\ufffdP\ufffdnW\ufffd(\ufffd\ufffd<\ufffdyiBVO\ufffd\ufffdh\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffd\ufffdq'\ufffd9["\ufffd<c-\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffd!p\ufffd\ufffdw5\ufffd\u03d4\ufffdr\ufffd)\ufffd\U001018ae^.,\ufffd8L\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\u049br\ufffd7\ufffd\ufffd\u0236\u01eb\ufffd.\ufffd@P\ufffdp\ufffd\ufffd\ufffd"\ufffd\ufffdX\ufffdSI\ufffd3\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffd\ufffd\ufffdk\ufffdTGm\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdVb\ufffdu6\ufffd\ufffdG\u0784\ufffd\ufffd\ufffd\ufffd`]O\ufffd\ufffd\ufffd\ufffdZQ\ufffd\ufffd\ufffd&'l\ufffdT\ufffdR&"N\ufffd!\ufffdv\ufffdG{\ufffd%\ufffd\ufffd\ufffd^}T\ufffd1\ufffdv\ufffd:\u0208\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffdIW\ufffdf\ufffd\ufffd*\ufffd\u06ae\ufffd
 \ufffd\u0283u\ufffd\ufffd*\ufffd\ufffd\ufffd\ufffdlg\ufffd\ufffdw\W\ufffdd?\ufffd'\ufffd~\ufffd|S6\ufffd|\ufffd\ufffd\u0256)\u0779\ufffd\ufffdE< \ufffdK\ufffd\ufffd7\ufffd\ufffd\ufffdb\ufffd%\ufffd\ufffd\ufffd\ufffdJ\ufffd\\ufffd*\D\ufffd)\ufffd\ufffde\ufffd
-\ufffd\ufffd2\ufffdG\ufffd\ufffd2\u045bBjx$Z-\ufffd\ufffd\ufffd\ufffdaV#s\ufffd/\ufffdh"\ufffd\ufffd\ufffdK6WZ,\ufffd\u0273\ufffd\ufffd\ufffd\ufffdL\ufffd9\ufffd0\ufffd~G\ufffd"~4\ufffd\ufffd5"[\ufffd\ufffd\ufffdK\ufffd\ufffd4\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffd\ufffd\ufffd\u0255\ufffd\ufffd\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffda\ufffd\ufffd1U\ufffd_\ufffd\ufffdK\ufffd\u012a\ufffd)\ufffd\ufffdP\ufffd\ufffd
?Q\u03a29\ufffd\u0792"\ufffd\ufffdz\u072ei$\ufffd\ufffd5I\ufffd\ufffd0\ufffd]x\ufffd\ufffdo\u072c\ufffd\ufffdUJ&\ufffd]\ufffd:QS{%K\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd<\ufffd\ufffd~m\ub30b\ufffd/7\ufffd\u01a3\ufffd\ufffdi_\ufffd\ufffdy
-I<G\ufffddk~\ufffd\ufffdx\ufffdk\ufffd\u06d2\ufffd\ufffd1\ufffd\ufffde'w\ufffd7\ufffd\ufffd\ufffd\u06f2\ufffd\ufffd\ufffd\ufffd\ufffdU\ufffdy\ufffd\ufffd\u02aa\ufffd\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffdP\ufffd\ufffdx\ufffd\ufffdV\ufffd\ufffd\ufffdnL"\ufffdN6t\ufffd\u0126>\ufffdgbN\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd4\ufffd!/\ufffde%\ufffd\ufffd\ufffd\ufffdO;m\ufffd\ufffd\ufffdht\ufffd\ufffdWv6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdyF\ufffdy\ufffd\ufffd\ufffd4\u0294a\ufffdtV\ufffd]\ufffd\ufffd
au\ufffd\ufffd\ufffd
\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffdYm3rM\ufffd/q{\ufffd~\ufffd\ufffdtj\ufffd\ufffdD\ufffd\ufffd
\ufffd7\ufffd\ufffd\ufffdf\ufffdi\ufffd\ufffd\ufffd\u0277
\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \ufffd.=[\ufffdn`4\ufffd\ufffd\ufffdqSh\ufffd\ufffdB\ufffdr\ufffdx_\ufffd5w\u0510\ufffd%\ufffd\ufffdn\ufffdQ\ufffd\ufffd\ufffd\ufffd~x\ufffd'G[	\ufffd`+qb\ufffd]Q\ufffd2\u0538\ufffdi\ufffd=UGn\ufffd~\ufffd\ufffd\ufffd\u068bJ\ufffd(\ufffd\ufffd\ufffd\ufffd\ufffdA\u076a\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffdE\ufffd7\ufffd\ufffdK\ufffdz
+M\ufffd\ufffd]\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd!}\ufffd\ufffdj\ufffdnh-C\u0566_\ufffd\u9b7a\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffda\ufffd\u066d\ufffdD\ufffdfr\ufffdj\ufffd6\ufffd$-\ufffd4\ufffdn\ufffdU\ufffdZ\ufffdF)\ufffdZp\ufffd\ufffdux'\ufffd@\ufffd\ufffd]U\ufffd\ufffd\ufffd/\ufffd\u0673\ufffd\u06ff\ufffd3\ufffdUg`iU\ufffd}\ufffd\ufffd\u06b0\ufffd\ufffdU\ufffdL\ufffd\ufffdW\ufffd\ufffd\ufffdu\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffdS\ufffd\ufffdU\ufffd\ufffd[\ufffd\ufffd\ufffd;u\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdXJP\ufffdv\ufffd\ufffdO\ufffd\u0140\ufffd\ufffd{$\ufffdK
 F\ufffd,q\ufffdQ\ufffd\ufffd\ufffdr\ufffdu\ufffd\ufffdH\ufffd\ufffd.\ufffd\ufffd\ufffd}i\ufffdm\ufffd\ufffd\ufffd\ufffdfZ\ufffdh~a\ufffd\ufffd\ufffdt\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffdB\ufffdb0*\ufffd\ufffdiW\ufffd\ufffd\ufffdC\u4da7\ufffd\ufffd\ufffdjZ\ufffd\ufffdm\ufffd\ufffdn\ufffd\ufffd[nKfi\ufffdc\ufffd+.\ufffd&oV.\ufffd\ufffd&\u02ad\ufffd\ufffd{\ufffd\ufffd\ufffd5\ufffd_\ufffds\ufffd9\ufffdd\ufffdm\ufffd\ufffdI\ufffdA. \ufffd*s\ufffd5:	\ufffd1\ufffd\ufffd\ufffd\u016e\ufffd
m!\ufffd|f\ufffd\ufffd\ufffdl'\ufffd6#N\ufffd
-Z\ufffd\ufffd>\ufffd\ufffd\ufffd\\ufffdoM\ufffdk\ufffdCZ8\ufffd)*\ufffd\ufffd\ufffdbEE@\ufffd\ufffd(2\ufffd\ufffd\ufffd7{\ufffdI\ufffd"	$!\ufffd\ufffd0a\ufffd=+vU\ufffdZ\u0141`-x\ufffdE\ufffd\ufffd\ufffdJU\u01fa
-\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd~\ufffd7\ufffd<N\ufffdz\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdT\ufffd!w\ufffd\ufffd\ufffd\ufffd\ufffdB,\ufffd\ufffdC)k\ufffd\ufffd\ufffdE\ufffd\ufffd+\ufffd\ufffd+\ufffd\ufffd#\ufffd6\ufffd-\ufffd\ufffd)\ufffd\ufffdp\ufffd*\u3a9dA \ufffd\ufffd\ufffd\ufffd\ufffdAo\ufffd\ufffd\ufffdc\ufffd\ufffdc~\ufffd\_xb\ufffd5\u04fc\ufffd\ufffd\ufffd\ufffd\ufffdz\ufffdg\ufffdQ\ufffd\ufffdu\ufffd}\u07b5\ufffdz\ufffdGe\ufffd\ufffdX~	>T\ufffdS\ufffds\ufffd\ufffdV6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdi\ufffd1=\ufffd2J\u7706Jh\ufffd@ U\ufffd\ufffd\ufffdu\ufffd;\ufffd\ufffd7!\ufffd0
-\u07fd\ufffd\\ufffd\u91ae\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd%-;\ufffd\ufffd=.\ufffd\ufffde\ufffd/\ufffdT\ufffd7D\ufffd$v\ufffd{\ufffd.\u02ab\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffdZ\ufffd\u046e\ufffdmcD\u05b2+-C\ufffd\ufffdu\ufffd_\ufffd\ufffd{\ufffd>\ufffd1\ufffdH\ufffd1]\ufffd"\ufffdD^n\ufffdR\ufffd
\ufffd\u067a\ufffd:\ufffd\ufffd\ufffd\ufffdE3\ufffd[\ufffdh9\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7\ufffdTJOW+3v\ufffd�\ufffdLimc
@\ufffd6'\ufffd\ufffd[\ufffdc\ufffd`\u01e68v\ufffd\ufffd\ufffd!\ufffd\ufffd\ufffdb\ufffdR\ufffd{\ufffd\ufffd1\ufffd_\u04f5\ufffd\ufffdu\ufffd\ufffd\ufffdo\ufffd\ufffdP\ufffd\ufffdE\ufffd2\ufffd\ufffd\@;4"\ufffdmO\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdm{\ufffd\ufffd\u07faE1\ufffdd\ufffd\ufffdA\ufffd\ufffd\ufffd\ufffd}C=W\ufffd\ufffd\ufffd\ufffdB\ufffd}[3']\PJ\ufffdG5\ufffdV\ufffd\ufffdmnY\ufffdGXy\ufffdahd\ufffd'J\ufffd[U~	v\ufffd\ufffdW\ufffd\u06c5Wo\ufffd]\ufffdWn\ufffdG\ufffdn\ufffdR\ufffd\ufffd\ufffd9H7\ufffd\u0468\ufffd\ufffdAu\ufffd1\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffdZm\ufffd]lU\ufffdr\ufffd\ufffdT\ufffdV\ufffdA
-sj\ufffd6l\ufffdhm,M\ufffd\ufffdy\ufffd4A\ufffd\ufffd\ufffd\ufffd*0\ufffd\ufffd\ufffd\ufffdv\ufffdJ\ufffd\ufffdR\ufffd?\ufffd\ufffd \ufffd\u0134>\ufffd\ufffd\ufffd2C!*\ufffd#\ufffdq0\ufffdMJ!:\u014f\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdR\ufffd|\ufffdd\ufffdF\ufffda?\ufffd\ufffd2\ufffd\u0742\ufffdc\ufffdh3\ufffd\ufffddB\ufffd\ufffdz\ufffd\ufffdSI\ufffdt?\ufffd%\ufffdL\ufffd\ufffdm\ufffd\ufffdF[\ufffdA\ufffd\ufffdx\ufffdY\ufffdG\ufffd\u048f0m\ufffd;GY1\u0171h%[\ufffds\u1312@\ufffd9\ufffd
q\ufffd\ufffd_8\ufffdG>r\ufffd\ufffdW\ufffdn\ufffd\ufffd\ufffd)jod\ufffdE\ufffd\ufffdz\ufffdC\ufffd.q\ufffdJviN&\ufffdIf\ufffd\ufffd\ufffd8b\ufffd\ufffdg\ufffd
-\ufffd
\ufffdv|\ufffds\ufffd\ufffdd\ufffd\ufffd%:uT\ufffd\ufffd\ufffdf\ufffd\ufffd\ufffd\ufffd\ufffd&\ufffdL\ufffd\ufffd0\ufffd\ufffd\ufffd~\ufffdp\ufffd\ufffd\ufffd\ufffd.(R\ufffd\ufffd\ufffdU
-;_)\ufffdw%$\ufffd\ufffd/\ufffd\ufffd\ufffdt#\ufffd
-~\ufffd#\ufffdu`u[\ufffdw\ufffd.\ufffd\ufffdq\ufffds\uf4ff\ufffd\ufffd\ufffd\ufffdY\ufffd\ufffd_\ufffd-\ufffd\ufffd\ufffd\ufffd*'\u0333\u0269\ufffd\ufffdk/\ufffd\ufffd\ufffd)2*
i\ufffd9\ufffd\ufffd$\ufffd7fU\ufffdz\ufffdfl\ufffd\ufffd\ufffdc\ufffd9}\ufffd]\ufffd\ufffd,\ud20fWYC\ufffdI\ufffd\ufffd\ufffdkS\ufffd-\ufffd\ufffdt\ufffdy7>\ufffdT!\ufffd\ufffd\ufffd\ufffd<v\ufffd`tF\ufffdW\ufffdV\ufffd\ufffd"\ufffd)\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffdU\ufffd\ufffd\ufffd!\ufffd\ufffd<\ufffd\ufffd\ufffd^\ufffd\ufffdD\ufffdV\ufffd\ufffd"_W\ufffd\ufffd\ud1d6\ufffd\ufffd6!\ufffd{\ufffd9JJ\ufffdj\ufffd\ufffdi_U\ufffd(\ud67d\ufffdc4*j\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd\ufffd\ufffd26\ufffd\ufffd\ufffd\ufffd\ufffdK\u0772\ufffd\ufffd	m\ufffd&c<kQ\ufffd\ufffdJln\ufffd'\ufffdI\ufffdy\ufffdT>\ufffd\ufffd\u04e3h\ufffd\ufffd\ufffd\ufffd'\ufffd..+\ufffdupC\ufffd6\ufffd&@j\ufffd5\ufffdt\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd0\ufffd\ufffd\ufffd=\ufffd\ufffdI\ufffd\u02c2\u0116\ufffd\ufffd\ufffd\ufffd
-\ufffd</\ufffd\ufffdB\u0f72Y%\ufffdV(\ufffd\ufffdq/\u0726,\u01d7	\ufffd9(B\ufffd\ufffd0j\ufffdtI4	\ufffdS:\ufffdq\ufffd\ufffd\u0519\ufffd1\ufffd\ufffdK\ufffdh^\ufffd\ufffdChhC\ufffd\ufffdF\ufffd\ufffd\ufffd\ufffd\ufffd( \ufffd|\ufffd|y\ufffd0%o:TA\ufffdB\ufffdQ\ufffd\ufffdyPI\\ufffd;hV\u0293\ufffd\ufffd\ufffd2J
-\u0125[\ufffdQ\ufffdr\ufffd\ufffd_k`\ufffd\ufffd9h\ufffd\ufffd "?7\ufffd<18\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd\u0429\ufffd
t]Z*7\u05a1\ufffd^\ufffd\ufffd%A\ufffd\u01cc#\ufffd\ufffd\ufffd7L{Lu\ufffd7\ufffd7]\u010cY	L\ufffd\ufffdL\ufffd;
-\ufffdi\ufffd\WkI\ufffd\ufffdS\ufffd\ufffd\ufffd\ufffdy!KC:\ufffd31hZ\ufffdPf:\ufffd\u07c4\ufffd\ufffd\ufffd0\ufffd\ufffdC\ufffd>C\ufffd{\u07b6$tR:(\u03eduO\ufffd\ufffdR4\ufffd\ufffd\ufffd\ufffd$=\ufffd\ufffdjl\ufffd\ufffd\ufffd\ufffduq\ufffd1?\u05e4\ufffd\ufffd9\ufffd\ufffdS\ufffdi|c\ufffd\ufffdq\ufffdF!\ufffd_z^\ufffdS\ufffd\ufffdK}\ufffd\ufffd`\ufffdd\ufffd%D\ufffdT	\ufffdwV\ufffd>\ufffd;\ufffd<\ufffd'\ufffdV=\ufffd(\ufffd5H\ufffd%j\ufffd\ufffd\ufffdWM\ufffd\ufffdV\ufffd#\ufffd\ufffd9\ufffdY\ufffdD2\ufffd\ufffd\u0593\ufffd\ufffdp~\ufffd\ufffd\ufffd\ufffd\ufffd~J\ufffd\ufffd}\ufffdD\ufffd]\ufffdgN\ufffdS\ufffds\ufffdjJm\ufffdn-\ufffd>,v\ufffdg&S\ufffdL\ufffdl\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd^\ufffdi\ufffd\ufffd\ufffd8\ufffd\ufffd\u029e\ufffd\ufffd%\ufffd\ufffd4'\ufffd\ufffdR\ufffd\ufffdJD\ufffd\ufffdh\ufffdRN0hB\ufffdA0\ufffd(r\ufffd0K+\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffdY\ufffd\ufffd|"\ufffdE\ufffdG\ufffd\ufffd\ufffd\ufffdE_R^\ufffdv\ufffd\ufffd\ufffd4\ufffd/\ufffd?\ufffd\ufffdm[\u02e8\ufffdy\ufffdN`\ufffdK/5[\ufffd7\ufffd1\ufffd\ufffd\ufffd[G\ufffd\u0612'\ufffd '\ufffd\u94efR\ufffdG\ufffd\ufffdhq\uab41\ufffd]\ufffd\ufffd>\ufffd\ufffd\ufffdiI\ufffd\ufffdX\ufffd
-5\ufffd'\ufffd\\ufffdGB\ufffd	\ufffd\ufffd\u0107\ufffd\ufffd\ufffd\ufffdd\ufffd^u\ufffd\ufffdx\ufffd+\ufffd\ufffd\ufffd[\ufffd^\ufffd\ufffd%e\ufffd\ufffd	\ufffd\u05aa\ufffdp\ufffd\ufffdxE\ufffd\ufffd
-\ufffd \ufffd6\ufffd%!It\ufffd\u07a8@\ufffd\u04be#%\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd*\ufffdh$r\ufffd\ufffd7\u05e9\ufffd\u05c1\ufffd55\ufffd\u05c8\ufffd\ufffd\u0551'I\ufffd+6\ufffd\ufffd*\u042ew\u0230\ufffd\ufffd%U\ufffd#\ufffd\ufffdzD\ufffd+J\ufffdt\ufffd\ufffd \ufffdB\ufffda\ufffdU\u0615	6\ufffd\ufffd\ufffd\ufffd}\ufffd\ufffduO\ufffdr\ufffd\ufffd7\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffdCu}FEu\ufffda7\ufffdRV\ufffd"KS\ufffd\ufffd\ufffd\ufffdT\ufffd\ufffd\ufffd20E\ufffd\ufffd\ufffdN\ufffd{\ufffd\ufffd^\ufffd\ufffdlk\ufffd\ufffd\u0195$vW\ufffd\ufffd(\ufffd,\ufffdF7\ufffd\ufffdb\u02e2�\ufffd\ufffdO\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd<"_\ufffd\ufffd)\ufffd\ufffd\ufffd.k\ufffdh\ufffd\ufffd\ufffd[n \ufffd9W\ufffd?g\ufffd\ufffd\u06887\ufffd\ufffdy\u0219\ufffd*\ufffd\ufffd\ufffd\ufffd\u04fc\ufffduA@ \ufffdOp\ufffd\ufffdI\ufffdR\ufffd\ufffdrP\ufffd(\ufffd$e[i<\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd/\ufffd\\ufffdt\ufffd/\ufffd\ufffdG\ufffdinQ\ufffd\ufffda\ufffd@\ufffd\ufffdq\ufffdI\ufffda\ufffd{\ufffdY\u0292\ufffd]\ufffd\ufffde\ufffd\ufffd?D\ufffd\ufffd98\u07d9\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffddx,\ufffd8\ufffd?\ufffd\ufffd\ufffd\ufffdPe\ufffd1\ufffdN\ufffdW\ufffd\ufffdwA\ufffdi\ufffdN,\ufffdB\ufffd\ufffd=\ufffd%P\ufffdK\ufffd\ufffd\ufffd\ufffd~\ufffd\u0488\ufffdG\ufffd!O\u02bd\ufffd\ufffdR=e\ufffd"!\ufffd]:\ufffd:B\ufffdI\ufffd\\ufffd\ufffdMJ1\ufffdj\ufffdG\ufffdK)b'xL"W?D\G\ufffd\u051dC\ufffd\ufffd{\ufffd\ufffd\ufffdA\ufffdA
?u#U\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdUJ\ufffd\ufffd\ufffd\ufffd\u01f9\ufffd	H{\ufffdF[\ufffd5h\ufffd\ufffd\ufffd[N6\ufffd\ufffd){((\ufffd\ufffd%\ufffd\ufffd>
 \ufffdV\ufffdY\ufffdR
-n\ufffd\ufffd#\ufffd\ufffd\ufffd\ufffd(a\ufffd\ufffd\ufffd\ufffdF\ufffdq\ufffd&mq\ufffd3%\ufffd\g?\ufffd%\ufffd\u04c6\ufffd\ufffdM5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffdD3\ufffdb$\u0281W\ufffd\ufffd \ufffd\ufffd\ufffd\ufffd\u01bf\ufffd\ufffd5&\u0354D4\ufffd�K\ufffd\ufffd\ufffdc\ufffd\ufffd\u13ca\ufffd.
-\ufffd\ufffd1Z\ufffdo
-^`\ufffd\ufffd~�`\ufffd6z	\ufffdq\ufffd\ufffd\ufffd\ufffd\ufffdaX\ufffd\ufffd\ufffd\ufffd\u01f0\ufffd)\ufffd\ufffd\u04fc\u0704'\ufffd\ufffd84\ufffdn"Db.\ufffd\ufffd\ufffd\ufffd\ufffdyC<K\ufffd\ufffd\ufffdd\ufffd\ufffd},\ufffd\ufffd{\ufffd*h\ufffd
-\u06b8\ufffdh\ufffd>\ufffd\ufffd\ufffdwMv^c\ufffd\ufffd8\ufffdI\u01bb\ufffd(~\ufffd\ufffdj?\ufffd\ufffd\ufffd
-e\ufffdo\ufffd\ufffdy\ufffd\ufffdl/\ufffd\ufffdDl5\ufffd\ufffd\ufffd\ufffd\ufffd\u017b\u05e8\ufffdp\ufffdy1\ufffd\ufffd\ufffd\u0723\u0735\ufffd\ufffd\ufffd\ufffd\ufffd^004\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffd\ufffd%C\ufffdA2\ufffd\ufffd2\ufffdd\ufffdWu\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffd>\ufffdo\ufffdkL<\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd5.\u017f\u0220i\ufffdf\ufffd\ufffdfh\ufffd7S\ufffd\ufffd-\ufffd\ufffd|\ufffd^\ufffd\ufffd\ufffd\ufffdT\ufffdjX[\ufffdw

<TRUNCATED>

[13/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/README.md
----------------------------------------------------------------------
diff --git a/sdks/perl/README.md b/sdks/perl/README.md
deleted file mode 100644
index 61069cc..0000000
--- a/sdks/perl/README.md
+++ /dev/null
@@ -1,341 +0,0 @@
-# Usergrid Perl Client ![CI status](https://travis-ci.org/aweeraman/usergrid-perl-sdk.svg?branch=master "CI Status")
-
-Usergrid::Client provides an easy to use Perl API for Apache Usergrid.
-
-## Quickstart
-
-Install Usergrid::Client from CPAN:
-
-    $ sudo cpan Usergrid::Client
-
-Write a perl script that uses the Perl API to talk to Usergrid. Here's an example:
-
-```perl
-#!/usr/bin/perl
-use Usergrid::Client;
-
-# Create a client object for Usergrid that's used for subsequent activity
-my $client = Usergrid::Client->new(
-  organization => 'test-organization',
-  application  => 'test-app',
-  api_url      => 'http://localhost:8080',
-  trace        => 0
-);
-
-# Logs the user in. The security token is maintained by the library in memory
-$client->login('johndoe', 'Johndoe123$');
-
-# Add two entities to the "books" collection
-$client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
-$client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-
-# Retrieve a handle to the collection
-my $books = $client->get_collection("books");
-
-# Add a new attribute for quantity in stock
-while ($books->has_next_entity()) {
-  my $book = $books->get_next_entity();
-
-  print "Name: "   . $book->get('name')   . ", ";
-  print "Author: " . $book->get('author') . "\n";
-
-  # Create a new attribute and update the entity
-  $book->set("in-stock", 0);
-  $client->update_entity($book);
-}
-```
-
-## What is Apache Usergrid
-
-Usergrid is an open-source Backend-as-a-Service (\u201cBaaS\u201d or \u201cmBaaS\u201d) composed of
-an integrated distributed NoSQL database, application layer and client tier with
-SDKs for developers looking to rapidly build web and/or mobile applications.
-It provides elementary services (user registration & management, data storage,
-file storage, queues) and retrieval features (full text search, geolocation
-search, joins) to power common app features.
-
-It is a multi-tenant system designed for deployment to public cloud environments
-(such as Amazon Web Services, Rackspace, etc.) or to run on traditional server
-infrastructures so that anyone can run their own private BaaS deployment.
-
-For architects and back-end teams, it aims to provide a distributed, easily
-extendable, operationally predictable and highly scalable solution. For
-front-end developers, it aims to simplify the development process by enabling
-them to rapidly build and operate mobile and web applications without requiring
-backend expertise.
-
-Source: [Usergrid Documentation](https://usergrid.apache.org/docs/)
-
-For more information, visit [http://www.usergrid.org](http://www.usergrid.org)
-
-## Installation
-
-### Prerequisites
-Usergrid::Client depends on the following modules which can be installed
-from CPAN as shown below:
-
-    $ sudo cpan install Moose
-    $ sudo cpan install JSON
-    $ sudo cpan install REST::Client
-    $ sudo cpan install URI::Template
-    $ sudo cpan install Log::Log4perl
-    $ sudo cpan install namespace::autoclean
-
-### Build and install
-
-    $ perl Build.PL
-    $ ./Build
-    $ ./Build test
-    $ sudo ./Build install
-
-### For legacy users on older versions of Perl
-
-    $ perl Makefile.PL
-    $ make
-    $ make test
-    $ sudo make install
-
-## Usage
-
-### Getting started
-
-In order to login to Usergrid using the API, create a Usergrid::Client object
-as shown below and invoke the login function.
-
-```perl
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url
-);
-
-$client->login($username, $password);
-```
-
-For troubleshooting the requests and responses, tracing can be enabled, which
-will log all requests and responses to standard output.
-
-```perl
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 1
-);
-```
-
-To get more details on the API, read the following perldocs:
-
-    Usergrid::Client
-    Usergrid::Collection
-    Usergrid::Entity
-
-### Entities
-
-Creating and updating an entity is easy. Here's how:
-
-```perl
-$book = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-$book->set('genre', 'Cyberpunk');
-
-$client->update_entity($book);
-```
-
-Querying an entity can be done by UUID:
-
-```perl
-$book = $client->get_entity("books", $uuid);
-```
-
-or by name:
-
-```perl
-$book = $client->get_entity("books", "Neuromancer");
-```
-
-Similarly, an entity can be deleted by UUID or by name:
-
-```perl
-$client->delete_entity_by_id("books", $uuid_or_name);
-
-# An entity can be also deleted by passing an entity object
-$client->delete_entity($entity);
-```
-
-### Collections
-
-A collection can be retrieved as shown below:
-
-```perl
-$collection = $client->get_collection("books");
-
-# Outputs the number of records in the collection
-print "$collection->count()\n";
-```
-
-To iterate over the collection:
-
-```perl
-while ($collection->has_next_entity()) {
-  $book = $collection->get_next_entity();
-  print "$book->get('name')\n";
-}
-```
-
-Note that by default a collection returns a maximum of 10 records per page. This
-can be overridden when retrieving the collection as shown below:
-
-```perl
-$collection = $client->get_collection("books", 30);
-
-# Retrieve the first book in the collection's current page
-$first_book = $collection->get_first_entity();
-
-# Retrieve the last book in the collection's current page
-$last_book  = $collection->get_last_entity();
-```
-
-To navigate the pages in the collection:
-
-```perl
-$collection->get_next_page();
-
-$collection->get_prev_page();
-```
-
-Both of the above return FALSE if the end or the beginning of the collection
-is reached.
-
-When iterating through a collection, the auto_page attribute can be set
-to allow the collection to transparently fetch the next page when iterating.
-
-```perl
-$collection = $client->get_collection("books");
-
-$collection->auto_page(1);
-
-while ($collection->has_next_entity()) {
-  my $entity = $collection->get_next_entity();
-  # do something
-}
-```
-
-### Querying & Batch Updates
-
-Collections can be queried using a SQL-like query language for greater control
-over the data set that is returned.
-
-```perl
-$collection = $client->query_collection("books", "select * where genre = 'Cyberpunk'", $limit );
-```
-
-Queries can also be used when deleting collections:
-
-```perl
-$collection = $client->delete_collection("books", "select * where genre = 'Cyberpunk'", $limit);
-```
-
-If the $limit is omitted in the above method calls, a default of 10 is assumed.
-
-A collection can be batch updated as shown below:
-
-```perl
-$client->update_collection("books", { in_stock => 1 });
-```
-
-A query can be used to fine-tune the update:
-
-```perl
-$client->update_collection("books", { in_stock => 0 }, "select * where genre = 'Cyberpunk'", $limit);
-```
-
-Similarly, entities can be deleted in batch:
-
-```perl
-$client->delete_collection("books", "select * where genre = 'Novel'", $limit);
-```
-
-### Entity Connections
-
-Connections can be created between entities through relationships as shown below:
-
-```perl
-$book1 = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-$book2 = $client->add_entity("books", { name => "Count Zero", author => "William Gibson" });
-$book3 = $client->add_entity("books", { name => "Mona Lisa Overdrive", author => "William Gibson" });
-
-$client->connect_entities($book1, "similar_to", $book2);
-$client->connect_entities($book1, "similar_to", $book3);
-```
-
-They can also be queried just like any other collection:
-
-```perl
-$collection = $client->query_connections($book1, "similar_to");
-
-# Queries and limits can also be passed in
-$collection = $client->query_connections($book1, "similar_to", $query, $limit);
-```
-
-To delete a connection:
-
-```perl
-$client->disconnect_entities($book1, "similar_to", $book2);
-```
-
-### Code Coverage
-
-Code coverage reporting requires Devel::Cover module which can be
-installed from CPAN as shown:
-
-    $ sudo cpan install Devel::Cover
-
-For generating reports on code coverage:
-
-    $ ./Build testcover
-
-The generated report artifacts are located in cover_db/.
-
-## Release notes
-
-### 0.22
-
-* Auto paging for collections
-
-### 0.21
-
-* Documentation updates
-
-### 0.2
-
-* Creating, querying and deleting entity connections
-* Bi-directional collection pagination
-
-### 0.11
-
-* Added namespace::autoclean.pm as a dependency to fix build break on some
-  platforms
-
-### 0.1
-
-* Initial release
-* Application and admin authentication
-* Support for collections and entities (CRUD & queries)
-
-## License
-Licensed to the Apache Software Foundation (ASF) under one or more
-contributor license agreements.  See the NOTICE file distributed with
-this work for additional information regarding copyright ownership.
-the ASF licenses this file to You under the Apache License, Version 2.0
-(the "License"); you may not use this file except in compliance with
-the License.  You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/examples/books.pl
----------------------------------------------------------------------
diff --git a/sdks/perl/examples/books.pl b/sdks/perl/examples/books.pl
deleted file mode 100644
index 842d378..0000000
--- a/sdks/perl/examples/books.pl
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use Usergrid::Client;
-
-# Create a client object for Usergrid that's used for subsequent activity
-my $client = Usergrid::Client->new(
-  organization => 'test-organization',
-  application  => 'test-app',
-  api_url      => 'http://localhost:8080',
-  trace        => 0
-);
-
-# Logs the user in. The security token is maintained by the library in memory
-$client->login('johndoe', 'Johndoe123$');
-
-# Add two entities to the "books" collection
-$client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
-$client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-
-# Retrieve a handle to the collection
-my $books = $client->get_collection("books");
-
-# Add a new attribute for quantity in stock
-while ($books->has_next_entity()) {
-  my $book = $books->get_next_entity();
-
-  print "Name: "   . $book->get('name')   . ", ";
-  print "Author: " . $book->get('author') . "\n";
-
-  # Create a new attribute and update the entity
-  $book->set("in-stock", 0);
-  $client->update_entity($book);
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/lib/Usergrid/Client.pm
----------------------------------------------------------------------
diff --git a/sdks/perl/lib/Usergrid/Client.pm b/sdks/perl/lib/Usergrid/Client.pm
deleted file mode 100644
index ccb276b..0000000
--- a/sdks/perl/lib/Usergrid/Client.pm
+++ /dev/null
@@ -1,492 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-package Usergrid::Client;
-
-use Moose;
-use namespace::autoclean;
-use Usergrid::Entity;
-use Usergrid::Collection;
-
-with (
-  'Usergrid::Request',
-);
-
-our $VERSION = '0.22';
-
-=head1 NAME
-
-Usergrid::Client - Usergrid Perl Client
-
-=head1 SYNOPSIS
-
-  use Usergrid::Client;
-
-  my $client = Usergrid::Client->new(
-    organization => 'test-organization',
-    application  => 'test-app',
-    api_url      => 'http://localhost:8080'
-  );
-
-  $client->login('johndoe', 'Johndoe123$');
-
-  $client->add_entity("books", { name => "Ulysses" });
-  $client->add_entity("books", { name => "Neuromancer" });
-
-  my $books = $client->get_collection("books");
-
-  while ($books->has_next_entity()) {
-    my $book = $books->get_next_entity();
-
-    print "Name: "   . $book->get('name')   . ", ";
-    print "Author: " . $book->get('author') . "\n";
-
-    $book->set("in-stock", 0);
-    $client->update_entity($book);
-  }
-
-=head1 DESCRIPTION
-
-Usergrid::Client provides an easy to use Perl API for Apache Usergrid.
-
-=head1 WHAT IS APACHE USERGRID
-
-Usergrid is an open-source Backend-as-a-Service ("BaaS" or "mBaaS") composed of
-an integrated distributed NoSQL database, application layer and client tier with
-SDKs for developers looking to rapidly build web and/or mobile applications.
-It provides elementary services (user registration & management, data storage,
-file storage, queues) and retrieval features (full text search, geolocation
-search, joins) to power common app features.
-
-It is a multi-tenant system designed for deployment to public cloud environments
-(such as Amazon Web Services, Rackspace, etc.) or to run on traditional server
-infrastructures so that anyone can run their own private BaaS deployment.
-
-For architects and back-end teams, it aims to provide a distributed, easily
-extendable, operationally predictable and highly scalable solution. For
-front-end developers, it aims to simplify the development process by enabling
-them to rapidly build and operate mobile and web applications without requiring
-backend expertise.
-
-Source: L<https://usergrid.apache.org/docs/>
-
-For more information, visit L<http://www.usergrid.org>
-
-=head1 ATTRIBUTES
-
-The following attributes are made available via the L<Usergrid::Request> role:
-
-=over 4
-
-=item organization (String)
-
-Organization name
-
-=item application (String)
-
-Application name
-
-=item api_url (String)
-
-URL of the Usergrid instance
-
-=item trace (Boolean)
-
-Enable/disable request and response tracing for debugging and troubleshooting
-(Optional)
-
-=back
-
-=head1 METHODS
-
-The following methods are provided in this API for interacting with the Apache
-Usergrid backend.
-
-=head2 Authentication
-
-=over 4
-
-=item login ( $username, $password )
-
-Performs application user authentication. Returns the user token for the
-logged in user. The token is also kept in memory and used for subsequent
-authentication of requests.
-
-=cut
-sub login {
-  my ($self, $username, $password) = @_;
-
-  my %request = (
-    grant_type => "password",
-    username   => $username,
-    password   => $password
-  );
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/token')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application
-  );
-
-  my $token = $self->POST($uri, \%request);
-
-  $self->user_token($token);
-
-  return $self->user_token;
-}
-
-=item admin_login ( $username, $password )
-
-Performs admin user authentication. Returns the user token for the
-logged in user. The token is also kept in memory and used for subsequent
-authentication of requests.
-
-=cut
-sub management_login {
-  my ($self, $username, $password) = @_;
-
-  my %request = (
-    grant_type => "password",
-    username   => $username,
-    password   => $password
-  );
-
-  my $token = $self->POST('/management/token', \%request);
-
-  $self->user_token($token);
-
-  return $self->user_token;
-}
-
-=back
-
-=head2 Entities
-
-This section covers some of the entity level methods available in the API.
-Entities form one of the basic building blocks of Usergrid and is analogous to
-a row in an RDBMS table.
-
-=over 4
-
-=item add_entity ( $collection, \%entity )
-
-Creates a new entity within the specified collection. Returns a L<Usergrid::Entity>
-for the newly added entity.
-
-=cut
-sub add_entity {
-  my ($self, $collection, $entity) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection
-  );
-
-  return Usergrid::Entity->new( object => $self->POST($uri, $entity));
-}
-
-=item update_entity ( L<Usergrid::Entity> )
-
-Saves changes to the given entity. Returns the updated L<Usergrid::Entity>.
-
-=cut
-sub update_entity {
-  my ($self, $entity) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/{uuid}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $entity->get('type'),
-      uuid         => $entity->get('uuid')
-  );
-
-  return Usergrid::Entity->new( object => $self->PUT($uri,
-    $entity->object->{'entities'}[0]) );
-}
-
-=item get_entity ( $collection, $id )
-
-Returns a L<Usergrid::Entity> identified by either UUID or name.
-If the entity does not exist, the method returns FALSE.
-
-=cut
-sub get_entity {
-  my ($self, $collection, $id_or_name) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/{id_or_name}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      id_or_name   => $id_or_name
-  );
-
-  my $response = $self->GET($uri);
-
-  return undef if (! $response);
-
-  return Usergrid::Entity->new( object => $response );
-}
-
-=item delete_entity_by_id ( $collection, $id )
-
-Deletes an entity from the collection identified by either UUID or name. Returns
-a L<Usergrid::Entity> of the deleted entity.
-
-=cut
-sub delete_entity_by_id {
-  my ($self, $collection, $id_or_name) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/{id}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      id           => $id_or_name
-  );
-
-  return Usergrid::Entity->new( object => $self->DELETE($uri) );
-}
-
-=item delete_entity ( L<Usergrid::Entity> )
-
-Deletes the specified L<Usergrid::Entity>. Returns an instance of the deleted
-L<Usergrid::Entity> if successful.
-
-=cut
-sub delete_entity {
-  my ($self, $entity) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/{uuid}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $entity->get('type'),
-      uuid         => $entity->get('uuid')
-  );
-
-  return Usergrid::Entity->new( object => $self->DELETE($uri) );
-}
-
-=item connect_entities ( L<Usergrid::Entity>, $relationship, L<Usergrid::Entity> )
-
-Creates a connection from Entity #1 to Entity #2 signified by the relationship.
-The first entity in this relationship is identified as the connecting entity and
-the second as the connected entity. The relationship is a string that signifies
-the type of connection. This returns a L<Usergrid::Entity> of the connecting
-entity.
-
-=cut
-sub connect_entities {
-  my ($self, $connecting, $relationship, $connected) = @_;
-
-  my $uri = URI::Template
-    ->new ('/{organization}/{application}/{connecting_collection}/{connecting}/{relationship}/{connected_collection}/{connected}')
-    ->process(
-      organization          => $self->organization,
-      application           => $self->application,
-      connecting_collection => $connecting->get('type'),
-      connecting            => $connecting->get('uuid'),
-      relationship          => $relationship,
-      connected_collection  => $connected->get('type'),
-      connected             => $connected->get('uuid')
-    );
-
-    return Usergrid::Entity->new ( object => $self->POST($uri));
-}
-
-=item disconnect_entities ( L<Usergrid::Entity>, $relationship, L<Usergrid::Entity> )
-
-Removes the connection between the two entities signified by the relationship.
-This does not affect the entities in any other way apart from the removal of the
-connection that is depicted by the relationship. This returns a L<Usergrid::Entity>
-of the connecting entity with the given relationship removed.
-
-=cut
-sub disconnect_entities {
-my ($self, $connecting, $relationship, $connected) = @_;
-
-my $uri = URI::Template
-  ->new ('/{organization}/{application}/{connecting_collection}/{connecting}/{relationship}/{connected_collection}/{connected}')
-  ->process(
-    organization          => $self->organization,
-    application           => $self->application,
-    connecting_collection => $connecting->get('type'),
-    connecting            => $connecting->get('uuid'),
-    relationship          => $relationship,
-    connected_collection  => $connected->get('type'),
-    connected             => $connected->get('uuid')
-  );
-
-  return Usergrid::Entity->new ( object => $self->DELETE($uri));
-}
-
-=back
-
-=head2 Collections
-
-This section covers the methods related to retrieving and working with
-collections in the Usergrid API. Collections contains groups of entities and is
-analogous to a table in an RDBMS.
-
-=over 4
-
-=item get_collection ( $collection, [ $limit ] )
-
-Returns a L<Usergrid::Collection> with the list of entities up to the maximum
-specified limit, which is 10 if not provided.
-
-=cut
-sub get_collection {
-  my ($self, $collection, $limit) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}?limit={limit}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      limit        => ( defined $limit ) ? $limit: 10
-  );
-
-  return $self->_collection($self->GET($uri), $uri);
-}
-
-=item update_collection ( $collection, \%attributes, [ $query ], [ $limit ] )
-
-Updates all the entities in the specified collection with the provided attributes.
-Optionally pass in the SQL-like query to narrow the scope of the objects that
-are affected. This also supports specifying a limit to restrict the maximum number of
-records that are updated. If not specified, the limit defaults to 10 entities.
-
-=cut
-sub update_collection {
-  my ($self, $collection, $properties, $query, $limit) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/?limit={limit}&ql={query}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      limit        => ( defined $limit ) ? $limit : 10,
-      query        => ( defined $query ) ? $query : undef
-  );
-
-  return $self->_collection($self->PUT($uri, $properties), $uri);
-}
-
-=item delete_collection ( $collection, [ $query ], [ $limit ] )
-
-Batch delete entities in the specified collection. Optionally pass in a SQL-like
-query to narrow the scope of the objects that are affected and a limit to restrict
-the maximum number of records that are deleted. If not specified, the limit
-defaults to 10 entities.
-
-=cut
-sub delete_collection {
-  my ($self, $collection, $query, $limit) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/?limit={limit}&ql={query}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      limit        => ( defined $limit ) ? $limit : 10,
-      query        => ( defined $query ) ? $query : undef
-  );
-
-  return $self->_collection($self->DELETE($uri), $uri);
-}
-
-=item query_collection ( $collection, $query, [ $limit ] )
-
-Queries all the entities in the specified collection using a SQL-like query string.
-This also supports specifying a limit to restrict the maximum number of
-records that are returned. If not specified, the limit defaults to 10 entities.
-
-=cut
-sub query_collection {
-  my ($self, $collection, $query, $limit) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}?limit={limit}&ql={ql}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $collection,
-      limit        => ( defined $limit ) ? $limit : 10,
-      ql           => $query
-  );
-
-  return $self->_collection($self->GET($uri), $uri);
-}
-
-=item query_connections ( $entity, $relationship, [ $query ], [ $limit ] )
-
-Returns a collection of entities for the given relationship, optionally filtered
-by a SQL-like query and limited to the maximum number of records specified. If no limit
-is provided, a default of 10 entities is assumed.
-
-=cut
-sub query_connections {
-  my ($self, $entity, $relationship, $query, $limit) = @_;
-
-  my $uri = URI::Template
-    ->new('/{organization}/{application}/{collection}/{id}/{relationship}?limit={limit}&ql={ql}')
-    ->process(
-      organization => $self->organization,
-      application  => $self->application,
-      collection   => $entity->get('type'),
-      id           => $entity->get('uuid'),
-      relationship => $relationship,
-      limit        => ( defined $limit ) ? $limit : 10,
-      ql           => $query
-  );
-
-  return $self->_collection($self->GET($uri), $uri);
-}
-
-__PACKAGE__->meta->make_immutable;
-
-1;
-
-__END__
-
-=back
-
-=head1 SEE ALSO
-
-L<Usergrid::Collection>, L<Usergrid::Entity>, L<Usergrid::Request>
-
-=head1 LICENSE
-
-This software is distributed under the Apache 2 license.
-
-=head1 AUTHOR
-
-Anuradha Weeraman <an...@cpan.org>
-
-=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/lib/Usergrid/Collection.pm
----------------------------------------------------------------------
diff --git a/sdks/perl/lib/Usergrid/Collection.pm b/sdks/perl/lib/Usergrid/Collection.pm
deleted file mode 100644
index 8d64ce6..0000000
--- a/sdks/perl/lib/Usergrid/Collection.pm
+++ /dev/null
@@ -1,212 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-package Usergrid::Collection;
-
-use Moose;
-use namespace::autoclean;
-
-with (
-  'Usergrid::Request',
-);
-
-my @stack;
-
-=head1 NAME
-
-Usergrid::Collection - a Usergrid collection
-
-=head1 DESCRIPTION
-
-Encapsulates Usergrid collections and provides methods for iterating and paging
-through them.
-
-=head1 ATTRIBUTES
-
-=over 4
-
-=item object
-
-A hash reference with the collection data
-
-=item uri
-
-The URI from which this collection was retrieved
-
-=item auto_page
-
-When set, the collection will automatically move to the next page when iterating
-through the collection
-
-=back
-
-=cut
-has 'object'      => ( is => 'rw', required => 1 );
-has 'uri'         => ( is => 'rw', required => 1 );
-has 'auto_page'   => ( is => 'rw', isa => 'Bool' );
-has 'iterator'    => ( is => 'rw', isa => 'Int', default => sub { -1 } );
-
-=head1 METHODS
-
-=over 4
-
-=item has_next_entity
-
-Returns true if there's another entity available during iteration.
-
-=cut
-sub has_next_entity {
-  my $self = shift;
-  my $next = $self->iterator + 1;
-  if ( $self->auto_page && $next >= $self->count()) {
-    return $self->get_next_page();
-  }
-  return ($next >= 0 && $next < $self->count());
-}
-
-=item get_next_entity
-
-Returns the next available L<Usergrid::Entity>. If there's no entity available
-to return, it returns a FALSE. If the auto_page attribute it set, the next page
-is automatically fetched and the next entity is returned.
-
-=cut
-sub get_next_entity {
-  my $self = shift;
-  if ($self->has_next_entity()) {
-    $self->iterator ($self->iterator + 1);
-    return Usergrid::Entity->new ( object => $self->object->{'entities'}[$self->iterator] );
-  }
-  return undef;
-}
-
-=item count
-
-Returns the count of the items in the collection.
-
-=cut
-sub count {
-  my $self = shift;
-  return scalar @{$self->object->{'entities'}};
-}
-
-=item reset_iterator
-
-Rewinds the iterator back to the beginning.
-
-=cut
-sub reset_iterator {
-  my $self = shift;
-  $self->iterator (-1);
-}
-
-=item get_first_entity
-
-Returns the first entity in the collection. This is only applicable for the
-current page of the collection.
-
-=cut
-sub get_first_entity {
-  my $self = shift;
-  return ($self->count() > 0) ? Usergrid::Entity->new (
-    object => $self->object->{'entities'}[0] ) : undef;
-}
-
-=item get_last_entity
-
-Returns the last entity in the collection. This is only applicable for the
-current page of the collection.
-
-=cut
-sub get_last_entity {
-  my $self = shift;
-  return ($self->count() > 0) ? Usergrid::Entity->new (
-    object => $self->object->{'entities'}[$self->count() - 1] ) : undef;
-
-}
-
-=item get_next_page
-
-Fetches the next page in the collection. Returns false when there are no more reults.
-
-=cut
-sub get_next_page {
-  my $self = shift;
-
-  my $csr = $self->object->{'cursor'};
-
-  my $object = $self->GET($self->uri . "&cursor=". $csr);
-
-  if ($object->{'count'} > 0) {
-    push @stack, "1" if (scalar @stack == 0);
-    push @stack, $csr;
-
-    $self->object( $object );
-    $self->reset_iterator();
-
-    return $self;
-  }
-
-  0;
-}
-
-=item get_prev_page
-
-Fetches the previous page in the collection. Returns false when there are no more reults.
-
-=cut
-sub get_prev_page {
-  my $self = shift;
-  my $object;
-
-  if (scalar @stack > 0) {
-    my $csr = pop @stack;
-
-    if ($csr eq "1") {
-      $object = $self->GET($self->uri);
-    } else {
-      $object = $self->GET($self->uri . "&cursor=" . $csr);
-    }
-
-    $self->object( $object );
-    $self->reset_iterator();
-
-    return $self;
-  }
-
-  0;
-}
-
-__PACKAGE__->meta->make_immutable;
-
-1;
-
-__END__
-
-=back
-
-=head1 SEE ALSO
-
-L<Usergrid::Client>, L<Usergrid::Entity>, L<Usergrid::Request>
-
-=head1 LICENSE
-
-This software is distributed under the Apache 2 license.
-
-=head1 AUTHOR
-
-Anuradha Weeraman <an...@cpan.org>
-
-=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/lib/Usergrid/Entity.pm
----------------------------------------------------------------------
diff --git a/sdks/perl/lib/Usergrid/Entity.pm b/sdks/perl/lib/Usergrid/Entity.pm
deleted file mode 100644
index 051e9b6..0000000
--- a/sdks/perl/lib/Usergrid/Entity.pm
+++ /dev/null
@@ -1,92 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-package Usergrid::Entity;
-
-use Moose;
-use namespace::autoclean;
-
-=head1 NAME
-
-Usergrid::Entity - a Usergrid entity
-
-=head1 DESCRIPTION
-
-Encapsulates Usergrid entities and provides methods for accessing the underlying
-data.
-
-=head1 ATTRIBUTES
-
-=over 4
-
-=item object
-
-A hash reference with the entity data
-
-=back
-
-=cut
-has 'object'      => ( is => 'rw', required => 1);
-
-=head1 METHODS
-
-=over 4
-
-=item get ( $attribute_name )
-
-Returns the value of the specified attribute.
-
-=cut
-sub get {
-  my ($self, $key) = @_;
-  return $self->object->{$key} if (defined $self->object->{$key});
-  return $self->object->{'entities'}[0]->{$key};
-}
-
-=item set ( $attribute_name, $value )
-
-Sets the value of the specified attribute.
-
-=cut
-sub set {
-  my ($self, $key, $value) = @_;
-  if (defined $self->object->{$key}) {
-    $self->object->{$key} = $value;
-    return;
-  }
-  $self->object->{'entities'}[0]->{$key} = $value;
-}
-
-__PACKAGE__->meta->make_immutable;
-
-1;
-
-__END__
-
-=back
-
-=head1 SEE ALSO
-
-L<Usergrid::Client>, L<Usergrid::Collection>, L<Usergrid::Request>
-
-=head1 LICENSE
-
-This software is distributed under the Apache 2 license.
-
-=head1 AUTHOR
-
-Anuradha Weeraman <an...@cpan.org>
-
-=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/lib/Usergrid/Request.pm
----------------------------------------------------------------------
diff --git a/sdks/perl/lib/Usergrid/Request.pm b/sdks/perl/lib/Usergrid/Request.pm
deleted file mode 100644
index 3768039..0000000
--- a/sdks/perl/lib/Usergrid/Request.pm
+++ /dev/null
@@ -1,249 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-package Usergrid::Request;
-
-use Moose::Role;
-use namespace::autoclean;
-use Carp qw(confess);
-use Log::Log4perl qw(:easy);
-use REST::Client;
-use URI::Template;
-use JSON;
-
-my $json = JSON->new->allow_nonref;
-
-=head1 NAME
-
-Usergrid::Request - Role that provides HTTP invocation and utility methods
-
-=head1 DESCRIPTION
-
-This is a Role that is applied to L<Usergrid::Client> and L<Usergrid::Collection>
-which provides methods that relate to HTTP invocation as well as some utility
-functions.
-
-=head1 ATTRIBUTES
-
-=over 4
-
-=item organization (String)
-
-Organization name
-
-=item application (String)
-
-Application name
-
-=item api_url (String)
-
-URL of the Usergrid instance
-
-=item trace (Boolean)
-
-Enable/disable request and response tracing for debugging and troubleshooting
-(Optional)
-
-=cut
-has 'organization'  => ( is => 'rw', isa => 'Str', required => 1);
-has 'application'   => ( is => 'rw', isa => 'Str', required => 1);
-has 'api_url'       => ( is => 'rw', isa => 'Str', required => 1);
-
-has 'trace'         => ( is => 'rw', isa => 'Bool', trigger => \&_enable_tracing);
-
-has 'user_token'    => ( is => 'rw');
-
-# internal method
-sub _is_token_required {
-  my ($self, $resource) = @_;
-  return 0 if $resource =~ m/\/management\/token/;
-  1;
-}
-
-# internal method
-sub _api_request {
-  my ($self, $method, $resource, $request) = @_;
-
-  $self->trace_message("$method $resource");
-  $self->trace_message("REQUEST: " . $self->prettify($request)) if ($request);
-
-  my $client = REST::Client->new();
-  $client->setHost($self->api_url);
-
-  if ($self->_is_token_required($resource) == 1 && defined $self->user_token) {
-     $client->addHeader('Authorization',
-        'Bearer ' . $self->user_token->{'access_token'});
-  }
-
-  my $json_req = $self->json_encode($request) if ($request);
-
-  $client->DELETE($resource)          if ($method eq 'DELETE');
-  $client->GET($resource)             if ($method eq 'GET');
-  $client->POST($resource, $json_req) if ($method eq 'POST');
-  $client->PUT($resource, $json_req)  if ($method eq 'PUT');
-
-  my $response = $client->responseContent();
-
-  $self->trace_message("RESPONSE: " . $self->prettify($response)) if ($response);
-
-  return undef if ($client->responseCode() eq "404");
-
-  confess "Bad request"  if ($client->responseCode() eq "400");
-  confess "Unauthorized" if ($client->responseCode() eq "401");
-  confess "Forbidden"    if ($client->responseCode() eq "403");
-  confess "Server error" if ($client->responseCode() eq "500");
-
-  return $self->json_decode($response);
-}
-
-# internal method
-sub _enable_tracing {
-  my ($self, $state, $old_state) = @_;
-  if ($state) {
-    Log::Log4perl::easy_init($DEBUG);
-    our $logger = Log::Log4perl->get_logger();
-  }
-}
-
-# internal method
-sub _collection {
-  my ($self, $object, $uri) = @_;
-
-  return Usergrid::Collection->new (
-    object       => $object,
-    uri          => $uri,
-    organization => $self->organization,
-    application  => $self->application,
-    api_url      => $self->api_url,
-    trace        => $self->trace,
-    user_token   => $self->user_token
-  );
-}
-
-=back
-
-=head1 METHODS
-
-=head2 HTTP Invocation Methods
-
-=over 4
-
-=item DELETE ( $resource )
-
-Invokes HTTP DELETE on the specified resource.
-
-=cut
-sub DELETE {
-  my ($self, $resource) = @_;
-  $self->_api_request('DELETE', $resource);
-}
-
-=item GET ( $resource )
-
-Invokes HTTP GET on the specified resource.
-
-=cut
-sub GET {
-  my ($self, $resource) = @_;
-  $self->_api_request('GET', $resource);
-}
-
-=item POST ( $resource, \%request )
-
-Invokes HTTP POST on the specified resource and passes in the payload
-for the request.
-
-=cut
-sub POST {
-  my ($self, $resource, $request) = @_;
-  $self->_api_request('POST', $resource, $request);
-}
-
-=item PUT ( $resource, \%request )
-
-Invokes HTTP PUT on the specified resource and passes in the payload
-for the request.
-
-=cut
-sub PUT {
-  my ($self, $resource, $request) = @_;
-  $self->_api_request('PUT', $resource, $request);
-}
-
-=back
-
-=head2 Utility Methods
-
-=over 4
-
-=item trace_message ( $message )
-
-Utility method to log a message to console if tracing is enabled.
-
-=cut
-sub trace_message {
-  my ($self, $message) = @_;
-  $Usergrid::Request::logger->debug($message) if (defined $Usergrid::Request::logger);
-}
-
-=item prettify ( $message, \%object )
-
-Returns a prettified string representation hash reference.
-
-=cut
-sub prettify {
-  my ($self, $json_obj) = @_;
-  return $json->pretty->encode($json_obj);
-}
-
-=item json_encode ( \%hashref )
-
-Returns a JSON object from a hash reference.
-
-=cut
-sub json_encode {
-  my ($self, $json_obj) = @_;
-  $json->encode($json_obj);
-}
-
-=item json_decode ( $json_object )
-
-Returns a hash reference from a JSON object.
-
-=cut
-sub json_decode {
-  my ($self, $json_obj) = @_;
-  $json->decode($json_obj);
-}
-
-1;
-
-__END__
-
-=back
-
-=head1 SEE ALSO
-
-L<Usergrid::Client>, L<Usergrid::Collection>, L<Usergrid::Entity>
-
-=head1 LICENSE
-
-This software is distributed under the Apache 2 license.
-
-=head1 AUTHOR
-
-Anuradha Weeraman <an...@cpan.org>
-
-=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/01_init.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/01_init.t b/sdks/perl/t/01_init.t
deleted file mode 100644
index c410155..0000000
--- a/sdks/perl/t/01_init.t
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-
-use Test::More tests => 3;
-
-BEGIN {
-  use_ok 'Usergrid::Client'     || print "Bail out!\n";
-  use_ok 'Usergrid::Entity'     || print "Bail out!\n";
-  use_ok 'Usergrid::Collection' || print "Bail out!\n";
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/02_login.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/02_login.t b/sdks/perl/t/02_login.t
deleted file mode 100644
index 8397b92..0000000
--- a/sdks/perl/t/02_login.t
+++ /dev/null
@@ -1,64 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-our $hostname        = 'localhost';
-our $port            = '8080';
-our $api_url         = "http://$hostname:$port";
-our $organization    = 'test-organization';
-our $application     = 'test-app';
-our $username        = 'testuser';
-our $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 1;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-ok ( $token->{user}->{username} eq $username, "user logged in" );
-
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/03_update.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/03_update.t b/sdks/perl/t/03_update.t
deleted file mode 100644
index b05a260..0000000
--- a/sdks/perl/t/03_update.t
+++ /dev/null
@@ -1,102 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 7;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $deleted_book);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  ok ( $token->{user}->{username} eq $username, "user logged in" );
-
-  $book = $client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
-
-  ok ( $book->get('author') eq "James Joyce", "check entity creation" );
-
-  $book->set('genre', 'Modernist');
-
-  $book = $client->update_entity($book);
-
-  ok ( $book->get('genre') eq "Modernist", "check for new attribute" );
-
-  $book->set('genre', 'Novel');
-
-  $book = $client->update_entity($book);
-
-  ok ( $book->get('genre') eq "Novel", "check for updated attribute" );
-
-  $book = $client->get_entity("books", $book->get('uuid'));
-
-  ok ( $book->get('genre') eq "Novel", "check again for updated attribute by uuid" );
-
-  $book = $client->get_entity("books", "Ulysses");
-
-  ok ( $book->get('name') eq 'Ulysses', "get object by name") ;
-
-  $book = $client->delete_entity_by_id("books", $book->get('uuid'));
-
-  $deleted_book = $client->get_entity("books", $book->get('uuid'));
-
-  ok ( (! defined $deleted_book), "deleted book cannot be found" );
-
-};
-
-diag($@) if $@;
-
-# Cleanup
-$client->delete_entity($book);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/04_collection.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/04_collection.t b/sdks/perl/t/04_collection.t
deleted file mode 100644
index d823ced..0000000
--- a/sdks/perl/t/04_collection.t
+++ /dev/null
@@ -1,104 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 10;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  $client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
-  $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-  $client->add_entity("books", { name => "On the Road", author => "Jack Kerouac" });
-  $client->add_entity("books", { name => "Ubik", author => "Philip K. Dick" });
-  $client->add_entity("books", { name => "Reef", author => "Romesh Gunasekera" });
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 5, "count must now be five" );
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    ok ( length($book->get('name')) > 3, "check the book titles" );
-  }
-
-  $collection->reset_iterator();
-
-  ok ( $collection->iterator == -1, "iterator must be reset" );
-
-  ok ( $collection->count() == 5, "count must be five" );
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    $client->delete_entity($book);
-  }
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must now be again zero" );
-
-};
-
-diag($@) if $@;
-
-# Cleanup
-$collection = $client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/05_query.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/05_query.t b/sdks/perl/t/05_query.t
deleted file mode 100644
index 40e3f1b..0000000
--- a/sdks/perl/t/05_query.t
+++ /dev/null
@@ -1,108 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 8;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection, $subset);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  for (my $i = 0; $i < 30; $i++) {
-    $client->add_entity("books", { name => "book $i", index => $i });
-  }
-
-  $collection = $client->get_collection("books", 30);
-
-  ok ( $collection->count() == 30, "count must now be 30" );
-
-  $book = $collection->get_first_entity();
-
-  ok ( $book->get('index') eq '0', "first index should be 0");
-
-  $book = $collection->get_last_entity();
-
-  ok ( $book->get('index') eq '29', "last index should be 29");
-
-  $subset = $client->query_collection("books", "select * where index = '5'", 15 );
-
-  ok ( $subset->count() == 1, "subset is 1" );
-  ok ( $subset->object->{'params'}->{'limit'}[0] eq '15', "check limit override" );
-
-  $book = $subset->get_next_entity();
-
-  ok ( $book->get('index') eq '5', "query returned the fifth book" );
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    $client->delete_entity($book);
-  }
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must now be again zero" );
-
-};
-
-diag($@) if $@;
-
-# Cleanup
-$collection = $client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/06_batch_update.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/06_batch_update.t b/sdks/perl/t/06_batch_update.t
deleted file mode 100644
index 04ff11d..0000000
--- a/sdks/perl/t/06_batch_update.t
+++ /dev/null
@@ -1,107 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 34;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection, $count);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  for (my $i = 0; $i < 30; $i++) {
-    $client->add_entity("books", { name => "book $i", index => $i });
-  }
-
-  $collection = $client->get_collection("books", 30);
-
-  ok ( $collection->count() == 30, "count must now be 30" );
-
-  $client->update_collection("books", { in_stock => 1 });
-
-  $collection = $client->get_collection("books", 30);
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    ok ( $book->get('in_stock') == 1 );
-  }
-
-  $client->update_collection("books", { in_stock => 0 }, "select * where index = '1' or index = '2' or index = '3' or index = '4' or index = '5'");
-
-  $collection = $client->get_collection("books", 30);
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    $count++ if ($book->get('index') =~ /[12345]/ && $book->get('in_stock') == 0);
-    $client->delete_entity($book);
-  }
-
-  ok ( $count == 5, "batch update only 5 entities" );
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must now be again zero" );
-
-};
-
-diag($@) if $@;
-
-# Cleanup
-$collection = $client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/07_batch_delete.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/07_batch_delete.t b/sdks/perl/t/07_batch_delete.t
deleted file mode 100644
index 2ed6d72..0000000
--- a/sdks/perl/t/07_batch_delete.t
+++ /dev/null
@@ -1,87 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 3;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection, $count);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  for (my $i = 0; $i < 30; $i++) {
-    $client->add_entity("books", { name => "book $i", index => $i });
-  }
-
-  $collection = $client->get_collection("books", 30);
-
-  ok ( $collection->count() == 30, "count must now be 30" );
-
-  $client->delete_collection("books", "select * where index = '1' or index = '2' or index = '3' or index = '4' or index = '5'");
-
-  $collection = $client->get_collection("books", 30);
-
-  ok ( $collection->count() == 25, "deleted 5 entities" );
-};
-
-diag($@) if $@;
-
-# Cleanup
-$collection = $client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/08_connections.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/08_connections.t b/sdks/perl/t/08_connections.t
deleted file mode 100644
index 35550e0..0000000
--- a/sdks/perl/t/08_connections.t
+++ /dev/null
@@ -1,94 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 5;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $book1, $book2, $book3, $collection);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-  $book1 = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
-  $book2 = $client->add_entity("books", { name => "Count Zero", author => "William Gibson" });
-  $book3 = $client->add_entity("books", { name => "Mona Lisa Overdrive", author => "William Gibson" });
-
-  $client->connect_entities($book1, "similar_to", $book2);
-  $client->connect_entities($book1, "similar_to", $book3);
-
-  $collection = $client->query_connections($book1, "similar_to");
-
-  ok ( $collection->count == 2, "two connections must exist" );
-
-  while ($collection->has_next_entity()) {
-    $book = $collection->get_next_entity();
-    ok ( $book->get('name') eq 'Count Zero' || $book->get('name') eq ('Mona Lisa Overdrive'), "check connections");
-  }
-
-  $client->disconnect_entities($book1, "similar_to", $book2);
-
-  $collection = $client->query_connections($book1, "similar_to");
-
-  ok ( $collection->count() == 1 );
-
-  $book = $collection->get_next_entity();
-
-  ok ( $book->get('name') eq 'Mona Lisa Overdrive', "check remaining connection");
-};
-
-diag($@) if $@;
-
-# Cleanup
-$client->delete_collection("books", undef, 10);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/09_paging.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/09_paging.t b/sdks/perl/t/09_paging.t
deleted file mode 100644
index 9a38a7f..0000000
--- a/sdks/perl/t/09_paging.t
+++ /dev/null
@@ -1,140 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 24;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection, $subset, $count);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  for (my $i = 0; $i < 30; $i++) {
-    $client->add_entity("books", { name => "book $i", index => $i });
-  }
-
-  $collection = $client->get_collection("books", 30);
-
-  ok ( $collection->count() == 30, "count must now be 30" );
-
-  $collection = $client->get_collection("books", 10);
-
-  ok ( $collection->count == 10, "checking first page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 0', "Check first entity of first page");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 9', "Check last entity of first page");
-
-  $collection->get_next_page();
-
-  ok ( $collection->count == 10, "checking second page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 10', "Check first entity of second page");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 19', "Check last entity of second page");
-
-  $collection->get_next_page();
-
-  ok ( $collection->count == 10, "checking third page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 20', "Check first entity of third page");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 29', "Check last entity of third page");
-
-  if (! $collection->get_next_page()) {
-    pass ( "no more results" );
-  }
-
-  $collection->get_prev_page();
-
-  ok ( $collection->count == 10, "checking third page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 20', "Check first entity of third page in reverse");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 29', "Check last entity of third page in reverse");
-
-  $collection->get_prev_page();
-
-  ok ( $collection->count == 10, "checking second page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 10', "Check first entity of second page in reverse");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 19', "Check last entity of second page in reverse");
-
-  $collection->get_prev_page();
-
-  ok ( $collection->count == 10, "checking first page count" );
-  ok ( $collection->get_first_entity()->get('name') eq 'book 0', "Check first entity of first page in reverse");
-  ok ( $collection->get_last_entity()->get('name')  eq 'book 9', "Check last entity of first page in reverse");
-
-  if (! $collection->get_prev_page()) {
-    pass ( "no more results in reverse" );
-  }
-
-  $count = 0;
-  $collection = $client->get_collection("books", 10);
-  do {
-    $count += $collection->count();
-  } while ($collection->get_next_page());
-
-  ok ( $count == 30, "should return 30 entities in forward" );
-
-  $count = 0;
-  while ($collection->get_prev_page()) {
-    $count += $collection->count();
-  }
-
-  ok ( $count == 30, "should return 30 entities in reverse" );
-};
-
-diag($@) if $@;
-
-# Cleanup
-$client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/t/10_auto_paging.t
----------------------------------------------------------------------
diff --git a/sdks/perl/t/10_auto_paging.t b/sdks/perl/t/10_auto_paging.t
deleted file mode 100644
index 5ed98f7..0000000
--- a/sdks/perl/t/10_auto_paging.t
+++ /dev/null
@@ -1,94 +0,0 @@
-#!/usr/bin/perl
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-use Usergrid::Client;
-use IO::Socket::INET;
-use Test::More;
-
-# TEST DATA
-my $hostname        = 'localhost';
-my $port            = '8080';
-my $api_url         = "http://$hostname:$port";
-my $organization    = 'test-organization';
-my $application     = 'test-app';
-my $username        = 'testuser';
-my $password        = 'Testuser123$';
-###########
-
-if (_check_port($hostname, $port)) {
-  plan tests => 3;
-} else {
-  plan skip_all => "server $api_url not reachable"
-}
-
-sub _check_port {
-  my ($hostname, $port) = @_;
-  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
-    Proto => 'tcp' ) || return 0;
-  return 1;
-}
-
-my ($user, $token, $book, $collection, $subset, $count);
-
-# Create the client object that will be used for all subsequent requests
-my $client = Usergrid::Client->new(
-  organization => $organization,
-  application  => $application,
-  api_url      => $api_url,
-  trace        => 0
-);
-
-# Create a test user
-$user = $client->add_entity("users", { username=>$username, password=>$password });
-
-$token = $client->login($username, $password);
-
-eval {
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->count() == 0, "count must be initially zero" );
-
-  for (my $i = 0; $i < 30; $i++) {
-    $client->add_entity("books", { name => "book $i", index => $i });
-  }
-
-  $collection = $client->get_collection("books");
-
-  ok ( $collection->get_last_entity()->get('name') eq 'book 9', "only return 10 entites per page by default");
-
-  $collection = $client->get_collection("books");
-
-  $collection->auto_page(1);
-
-  $count = 0;
-
-  while ($collection->has_next_entity()) {
-    $count += 1;
-    my $entity = $collection->get_next_entity();
-  }
-
-  ok ( $count == 30, "should return 30 entities in when auto paging" );
-};
-
-diag($@) if $@;
-
-# Cleanup
-$client->delete_collection("books", undef, 30);
-$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/php/LICENSE b/sdks/php/LICENSE
deleted file mode 100644
index e06d208..0000000
--- a/sdks/php/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets "{}"
-      replaced with your own identifying information. (Don't include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same "printed page" as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright {yyyy} {name of copyright owner}
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-


[08/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
deleted file mode 100644
index 603d60f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-
-return [
-
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\BadRequestException',
-        'code' => 400,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\UnauthorizedException',
-        'code' => 401,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\RequestFailedException',
-        'code' => 402,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\NotFoundException',
-        'code' => 404,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 500,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 502,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 503,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 504,
-    ],
-
-];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Management.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
deleted file mode 100644
index e59154d..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
+++ /dev/null
@@ -1,1076 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'AuthPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/token',
-        'summary' => 'Get management access token',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ]
-        ]
-    ],
-    'AuthorizeGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/authorize',
-        'summary' => 'Authorize the client.  See the OAuth2 specification.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'response_type' => [
-                'description' => 'Response type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'token',
-                'required' => true,
-                'allowableValues' => ['code', 'token']
-            ],
-            'client_id' => [
-                'description' => 'Client ID.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ]
-        ]
-
-    ],
-    'OrgJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs',
-        'summary' => 'Create new organization.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'organization' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization Name'
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}',
-        'summary' => 'Find organization by name or UUID',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/activate',
-        'summary' => 'Activates the organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'confirm' => [
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-                'description' => 'Send confirmation email'
-            ]
-
-        ]
-    ],
-    'OrgReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/reactivate',
-        'summary' => 'Reactivates the organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-        ]
-    ],
-    'OrgFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/feed',
-        'summary' => 'Get organization activity feed',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgCredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
-        'summary' => 'Get organization client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgCredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
-        'summary' => 'Generate organization client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgUsersGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Get admin users for organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgUsersJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Create new admin user for organization using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgUsersFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Create new admin user for organization using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'OrgUserPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'summary' => 'Adds existing admin users for organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin user username, email, or uuid'
-            ]
-        ]
-    ],
-    'OrgUserDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'summary' => 'Remove an admin user from organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin user username, email, or uuid'
-            ]
-        ]
-    ],
-    'OrgAppsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Get apps for organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppsJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Create new application for organization using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application Name'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgAppsFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Create new application for organization using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application Name'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'OrgAppDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}',
-        'summary' => 'Delete an application in an organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppCredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
-        'summary' => 'Get application keys.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppCredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
-        'summary' => 'Generate application keys.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgUserJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users',
-        'summary' => 'Create new admin user.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgUserFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users',
-        'summary' => 'Create new admin using form post parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-
-    ],
-    'OrgUserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/resetpw',
-        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-    ],
-    'OrgUserResetPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/resetpw',
-        'summary' => 'Complete a user password reset.  Handles form POST response.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'recaptcha_challenge_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Challenge Field'
-            ],
-            'recaptcha_response_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Response Field'
-            ],
-        ]
-    ],
-    'AdminUserGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}',
-        'summary' => 'Returns the admin user details',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-        ]
-
-    ],
-    'AdminUserJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}',
-        'summary' => 'Updates the admin user details.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-
-    ],
-    'AdminUserActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/activate',
-        'summary' => 'Activates the admin user from link provided in email notification.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'confirm' => [
-                'location' => 'uri',
-                'type' => 'boolean',
-                'required' => false,
-                'description' => 'Send confirmation email'
-            ],
-        ]
-    ],
-    'AdminUserReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/reactivate',
-        'summary' => 'Request admin user reactivation.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ]
-        ]
-    ],
-    'AdminUserFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/feed',
-        'summary' => 'Get admin user activity feed.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-        ]
-    ],
-    'AdminUserPasswordJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}/password',
-        'summary' => 'Set admin user password.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'old_password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Old and new password'
-            ],
-            'new_password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Old and new password'
-            ],
-        ]
-    ],
-    'AdminUserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
-        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ]
-        ]
-    ],
-    'AdminUserResetPasswordFormPost' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
-        'summary' => 'Complete a user password reset.  Handles form POST response.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'recaptcha_challenge_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Challenge Field'
-            ],
-            'recaptcha_response_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Response Field'
-            ]
-        ]
-    ],
-    'AdminUserOrgsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Get organizations for admin user.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ]
-    ],
-    'AdminUserOrgsJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Create new organization for admin user using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'organization' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'AdminUserOrgsFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Create new organization for admin user using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'organization' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'AdminUserOrgPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
-        'summary' => 'Add admin users to organization.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'AdminUserOrgDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
-        'summary' => 'Remove an admin user from organization.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-
-        ]
-    ]
-
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
deleted file mode 100644
index 0a16a62..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'name' => 'Usergrid',
-    'apiVersion' => '1.0.0',
-    // 'baseUrl' => 'http://localhost:8080',
-    'baseUrl' => $baseURL,
-    'description' => 'Client to Usergrid application service',
-    'operations' => []
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
deleted file mode 100644
index 0606eb2..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
+++ /dev/null
@@ -1,154 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-    'ToGroup' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/{group}/notifications',
-        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'group' => [
-                'description' => 'group name',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-
-        ]
-    ],
-    'ToDevice' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/{device_uuid}/notifications',
-        'notes' => 'Create Notification for single Device.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'device_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'device name or uuid'
-            ],
-
-        ]
-    ],
-    'ToDevices' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/*/notifications',
-        'notes' => 'Create Notification all Devices.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'ToUser' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_name}/notifications',
-        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_name' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'User name or uuid'
-            ],
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
deleted file mode 100644
index a51055f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [],
-    'find' => [],
-    'create' => [],
-    'destroy' => [],
-    'update' => []
-];
\ No newline at end of file


[28/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/Icon.ai
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/Icon.ai b/sdks/other/ios/samples/parties/Icon.ai
new file mode 100644
index 0000000..ad69fcf
--- /dev/null
+++ b/sdks/other/ios/samples/parties/Icon.ai
@@ -0,0 +1,4620 @@
+%PDF-1.5
%\ufffd\ufffd\ufffd\ufffd
+1 0 obj
<</Metadata 2 0 R/OCProperties<</D<</ON[6 0 R 36 0 R 65 0 R 94 0 R 123 0 R 152 0 R 181 0 R 210 0 R 239 0 R 268 0 R]/Order 269 0 R/RBGroups[]>>/OCGs[6 0 R 36 0 R 65 0 R 94 0 R 123 0 R 152 0 R 181 0 R 210 0 R 239 0 R 268 0 R]>>/Pages 3 0 R/Type/Catalog>>
endobj
2 0 obj
<</Length 56153/Subtype/XML/Type/Metadata>>stream
+<?xpacket begin="\ufeff" id="W5M0MpCehiHzreSzNTczkc9d"?>
+<x:xmpmeta xmlns:x="adobe:ns:meta/" x:xmptk="Adobe XMP Core 5.0-c060 61.134777, 2010/02/12-17:32:00        ">
+   <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
+      <rdf:Description rdf:about=""
+            xmlns:dc="http://purl.org/dc/elements/1.1/">
+         <dc:format>application/pdf</dc:format>
+         <dc:title>
+            <rdf:Alt>
+               <rdf:li xml:lang="x-default">Icon</rdf:li>
+            </rdf:Alt>
+         </dc:title>
+      </rdf:Description>
+      <rdf:Description rdf:about=""
+            xmlns:xmp="http://ns.adobe.com/xap/1.0/"
+            xmlns:xmpGImg="http://ns.adobe.com/xap/1.0/g/img/">
+         <xmp:MetadataDate>2013-05-04T20:26:56-07:00</xmp:MetadataDate>
+         <xmp:ModifyDate>2013-05-04T20:26:56-07:00</xmp:ModifyDate>
+         <xmp:CreateDate>2013-05-04T20:19:17-07:00</xmp:CreateDate>
+         <xmp:CreatorTool>Adobe Illustrator CS5</xmp:CreatorTool>
+         <xmp:Thumbnails>
+            <rdf:Alt>
+               <rdf:li rdf:parseType="Resource">
+                  <xmpGImg:width>256</xmpGImg:width>
+                  <xmpGImg:height>256</xmpGImg:height>
+                  <xmpGImg:format>JPEG</xmpGImg:format>
+                  <xmpGImg:image>/9j/4AAQSkZJRgABAgEASABIAAD/7QAsUGhvdG9zaG9wIDMuMAA4QklNA+0AAAAAABAASAAAAAEA&#xA;AQBIAAAAAQAB/+4ADkFkb2JlAGTAAAAAAf/bAIQABgQEBAUEBgUFBgkGBQYJCwgGBggLDAoKCwoK&#xA;DBAMDAwMDAwQDA4PEA8ODBMTFBQTExwbGxscHx8fHx8fHx8fHwEHBwcNDA0YEBAYGhURFRofHx8f&#xA;Hx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8fHx8f/8AAEQgBAAEAAwER&#xA;AAIRAQMRAf/EAaIAAAAHAQEBAQEAAAAAAAAAAAQFAwIGAQAHCAkKCwEAAgIDAQEBAQEAAAAAAAAA&#xA;AQACAwQFBgcICQoLEAACAQMDAgQCBgcDBAIGAnMBAgMRBAAFIRIxQVEGE2EicYEUMpGhBxWxQiPB&#xA;UtHhMxZi8CRygvElQzRTkqKyY3PCNUQnk6OzNhdUZHTD0uIIJoMJChgZhJRFRqS0VtNVKBry4/PE&#xA;1OT0ZXWFlaW1xdXl9WZ2hpamtsbW5vY3R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo+Ck5SVlpeYmZ&#xA;qbnJ2en5KjpKWmp6ipqqusra6voRAAICAQIDBQUEBQYECAMDbQEAAhEDBCESMUEFURNhIgZxgZEy&#xA;obHwFMHR4SNCFVJicvEzJDRDghaSUyWiY7LCB3PSNeJEgxdUkwgJChgZJjZFGidkdFU38qOzwygp&#xA;0+PzhJSktMTU5PRldYWVpbXF1eX1RlZmdoaWprbG1ub2R1dnd4eXp7fH1+f3OEhYaHiImKi4yNjo&#xA;+DlJWWl5iZmpucnZ6fkqOkpaanqKmqq6ytrq+v/aAAwDAQACEQMRAD8AB5yD7A7FXYq7FXYq7
 FXY&#xA;q7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq&#xA;7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7&#xA;FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7F&#xA;XYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FX&#xA;Yq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXYq7FXY&#xA;q7FXYq7FXYqjLDRtY1EO2n2NxeLHQSG3ieUKT05cAaVpk4Y5S+kEtOXU4sf1yjG+8gIv/CHmz/qy&#xA;X/8A0izf805P8vk/my+Raf5R0/8AqkP9MP1tf4Q82D/pS3//AEizf804/l8n82XyK/yjp/8AVIf6&#xA;YfrS64tLq2k9O5heCT+SRSh+5gMqII5uVDJGQuJB9ylgZOxVMrfyz5kuYEnttJvJ4JBWOWO3ldGH&#xA;iGVSDlscMyLET8nFnrsETUpwBHfIKv8AhDzZ/wBWS/8A+kWb/mnD+XyfzZfIsf5R0/8AqkP9MP1q&#xA;N35b8xWdu9zd6Xd29vHTnNLBKiLU0FWZQBUmmRlhnEWYkD3M8etwzPDGcSe4SCXZW5KJsNM1LUJG&#xA;isLSa7kQcnSCN5WC1pUhAdslGEpbAW1Zc8MYuchEeZpHf4Q82f8AVkv/APpFm/5pyz8vk/my+RaP&#xA;5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8AVIf6YfrWv5T80xoXfRr5EHVmtpgB&#xA;9JXAcGQc4n5JGv052
 GSH+mH60sdHjco6lHU0ZWFCD7g5U5QIIsK1jpuo6hMYbC1mu5lUu0cEbSMF&#xA;BALEICaVIyUYSkaAthlzQxi5yER5mkf/AIQ82f8AVkv/APpFm/5pyz8vk/my+Rcf+UdP/qkP9MP1&#xA;u/wh5s/6sl//ANIs3/NOP5fJ/Nl8iv8AKOn/ANUh/ph+t3+EPNn/AFZL/wD6RZv+acfy+T+bL5Ff&#xA;5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8AVIf6YfraPlLzWCAdFvwWNFH1abc0&#xA;r/L7YPy+T+afkU/yhp/9Uh/ph+tv/CHmz/qyX/8A0izf804fy+T+bL5FH8o6f/VIf6YfrWS+VfNE&#xA;MTyy6PexxRqXkke2lVVVRUkkrQADAcGQCzE/JMdfpyaGSBJ/pD9aV5U5aZW3lnzJdQJcW2lXk8Eg&#xA;rHLHbyujDxDKpBy2OGZFiJr3ONPW4ImpTgCO+QVf8IebP+rJf/8ASLN/zTh/L5P5svkWH8o6f/VI&#xA;f6YfrS+8sb2xnNve28trOACYpkaNwDuDxYA5XKJiaIouTjywmLiRIeW6hkWbsVdirsVdir2H8hv9&#xA;49Y/4yQf8RfNx2V/F8P0vGe1f1Y/cf0PVM27yTsVQ2o6Xp2pW5tr+2juYG6pKoYfMV6H3GQnjjMV&#xA;IW24c88UuKBMT5PEvzI/LU6AP0npfKTSGIEqMeTwMxoKnuhOwP0HNFrNF4fqj9P3PddjdtfmP3eT&#xA;bJ9/7WD2FnNe3tvZwCs1zIkUY/ynYKP15gxiSaDvcuQQgZHlEW+p7CyhsbG3soBSG2jSKMf5KKFH&#xA;6s6yEBGIA6Pk+XKckzI85G1fJNaB13TI9V0a906QDjdQvGCezEfCfoahyvNj44GPe5GlznFljMfw&#xA;m3y1LFJDK8Ui8ZI2Kup6hlNCM5R9XjIEWORekfkX/w
 ApDqH/ADCf8zUzZdl/3h936Q8z7U/3Mf63&#xA;6C9rzevDOxV2KpD5p8l6H5jtWjvIQl1SkN6gAlQ9t/2h/knMbPpYZRvz73YaHtLLppXE+nrHo87/&#xA;ACq0W90X8wtT028Wk1vZSDkOjKZoSrr7MN812gxmGYxPMD9Iek7e1Mc+ihkjyMx90nsWbp4t2Kux&#xA;V2Ksd8+63caJ5fOpwV5W9xAXTpzQyAOh/wBZajMXWZTCHEO8Oy7J00c+bwz1jL7tk9s7uC8tIbu3&#xA;YPBOiyROO6uKg5kRkJAEdXAyYzCRjLmDSo6JIjI6hkcFWU7gg7EHCRbEEg2HznqXkq5i89ny3CCB&#xA;NcAW79f3D/GH/wBjH1+Wc1PTkZfDHe+lYe04nSeOekd/fy+0voi0tYLS1htbdeEFuixRIOyoOIH3&#xA;DOkjERAA6Pm+TIZyMjzJtS1TUrbTNOudQum4wW0bSSHvRR0HuegwZMghEyPRlgwyyzEI85GnzDrO&#xA;q3Orardalcms11IZGHYA/ZUeyigGctkmZSMj1fVdNgjhxxhHlEILINzsVdirsVdir2H8hv8AePWP&#xA;+MkH/EXzcdlfxfD9LxntX9WP3H9D1TNu8kx7zF578v8Al69htNTkkjknT1FZIy6heRWppv1HhmLm&#xA;1cMcqk7LR9lZtTAyxgEDbmndneWt7axXdpKs1tMoeKVDVWBzIhMSFjk4GTHKEjGQqQW6hYW2oWNx&#xA;Y3Kh7e5jaORT4MKff4YJwEokHkU4csscxOPOJt4n+Vvlt28+zJOKroplMldv3qsYlH3kt9GaLQ4b&#xA;zb/wvddu60fkxX+Vr5c3umdA8C0HQuUDAuoDMtdwGqASPficFpo1beFD54/NPR/0Z5yvOIpDe0u4&#xA;9v8Aftef/JQNnN67Hw5T57vpHYWp8XSx74+n5cvspPPyL/5SHUP+YT/mamX9l/3h936
 Q4HtT/cx/&#xA;rfoL2vN68Mxzzl53sPK0VrJd28s4umdUEXHbgATXkR/NmLqdUMVWLt2fZvZk9WZCJA4e9R8ofmJo&#xA;nmeeW1tUlt7qJfU9GYL8SVALKVJGxO+R0+sjlNDYs+0ex8ulAlKjE9QynMx1LDfM2q6J5c83WOt6&#xA;i5iS7sLi0ZkQuS0c0MiV41PRmzBz5I4somesSPtDu9Fgy6nTSxQ34Zxl8xIH9C3/AJW/5G/5a5P+&#xA;RMn9Mf5Rxeaf9Dur/mj5hlWl6laanp8F/ZsXtrhecTEFSRWnQ75l48gnESHIuoz4JYpmEvqCKybU&#xA;xK+/NPybZXtxZ3F1ItxbSPDMohkIDxsVYVA33GYU9fjiSD0dxi7B1U4iUQKkLG46sT/MT8xPK2t+&#xA;VrjT9PuHkupHiZVaJ1FFcE7kU6Zh6zWQyQ4Y83b9j9j6jBqBOYHDR6juRv5K+Z/rWnTaDcPWeyrL&#xA;a1O5hY/Ev+wc/jlnZmewYHpyafabQ8Exmjylsff+0fc9MzavLJfJoWnya7DrbJ/p0MDWyv8A5DMG&#xA;+8bj6TlRwxMxPrVOSNVMYTi/hMr/AB+OiYZa4zyn87vMoWG38v27/FJS4vQP5R/dofmfi+gZp+08&#xA;/KA95eu9mNFZOY+6P6T+j5vIM1D2TsVdirsVdirsVew/kN/vHrH/ABkg/wCIvm47K/i+H6XjPav6&#xA;sfuP6Hqmbd5J4z+dtpdXHmLT1gheVja0ARSxr6j7bDNH2mLyD3fre29mMkY4J2QPV+gM7/LHRdR0&#xA;jylb22oKY7h3eb0G6xq52U+B70982GhxShjqToO29TDNqTKG4oC+9leZjqGI/l7p0anXNYCgHVtS&#xA;uJImpSsMcjKh+luRzB0UPqn/ADpH5O57XzE+Hi/1PHH5kC/0MuzOdM8/8s+aPrf5na/YGSsDxrHA&#xA;Oo5WZ4MB8y7
 nNZgz3qJD8bfgvRa3Q8GgxTre9/8AO/sD0DNm868x/PLR/W0my1ZF+O0kMMp78JRU&#xA;E/Jl/HNV2pj2Evg9T7L6msksZ/iF/Efj7Ei/Iv8A5SHUP+YT/mamY/Zf94fd+kOw9qf7mP8AW/QX&#xA;teb14ZivnzyL/iyGzj+u/UvqjO1fS9XlzCj+eOlOOYer0vjVvVO37K7U/KGR4eLirrXL4FC+R/yz&#xA;tPK97NfNeNe3cielG3p+kqISC3w8nqTQb1yOl0IxG7stvanbctVEQ4eGN3zv9AZpmc6N4h+dmtw3&#xA;mvWunQsHGnRt6pFDSWYgsu3gqLmh7Sy8U+Efwvd+zOlMMJmf4z9g/Bec5rnpX0l+XX/KEaR/xg/4&#xA;2OdLof7qL5l2z/jWT3sjzKdY+YfN/wDylmt/8x91/wAnmzltR/eS/rH731Ts7/F8f9SP3BKMpcxN&#xA;PLOuT6HrlpqcNf3Dj1UH7UbbOv0qTlmHIYSEh0cXW6UZ8UsZ6j7ej6dtbmC6tormBxJBOiyROOhV&#xA;hUH7s6mMhIWORfK5wMJGJ5hUyTFDalqFtp2n3F/dNxt7aNpJD7KK0HuegyGSYhEyPRtwYZZJiEec&#xA;jT5h1zV7nWNWutSuT+9uZC5HUKOiqPZVoBnLZJmcjI9X1TS6eOHHHHHlEIHIN7sVdirsVdirsVew&#xA;/kN/vHrH/GSD/iL5uOyv4vh+l4z2r+rH7j+h6pm3eSdirsVYx5+81JomlehbMG1i/wD3Gnwg/Fyf&#xA;4fU+S1+/MPWajw40PqPJ2vZOgOfJcv7uG8j+j4p3o2mxaZpNpp8W6WsSRV8SooW+k75kYsfBER7n&#xA;B1OY5ckpn+I2jMsaEg0/yJ5V07VBqtnZGK/DOwm9adt5AQ1VZypryPbMaGkxxlxAb/F2GbtXUZMf&#xA;hylcO6o9Pgn+ZLr0q81aQNY8u6hptKtcQsI/
 +Mi/FGf+DUZTqMfHjMXL0Go8HPGfcfs6/Y8p/IwE&#xA;eYtQBFCLShB/4ypmo7L/ALw+79Ieu9qf7mH9b9Be15vXhmi6BwhI5sCQvcgUBP4jBaa2tvChjf5g&#xA;65q2ieWbi/0yJZJ0ZUeRt/SR/h9QLT4iGI6/PMXWZZQx3F2fZGlx584hkO33+T5xmmlnmeaZzJLI&#xA;xeR2NSzMakk5zRNvpkYiIocgsxS+kvy6/wCUI0j/AIwf8bHOl0P91F8y7Z/xrJ72R5lOsfMPm/8A&#xA;5SzW/wDmPuv+TzZy2o/vJf1j976p2d/i+P8AqR+4JRlLmOxV7h+SmvT32hXOmTVY6Y6ek5/33PyK&#xA;r/sWRs3nZmUmBif4f0vCe02lEMwyD+P7xX63oubN5p5d+eGvTQWVnosVVS7rPct4pGaIn/Bbn5DN&#xA;T2plIAh8Xq/ZfSCUpZT/AA7D4vG80z2rsVdirsVdirsVdir2H8hv949Y/wCMkH/EXzcdlfxfD9Lx&#xA;ntX9WP3H9D1TNu8kxfzZ+Yei+WLyG0v4LmWSeP1UMCxsoXkV35um+2YmfWQxGiC7XQdj5dVEygYg&#xA;A1vf6iwnWvz0leJo9G0/0nIoLi5YMR8o12r82zAydqE/SKd7pvZYA3llfkP1/sSP8u4tR8y+f4dQ&#xA;1GV7l7Wt3PK++8e0YHYUdloBlGkBy5gTvW7n9sShpdGYQHDxekfHn9j3rOhfPkBrWu6Voll9d1Of&#xA;6vbchH6nF3+Jq0FEDN28Mry5Y4xcjQcjTaXJnlwYxcvx3pD/AMrX8gf9XT/khc/9U8x/z+H+d9h/&#xA;U7D+QNZ/M/2Uf1sos7u3vLSG7tnElvcIssMgqOSOKqaGh6HMqMhIWORdVkxyhIxltIGiq5Jg858o&#xA;6N+ifzR1+BV4wzW/1mCnThNKrbfJqr9GavTY+DUSHl+p6XtDU+NoMR6iVH4Av
 Rs2jzTEvN+ufojz&#xA;H5alduNvcyz2tx2HGURgE/J+JzB1WXgyQPTf9DuOztL42DMBziIyHwv9FstzOdOoX9jbX9jPZXK8&#xA;7e5jaKVf8lhQ098jOAkCDyLZiyyxzE484m3y9rWlXGk6tdabcD97ayNGT/MB9lh7MtCM5XJAwkYn&#xA;o+q6bURzY4zjykEFkG99Jfl1/wAoRpH/ABg/42OdLof7qL5l2z/jWT3sjzKdY+YfN/8Aylmt/wDM&#xA;fdf8nmzltR/eS/rH731Ts7/F8f8AUj9wSjKXMdir1v8AIT/pe/8ARp/zOzb9lfxfD9Lx/tZ/k/8A&#xA;O/3r1rNw8e8Y/Pb/AI7Omf8AMO3/ABPNH2p9Y9z2/sr/AHU/636HmOax6l2KuxV2KuxV2KuxVnn5&#xA;Z+fdH8rwX8eoQ3ErXTRtH9XVGACBgeXN0/mzP0Wqjivivd5/tvsrLqjEwMRw3zv9RZr/AMry8p/8&#xA;sl//AMi4f+q2Z38qY+6X2frdH/oX1H86HzP/ABLzz8yfN2m+Z9Vtbuwjmijgg9JxOqKxbmzbcGfb&#xA;fNbrNRHLIEdz0nYvZ89LjlGZBJle3u9wYjmI7hnf5a+dvL3leK9kv4LmW8umRVaBI2VY0BNKvIhq&#xA;WbfbwzP0WphisyBsug7a7MzaoxEDERj33z+RZt/yvLyn/wAsl/8A8i4f+q2Z38qY+6X2frdF/oX1&#xA;H86HzP8AxLDvzK/MXTfM1hZ2enRXEUcMrTT/AFhUWpC8U48Hev2mzC1usjlAEbd12L2PPSzlKZiS&#xA;RQq/jzA8nn+a96J6r5L/ADb0XR/Ldppmo291JcWvJBJCkbKULFl3aRDsDTpm10uvjCAjIHZ5LtP2&#xA;fy5s8skDECXff6inn/K8vKf/ACyX/wDyLh/6rZkfypj7pfZ+twP9C+o/nQ+Z/wCJQDfm95Q/T0eq&#xA;raXwf
 6q9rL+7hqR6iyJT972+Pv3yr8/j8TjqXKun63IHs9qfBOPih9XFzPcQf4fcj/8AleXlP/lk&#xA;v/8AkXD/ANVst/lTH3S+z9bj/wChfUfzofM/8Swv8yvP2keZ4dPTToriF7R5Gczqi/bC048Hf+XM&#xA;HW6qOWuG9nedi9k5NKZcZieKuV/pAZZp353+X0sLZL61vWvFjRbho0iKGQABipMqmhPtmZj7TgIj&#xA;iBv8ebqM3sxmMyYGHDe3Pl8kR/yvLyn/AMsl/wD8i4f+q2S/lTH3S+z9bV/oX1H86HzP/EvO/wAx&#xA;vMugeY9Tg1HS4biGf0/TuhOiKG4n4GBR33oaH5DNbrM0MkuKN+b0nY2izabGYZDEi7FX8egYlmI7&#xA;h635U/Nzy3pHl2w025trx57WPhI0aRFCak7FpVPfwzb6fXwhARINj8d7x+v9n8+bPLJEwqR6k/qT&#xA;b/leXlP/AJZL/wD5Fw/9Vsu/lTH3S+z9bh/6F9R/Oh8z/wAS8c12+h1DXNRv4Qyw3dzNPGrgBgsk&#xA;hcBgCRWh8c02WQlMkdS9rpcRx4oQPOMQPkEDlbe7FWc/ll550nyt+kv0hDcS/XPQ9L6uqNT0vU5c&#xA;ubp/OKZn6LVRxXxXvToe2+y8mr4OAxHDfO+tdwPczj/leXlP/lkv/wDkXD/1WzO/lTH3S+z9bof9&#xA;C+o/nQ+Z/wCJef8A5lecdM80X9ncWEU8SW8TRuJ1RSSWrtwZ812t1EcsgR3PRdi9nZNLCUZkGz0/&#xA;sDDsw3dOxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2&#xA;KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2K&#xA;uxV2KuxV2KuxV2KuxV2KuxV2KuxV2K
 uxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2Ku&#xA;xV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2Kux&#xA;V2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV&#xA;2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxV2KuxVVtLS7vLhLa0hkuLiSvCGJS7tQV&#xA;NFUEmgFcMYkmhuWGTJGA4pEAd52TL/CHmz/qyX//AEizf805b+XyfzZfIuN/KOn/ANUh/ph+t3+E&#xA;PNn/AFZL/wD6RZv+acfy+T+bL5Ff5R0/+qQ/0w/W7/CHmz/qyX//AEizf804/l8n82XyK/yjp/8A&#xA;VIf6Yfrd/hDzZ/1ZL/8A6RZv+acfy+T+bL5Ff5R0/wDqkP8ATD9aGvtD1vT41lv9PubSJzxV54ZI&#xA;lLUrQFwN9shPFKPMENuLVYshqEoyPkQUDkG92KuxVNIfK3meeFJodIvZYZVDxyJbSsrKwqGUhaEE&#xA;ZaMGQixE/JxZa/BEkHJAEf0gv/wh5s/6sl//ANIs3/NOH8vk/my+RY/yjp/9Uh/ph+t3+EPNn/Vk&#xA;v/8ApFm/5px/L5P5svkV/lHT/wCqQ/0w/W7/AAh5s/6sl/8A9Is3/NOP5fJ/Nl8iv8o6f/VIf6Yf&#xA;raPlHzYBU6LfgDqfqs3/ADTj+XyfzZfIr/KGn/1SH+mH60uubS7tX4XMMkD/AMsilDt7MBlRBHNy&#xA;YZIyFxIPuUsDN2KuxVNIfK3meeFJodIvZYZVDxyJbSsrKwqGUhaEEZaMGQixE/JxZa/BEkHJAEf0&#xA;gv8A8IebP+rJf/8ASLN/zTh/L5P5svkWP8o6f/VIf6Yfrd/hDzZ/1ZL
 /AP6RZv8AmnH8vk/my+RX&#xA;+UdP/qkP9MP1qVx5Z8yW0Dz3Ok3kEEYrJLJbyoijxLMoAwSwzAsxNe5lDW4JGozgSe6QS3KnKdir&#xA;sVdirsVdirsVdirsVdir038jdG9bVr3VnX4bSMQwk9PUlNSR7hVp9ObPszHczLueW9qNTw444x/E&#xA;bPuH7fue0ZvHiHYq7FXYqxf8y9G/Svk2/iReU1souofHlD8TU+achmJrsfHiPlu7XsXU+FqYnpL0&#xA;n4/tp85Zzb6W7FXYq+n/ACh/yieif8wFr/yZXOp0/wDdx/qj7nyvtH/GMn9eX3lNsucN2KuxV2Kq&#xA;VzaWt1EYbqFJ4W6xyqHU/QwIyMoiQoi2cMkoG4kg+TBPM35OaBqKPNpP+4286hVq0DH3Q7r/ALH7&#xA;s1+fs2Et4+k/Y7/Re0ebGayeuP2/t+PzeN695f1bQr5rLUoDDKN0bqjr/MjftDNNlxSgakHtdLq8&#xA;eeHHjNj7vel2VuS+n/KH/KJ6J/zAWv8AyZXOp0/93H+qPufK+0f8Yyf15feU2y5w3Yqx38xP+UJ1&#xA;f/jAf+JDMXW/3UnZdj/41j/rPmzOafTnYq7FXYq7FXYq7FXYq7FXYq+iPys0b9GeTbPkvGa9rdy/&#xA;89Psf8kwudFoMfDiHnu+b9u6nxdVLuj6flz+22W5mundirsVdirTKrKVYBlYUIO4IOJCQafL3mbS&#xA;G0fX7/TWG1tMyx17xn4oz9KEHOUzY+CZj3Pqui1HjYYz/nD7ev2pZlblOxV9P+UP+UT0T/mAtf8A&#xA;kyudTp/7uP8AVH3PlfaP+MZP68vvKbZc4bsVdirsVdirsVSjzP5Y03zFpb2N6grQmC4ABeJ+zKf1&#xA;jvlGfBHLGi5mh109NkE4fEd75w1zRr3RdVuNNvV4z27UJH2WU7q6+zDcZzWTGYSMTzD6ZpdTDPjG&#xA
 ;SPIvpDyh/wAonon/ADAWv/Jlc6bT/wB3H+qPufM+0f8AGMn9eX3lNsucN2Ksd/MT/lCdX/4wH/iQ&#xA;zF1v91J2XY/+NY/6z5szmn052KuxV2KuxV2KuxV2KuxVH6Dpcmq61ZacnW6mSMnwUn4m+hanJ44c&#xA;UhHvcfV5xixSmf4Q+pIo44o0ijULHGAqKOgAFABnVgUKD5RKRJs812FDsVdirsVdirxf88dGMOr2&#xA;WrIP3d3EYZSP9+RHYn5q34Zo+08dTEu97j2X1PFjljP8Jv4H9v3vMs1j1DsVfT/lD/lE9E/5gLX/&#xA;AJMrnU6f+7j/AFR9z5X2j/jGT+vL7ym2XOG7FXYq7FXYq7FXYq8z/O3y6txpUGuRL+/smENwR3hk&#xA;Pwk/6rn/AIbNV2nhsCY6PU+zGs4chwnlLce8fs+5m3lD/lE9E/5gLX/kyuZ+n/u4/wBUfc6LtH/G&#xA;Mn9eX3lNsucN2Ksd/MT/AJQnV/8AjAf+JDMXW/3UnZdj/wCNY/6z5szmn052KuxV2KuxV2KuxV2K&#xA;uxV6P+SOjG51+51R1/d2EXGM/wDFs1VFP9gG+/Nl2ZjufF3PM+0+p4cIxjnM/YP209uzevCuxVbL&#xA;LHDE8sjcY41Lux6BVFScBIAspjEk0OZQ2kalBqml2mowAiK7iSVVPUchXifcdMjiyCcRIdW3UYTi&#xA;ySgecTSLybS7FWI/mpox1TybdlF5TWRF3FT/AIrrz/5Js2YWvx8WI+W7uewdT4WpjfKXp+fL7afP&#xA;Gc6+juxV9P8AlD/lE9E/5gLX/kyudTp/7uP9Ufc+V9o/4xk/ry+8ptlzhuxVJfOeo3mneVtSvrKT&#xA;0rqCIvFJRWo1QK0YEH6RmPqpmGMkc3O7Nwxy6iEJC4kvGLP83/PME6yTXkd0gO8MsMSqR841jb8c&#xA;0se0MwPO/gHt8ns9pJChEx8w
 T+m3snk3zbZ+Z9IF9AvpTI3p3VuTUxuBXrtVSNwc3Wm1Ayxvq8V2&#xA;l2fLS5OA7joe8J7mQ692KpV5rskvfLOqWrioktZePswQsp+hgMo1MeLHIeTl6DKYZ4SHSQa8of8A&#xA;KJ6J/wAwFr/yZXDp/wC7j/VH3J7R/wAYyf15feU2y5w3Yqx38xP+UJ1f/jAf+JDMXW/3UnZdj/41&#xA;j/rPmzOafTnYq7FXYq7FXYq7FXYq7FX0D+UmjHTvJ0ErrSbUHa6fx4tRY/o4KD9OdD2dj4cd9753&#xA;7QanxNSQOUPT+v7WaZnOjdirF/zM1X9HeS9RdWpJcILaOnjMeLf8JyOYeuycOI+eztexMHiaqA6D&#xA;f5ftSz8mdV+ueURas1ZNPmeKnfg/7xT97EfRlfZuS8ddxcv2kwcGp4ukxf6Gd5sHn3YqtmijmieG&#xA;VQ8UilHU9CrChGAgEUUxkYkEcw+Wtd0uTStZvdOfc2szxhvFQfhb6Voc5TJDhkY9z6xpc4y4ozH8&#xA;QtA5BvfT/lD/AJRPRP8AmAtf+TK51On/ALuP9Ufc+V9o/wCMZP68vvKbZc4bsVY7+Yn/AChOr/8A&#xA;GA/8SGYut/upOy7H/wAax/1nzZnNPpz1v8hoLkDWJ6EWzeggPYyLzJp8g2/zzb9lA+o9Nnj/AGrl&#xA;H92P4t/ls9azcPHuxVDapKsWmXcrfZjhkZq7CgQnK8pqBPk24I3kiPMILyh/yieif8wFr/yZXI6f&#xA;+7j/AFR9zf2j/jGT+vL7ym2XOG7FWO/mJ/yhOr/8YD/xIZi63+6k7Lsf/Gsf9Z82ZzT6c7FXYq7F&#xA;XYq7FXYq7FUXpOnTalqlpp8P95dSpEp8ObAV+jrkoRMiAOrTqMwxY5TPKIt9TW1vFbW0VvCOMUKL&#xA;HGvgqCgH3DOrjERAA6Pk85mUjI8yqZJi7FXk357ar8OmaSrdS
 91Kvy/dxn8XzT9qZOUfi9h7K4Pr&#xA;yf5v6T+hLfyO1T0NdvdOZqJeQCRB4yQn/ml2yrszJUzHvDk+1GDiwxn/ADT9h/aA9rzevDOxV2Kv&#xA;EPzt0YWvmC31NBSPUIqSH/i2Cin/AIQrmh7Tx1Pi/nPd+zGp48Jxn+A/Yf2285zXPSvp/wAof8on&#xA;on/MBa/8mVzqdP8A3cf6o+58r7R/xjJ/Xl95TbLnDdiqWeZtJk1jQL3TIpFikuo/TWRgSAag1NMp&#xA;1GMzgYjq5Wh1Aw5o5CLES8zsvyIuPWU3uqoIAfiEMZLkeALEAfcc1cey5XuXqMvtVGvRDfzL1HRN&#xA;E07RdNi07T4/Tt4q0ruzMdyzHuTm2xYo448MXldVqZ55mczcijsscd2KsY/MrV10zyZqMnKktyn1&#xA;WEdy03wmnyTkfozE12ThxHz2dr2Lp/F1UB0ieL5ftTHyh/yieif8wFr/AMmVy3T/AN3H+qPucbtH&#xA;/GMn9eX3lNsucN2Ksd/MT/lCdX/4wH/iQzF1v91J2XY/+NY/6z5szmn052KuxV2KuxV2KuxV2KvQ&#xA;fyW0b655nk1B1rFpsRYHqPVlqif8LzP0ZsOzcfFkv+a877S6ngwCA5zP2Df9T3TN+8C7FXYq7FXY&#xA;q7FXYq7FWF/m5ow1DyfPMq1m091uUp14j4ZB8uLV+jMDtHHxY77neez2p8PUgdJ7fqfP2c++iPp/&#xA;yh/yieif8wFr/wAmVzqdP/dx/qj7nyvtH/GMn9eX3lNsucN2KuxV2KuxV2KuxV4T+bnm9NY1ddMs&#xA;35WGnEhnU1WSc7Mw9l+yPpzn9fqOOVD6Yvf+z3Zxw4/EkPXP7B+17B5Q/wCUT0T/AJgLX/kyubrT&#xA;/wB3H+qPueM7R/xjJ/Xl95TbLnDdirHfzE/5QnV/+MB/4kMxdb/dSdl2P/jWP+s+bM5p9Odirs
 Vd&#xA;irsVdirsVdir3v8AJ3RvqHlJbt1pNqMjTGvX01+BB/wpb6c3/ZuPhx3/ADnz72j1PianhHKAr48z&#xA;+PJnWbB0DsVdirsVdirsVdirsVU7q2huraa2mXlDOjRyL4q44kfccjKIkCD1ZwmYSEhzBt8sarp8&#xA;unandWE395ayvE3vwYiv05yk4mJIPR9YwZhkxxmOUhb6V8of8onon/MBa/8AJlc6fT/3cf6o+58w&#xA;7R/xjJ/Xl95TbLnDdirsVdirsVaZlVSzEKqipJ2AAxJSBbyj8xfzVi9KXSPL0vNnBS51BD8IB2KR&#xA;Huf8r7vHNPrNffph8/1PXdj9gmxlzD3R/X+r5vIs1D2L6f8AKH/KJ6J/zAWv/Jlc6nT/AN3H+qPu&#xA;fK+0f8Yyf15feU2y5w3Yqx38xP8AlCdX/wCMB/4kMxdb/dSdl2P/AI1j/rPmzOafTnYq7FXYq7FX&#xA;Yq7FVewspr6+t7KEVmuZUhj/ANZ2Cj9eGMSTQ6teXIMcDI8oi31PYWUNjY29lAKQ20aRRj/JRQo/&#xA;VnWQgIxAHR8ny5DkmZHnI2r5JrdiqG1HUrHTbN7y+mW3tY6c5X6DkQo/E5CeQQFnk24cM8shGAuR&#xA;Sb/lYnkn/q7wfe39Mo/O4v5zm/yPqv8AU5O/5WJ5J/6u8H3t/TH87i/nL/I+q/1OSbaVrGmatbG5&#xA;064S6gDGMyJ0DAAkb/MZdjyxmLibDiZ9Nkwy4ZjhKMyxodirsVeFfnRo31PzQl+i0i1GIOSOnqxf&#xA;A/8AwvE/Tmg7Rx8OS/5z33s1qePT8B5wP2Hcfpev+UP+UT0T/mAtf+TK5udP/dx/qj7nje0f8Yyf&#xA;15feU2y5w3YqhNV1O10vTp9Quywt7ZecpUcjTpsMhkyCETI8g3afBLLMQj9UmIP+c/ktVqGuXPgI&#xA;t/xYZg/ynj83cj2b1X
 9H5pPqX57aeqkabpksr/svcusYHvxT1K/eMqn2qP4Y/NzcPsrM/wB5MD3b&#xA;/fTz/wAyfmB5m8wBory59K0J/wB5IB6cX+y3LN/sic12bVZMnM7dz0Wi7IwafeIuXedz+z4MczHd&#xA;k7FX0/5Q/wCUT0T/AJgLX/kyudTp/wC7j/VH3PlfaP8AjGT+vL7ym2XOG7FWO/mJ/wAoTq//ABgP&#xA;/EhmLrf7qTsux/8AGsf9Z82ZzT6c7FXYq7FXYq7FXYqzr8nNGF95tW6daw6dE02/T1G+BB/wxYfL&#xA;M7s/HxZL7t3Qe0ep8PTcI5zNfDmfx5ve86F8+dirsVeb/njqfoaBZ6epo95PzYeKQrv/AMM65q+1&#xA;J1ER7y9P7L4OLNKf82P3/wBheJZpHuXYq9a/IjU99U0tj/JdRL/wkh/4hm27KnvKPxeP9qsH0ZPf&#xA;H9I/S9bzcvHuxV2KsE/OPRvr3lI3aLWbTpVmqOvpt8Dj/hg30Zr+0sfFjv8Amu/9nNT4eo4TymK+&#xA;PMMl8of8onon/MBa/wDJlcytP/dx/qj7nWdo/wCMZP68vvKbZc4bsVY7+Yn/AChOr/8AGA/8SGYu&#xA;t/upOy7H/wAax/1nzZnNPpzsVdirsVdir6f8of8AKJ6J/wAwFr/yZXOp0/8Adx/qj7nyvtH/ABjJ&#xA;/Xl95TbLnDdirHfzE/5QnV/+MB/4kMxdb/dSdl2P/jWP+s+bM5p9OdirsVdirsVdirsVZn5E/MOH&#xA;ypZ3UI0z65NdSB3m9f0vhRaKvH036Esa175m6XVjCDtd+bpO1exzq5RPHwiI5Vf6Qyj/AJX3/wBq&#xA;L/p7/wCvOZX8q/0ft/Y6r/Qn/tn+x/487/lff/ai/wCnv/rzj/Kv9H7f2L/oT/2z/Y/8ed/yvv8A&#xA;7UX/AE9/9ecf5V/o/b+xf9Cf+2f7H/jzCvPfnaXzXfW
 1wbX6nFbRGNYfU9X4mYlm5cU6igpTtmDq&#xA;tT4sgap3nZXZg0kDHi4jI86r9JYzmM7R2Kp55N80S+WdbTU0g+sqI3ikg5+nyVx/NxelGAPTL9Pn&#xA;8KfFzcDtLQjVYvDJ4d7vmz//AJX3/wBqL/p7/wCvObD+Vf6P2/see/0J/wC2f7H/AI87/lff/ai/&#xA;6e/+vOP8q/0ft/Yv+hP/AGz/AGP/AB53/K+/+1F/09/9ecf5V/o/b+xf9Cf+2f7H/jyH1D87ob6x&#xA;uLKbQaw3MTwyf6V+y6lT/un3yM+0xKJBjz8/2NmH2YOOYkMu8Tf0/wDHlPR/zs/R2k2Wn/ob1fqd&#xA;vFb+r9Z48vSQJy4+kaVp0rjj7T4YiPDyHf8AsZaj2Z8TJKfiVxSJ+nvN/wA5Gf8AK+/+1F/09/8A&#xA;XnJfyr/R+39jT/oT/wBs/wBj/wAed/yvv/tRf9Pf/XnH+Vf6P2/sX/Qn/tn+x/48lvmL85P0zol5&#xA;pf6I9D63H6frfWefHcGvH0lr08cqz9o+JAx4avz/AGOTo/ZzwcscniXwnlw/8eebZrXp3Yq7FXYq&#xA;7FXp+j/nZ+jtJstP/Q3q/U7eK39X6zx5ekgTlx9I0rTpXNrj7T4YiPDyHf8AseV1Hsz4mSU/Erik&#xA;T9Peb/nIz/lff/ai/wCnv/rzkv5V/o/b+xp/0J/7Z/sf+PO/5X3/ANqL/p7/AOvOP8q/0ft/Yv8A&#xA;oT/2z/Y/8eS3zF+cn6Z0S80v9Eeh9bj9P1vrPPjuDXj6S16eOVZ+0fEgY8NX5/scnR+zng5Y5PEv&#xA;hPLh/wCPPNs1r07sVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirs&#xA;VdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdi
 rsVdirsV&#xA;dirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVdirsVd&#xA;irsVdirsVdirsVdirsVdirsVdirsVdirsVf/2Q==</xmpGImg:image>
+               </rdf:li>
+            </rdf:Alt>
+         </xmp:Thumbnails>
+      </rdf:Description>
+      <rdf:Description rdf:about=""
+            xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
+            xmlns:stRef="http://ns.adobe.com/xap/1.0/sType/ResourceRef#"
+            xmlns:stEvt="http://ns.adobe.com/xap/1.0/sType/ResourceEvent#">
+         <xmpMM:InstanceID>uuid:48d7dac6-a6c2-f34d-8497-b10b25305818</xmpMM:InstanceID>
+         <xmpMM:DocumentID>xmp.did:F77F1174072068118083DC2D0C045B5E</xmpMM:DocumentID>
+         <xmpMM:OriginalDocumentID>uuid:5D20892493BFDB11914A8590D31508C8</xmpMM:OriginalDocumentID>
+         <xmpMM:RenditionClass>proof:pdf</xmpMM:RenditionClass>
+         <xmpMM:DerivedFrom rdf:parseType="Resource">
+            <stRef:instanceID>uuid:830e67ab-b668-fd42-8824-d82a4db061be</stRef:instanceID>
+            <stRef:documentID>xmp.did:F77F1174072068118083BFB0448CE18C</stRef:documentID>
+            <stRef:originalDocumentID>uuid:5D20892493BFDB11914A8590D31508C8</stRef:originalDocumentID>
+            <stRef:renditionClass>proof:pdf</stRef:renditionClass>
+         </xmpMM:DerivedFrom>
+         <xmpMM:History>
+            <rdf:Seq>
+               <rdf:li rdf:parseType="Resource">
+                  <stEvt:action>saved</stEvt:action>
+                  <stEvt:instanceID>xmp.iid:F77F1174072068118083BFB0448CE18C</stEvt:instanceID>
+                  <stEvt:when>2013-05-04T20:16:01-07:00</stEvt:when>
+                  <stEvt:softwareAgent>Adobe Illustrator CS5</stEvt:softwareAgent>
+                  <stEvt:changed>/</stEvt:changed>
+               </rdf:li>
+               <rdf:li rdf:parseType="Resource">
+                  <stEvt:action>saved</stEvt:action>
+                  <stEvt:instanceID>xmp.iid:F77F1174072068118083DC2D0C045B5E</stEvt:instanceID>
+                  <stEvt:when>2013-05-04T20:19:16-07:00</stEvt:when>
+                  <stEvt:softwareAgent>Adobe Illustrator CS5</stEvt:softwareAgent>
+                  <stEvt:changed>/</stEvt:changed>
+               </rdf:li>
+            </rdf:Seq>
+         </xmpMM:History>
+      </rdf:Description>
+      <rdf:Description rdf:about=""
+            xmlns:illustrator="http://ns.adobe.com/illustrator/1.0/">
+         <illustrator:Type>Document</illustrator:Type>
+         <illustrator:StartupProfile>Print</illustrator:StartupProfile>
+      </rdf:Description>
+      <rdf:Description rdf:about=""
+            xmlns:xmpTPg="http://ns.adobe.com/xap/1.0/t/pg/"
+            xmlns:stDim="http://ns.adobe.com/xap/1.0/sType/Dimensions#"
+            xmlns:stFnt="http://ns.adobe.com/xap/1.0/sType/Font#"
+            xmlns:xmpG="http://ns.adobe.com/xap/1.0/g/">
+         <xmpTPg:HasVisibleOverprint>False</xmpTPg:HasVisibleOverprint>
+         <xmpTPg:HasVisibleTransparency>False</xmpTPg:HasVisibleTransparency>
+         <xmpTPg:NPages>1</xmpTPg:NPages>
+         <xmpTPg:MaxPageSize rdf:parseType="Resource">
+            <stDim:w>512.000000</stDim:w>
+            <stDim:h>512.000000</stDim:h>
+            <stDim:unit>Pixels</stDim:unit>
+         </xmpTPg:MaxPageSize>
+         <xmpTPg:Fonts>
+            <rdf:Bag>
+               <rdf:li rdf:parseType="Resource">
+                  <stFnt:fontName>Meloriac-Regular</stFnt:fontName>
+                  <stFnt:fontFamily>Meloriac</stFnt:fontFamily>
+                  <stFnt:fontFace>Regular</stFnt:fontFace>
+                  <stFnt:fontType>Open Type</stFnt:fontType>
+                  <stFnt:versionString>OTF 1.200;PS 001.001;Core 1.0.29</stFnt:versionString>
+                  <stFnt:composite>False</stFnt:composite>
+                  <stFnt:fontFileName>meloriac.otf</stFnt:fontFileName>
+               </rdf:li>
+            </rdf:Bag>
+         </xmpTPg:Fonts>
+         <xmpTPg:PlateNames>
+            <rdf:Seq>
+               <rdf:li>Cyan</rdf:li>
+               <rdf:li>Magenta</rdf:li>
+               <rdf:li>Yellow</rdf:li>
+               <rdf:li>Black</rdf:li>
+            </rdf:Seq>
+         </xmpTPg:PlateNames>
+         <xmpTPg:SwatchGroups>
+            <rdf:Seq>
+               <rdf:li rdf:parseType="Resource">
+                  <xmpG:groupName>Default Swatch Group</xmpG:groupName>
+                  <xmpG:groupType>0</xmpG:groupType>
+                  <xmpG:Colorants>
+                     <rdf:Seq>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>White</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>Black</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>100.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Red</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Yellow</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Green</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Cyan</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Blue</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>CMYK Magenta</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=15 M=100 Y=90 K=10</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>14.999998</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>90.000000</xmpG:yellow>
+                           <xmpG:black>10.000002</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=90 Y=85 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>90.000000</xmpG:magenta>
+                           <xmpG:yellow>85.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=80 Y=95 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>80.000000</xmpG:magenta>
+                           <xmpG:yellow>95.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=50 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>50.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=35 Y=85 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>35.000004</xmpG:magenta>
+                           <xmpG:yellow>85.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=5 M=0 Y=90 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>5.000001</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>90.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=20 M=0 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>19.999998</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=50 M=0 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>50.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=75 M=0 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>75.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=85 M=10 Y=100 K=10</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>85.000000</xmpG:cyan>
+                           <xmpG:magenta>10.000002</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>10.000002</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=90 M=30 Y=95 K=30</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>90.000000</xmpG:cyan>
+                           <xmpG:magenta>30.000002</xmpG:magenta>
+                           <xmpG:yellow>95.000000</xmpG:yellow>
+                           <xmpG:black>30.000002</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=75 M=0 Y=75 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>75.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>75.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=80 M=10 Y=45 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>80.000000</xmpG:cyan>
+                           <xmpG:magenta>10.000002</xmpG:magenta>
+                           <xmpG:yellow>45.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=70 M=15 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>70.000000</xmpG:cyan>
+                           <xmpG:magenta>14.999998</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=85 M=50 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>85.000000</xmpG:cyan>
+                           <xmpG:magenta>50.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=100 M=95 Y=5 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>95.000000</xmpG:magenta>
+                           <xmpG:yellow>5.000001</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=100 M=100 Y=25 K=25</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>25.000000</xmpG:yellow>
+                           <xmpG:black>25.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=75 M=100 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>75.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=50 M=100 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>50.000000</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=35 M=100 Y=35 K=10</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>35.000004</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>35.000004</xmpG:yellow>
+                           <xmpG:black>10.000002</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=10 M=100 Y=50 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>10.000002</xmpG:cyan>
+                           <xmpG:magenta>100.000000</xmpG:magenta>
+                           <xmpG:yellow>50.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=95 Y=20 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>95.000000</xmpG:magenta>
+                           <xmpG:yellow>19.999998</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=25 M=25 Y=40 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>25.000000</xmpG:cyan>
+                           <xmpG:magenta>25.000000</xmpG:magenta>
+                           <xmpG:yellow>39.999996</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=40 M=45 Y=50 K=5</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>39.999996</xmpG:cyan>
+                           <xmpG:magenta>45.000000</xmpG:magenta>
+                           <xmpG:yellow>50.000000</xmpG:yellow>
+                           <xmpG:black>5.000001</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=50 M=50 Y=60 K=25</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>50.000000</xmpG:cyan>
+                           <xmpG:magenta>50.000000</xmpG:magenta>
+                           <xmpG:yellow>60.000004</xmpG:yellow>
+                           <xmpG:black>25.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=55 M=60 Y=65 K=40</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>55.000000</xmpG:cyan>
+                           <xmpG:magenta>60.000004</xmpG:magenta>
+                           <xmpG:yellow>65.000000</xmpG:yellow>
+                           <xmpG:black>39.999996</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=25 M=40 Y=65 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>25.000000</xmpG:cyan>
+                           <xmpG:magenta>39.999996</xmpG:magenta>
+                           <xmpG:yellow>65.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=30 M=50 Y=75 K=10</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>30.000002</xmpG:cyan>
+                           <xmpG:magenta>50.000000</xmpG:magenta>
+                           <xmpG:yellow>75.000000</xmpG:yellow>
+                           <xmpG:black>10.000002</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=35 M=60 Y=80 K=25</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>35.000004</xmpG:cyan>
+                           <xmpG:magenta>60.000004</xmpG:magenta>
+                           <xmpG:yellow>80.000000</xmpG:yellow>
+                           <xmpG:black>25.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=40 M=65 Y=90 K=35</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>39.999996</xmpG:cyan>
+                           <xmpG:magenta>65.000000</xmpG:magenta>
+                           <xmpG:yellow>90.000000</xmpG:yellow>
+                           <xmpG:black>35.000004</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=40 M=70 Y=100 K=50</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>39.999996</xmpG:cyan>
+                           <xmpG:magenta>70.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>50.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=50 M=70 Y=80 K=70</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>50.000000</xmpG:cyan>
+                           <xmpG:magenta>70.000000</xmpG:magenta>
+                           <xmpG:yellow>80.000000</xmpG:yellow>
+                           <xmpG:black>70.000000</xmpG:black>
+                        </rdf:li>
+                     </rdf:Seq>
+                  </xmpG:Colorants>
+               </rdf:li>
+               <rdf:li rdf:parseType="Resource">
+                  <xmpG:groupName>Grays</xmpG:groupName>
+                  <xmpG:groupType>1</xmpG:groupType>
+                  <xmpG:Colorants>
+                     <rdf:Seq>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=100</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>100.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=90</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>89.999405</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=80</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>79.998795</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=70</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>69.999702</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=60</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>59.999104</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=50</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>50.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=40</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>39.999401</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=30</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>29.998802</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=20</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>19.999701</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=10</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>9.999103</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=0 Y=0 K=5</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>0.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>4.998803</xmpG:black>
+                        </rdf:li>
+                     </rdf:Seq>
+                  </xmpG:Colorants>
+               </rdf:li>
+               <rdf:li rdf:parseType="Resource">
+                  <xmpG:groupName>Brights</xmpG:groupName>
+                  <xmpG:groupType>1</xmpG:groupType>
+                  <xmpG:Colorants>
+                     <rdf:Seq>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>R=255 G=67 B=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.003099</xmpG:cyan>
+                           <xmpG:magenta>87.389900</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.003099</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=75 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>75.000000</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=0 M=10 Y=95 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>0.000000</xmpG:cyan>
+                           <xmpG:magenta>10.000002</xmpG:magenta>
+                           <xmpG:yellow>95.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=85 M=10 Y=100 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>85.000000</xmpG:cyan>
+                           <xmpG:magenta>10.000002</xmpG:magenta>
+                           <xmpG:yellow>100.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=100 M=90 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>100.000000</xmpG:cyan>
+                           <xmpG:magenta>90.000000</xmpG:magenta>
+                           <xmpG:yellow>0.000000</xmpG:yellow>
+                           <xmpG:black>0.000000</xmpG:black>
+                        </rdf:li>
+                        <rdf:li rdf:parseType="Resource">
+                           <xmpG:swatchName>C=60 M=90 Y=0 K=0</xmpG:swatchName>
+                           <xmpG:mode>CMYK</xmpG:mode>
+                           <xmpG:type>PROCESS</xmpG:type>
+                           <xmpG:cyan>60.000004</xmpG:cyan>
+                           <xmpG:magenta>90.000000</xmpG:magenta>
+                           <xmpG:yellow>0.003099</xmpG:yellow>
+                           <xmpG:black>0.003099</xmpG:black>
+                        </rdf:li>
+                     </rdf:Seq>
+                  </xmpG:Colorants>
+               </rdf:li>
+            </rdf:Seq>
+         </xmpTPg:SwatchGroups>
+      </rdf:Description>
+      <rdf:Description rdf:about=""
+            xmlns:pdf="http://ns.adobe.com/pdf/1.3/">
+         <pdf:Producer>Adobe PDF library 9.90</pdf:Producer>
+      </rdf:Description>
+   </rdf:RDF>
+</x:xmpmeta>
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                                                                                                    
+                           
+<?xpacket end="w"?>
endstream
endobj
3 0 obj
<</Count 1/Kids[8 0 R]/Type/Pages>>
endobj
8 0 obj
<</ArtBox[0.0 0.0 512.0 512.0]/BleedBox[0.0 0.0 512.0 512.0]/Contents 270 0 R/LastModified(D:20130504202656-07'00')/MediaBox[0.0 0.0 512.0 512.0]/Parent 3 0 R/PieceInfo<</Illustrator 271 0 R>>/Resources<</ColorSpace<</CS0 272 0 R>>/ExtGState<</GS0 273 0 R>>/Font<</T1_0 267 0 R>>/ProcSet[/PDF/Text]/Properties<</MC0 268 0 R>>>>/Thumb 274 0 R/TrimBox[0.0 0.0 512.0 512.0]/Type/Page>>
endobj
270 0 obj
<</Filter/FlateDecode/Length 155>>stream
+H\ufffd<\ufffd\ufffd
+\ufffd@D\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd\u0774\ufffdh\ufffd"
+\u0142\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd
+�\ufffdy0\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd�\ufffdd\ufffd\ufffd#\ufffd\ufffd\ufffd
v\ufffd\ufffd1@a\ufffd\ufffdt\ufffd]<\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffdO*\u07ac\ufffd,\ufffdpb\ufffdfA}\ufffd9\ufffdsf\ufffdn\ufffd\ufffd_t\ufffd\ufffd$\ufffd@!\ufffd4T\ufffde\ufffdg\ufffd~\ufffd\ufffdZ\ufffd\ufffd\ufffd[\ufffdp\ufffd'\ufffd
endstream
endobj
274 0 obj
<</BitsPerComponent 8/ColorSpace 275 0 R/Filter[/ASCII85Decode/FlateDecode]/Height 64/Length 503/Width 64>>stream
+8;Z]!;/X<+#Xn-2J`STbiY9+%]B]I7J0V2o;cSYg-+1"5iN6g9W9D&L.c]SR;qE2Q
+V'l#Jr`KEMe5afLs474"n=T$(pDBAL1LDn"f(e"LY[A<;nMWmRR/#.emjG0U<hGf(
+56?RPd]H<5!rpTf$R9Xb_=9BWr-`K@QQoD9WiT=G1\$M/4\6L&oN1A^pWe7i.X/I?
+GjL/LU5E]uA*bXNOcI1XhmH1&YODDfG6$t_?1B;\14OaB&QAWkjuNH;s*sek2fWg4
+ms2n5H/]@nCFo43k^M@r14KR9A)'dHo/uP5rM14/Gs:ht:iIARp=Ack]8[8%+'Gmu
+e(-[Zj%itd]&eniroOV/Jm1-2q:j2s5$MargWiUrE*Mt&s"shj++A&j"rS$QU>#+/
+2uH<b;tV+/Fnr-:A^A+o?]3L+5PP<>Mt4VEs4q_jKUI33R=Di_\D<eWUf,dq1J7Rn
+7J[opc?#%[^Ah6.S%c5Xs',I%q>^K^rA+G7.([C~>
endstream
endobj
275 0 obj
[/Indexed/DeviceRGB 255 276 0 R]
endobj
276 0 obj
<</Filter[/ASCII85Decode/FlateDecode]/Length 428>>stream
+8;X]O>EqN@%''O_@%e@?J;%+8(9e>X=MR6S?i^YgA3=].HDXF.R$lIL@"pJ+EP(%0
+b]6ajmNZn*!='OQZeQ^Y*,=]?C.B+\Ulg9dhD*"iC[;*=3`oP1[!S^)?1)IZ4dup`
+E1r!/,*0[*9.aFIR2&b-C#s<Xl5FH@[<=!#6V)uDBXnIr.F>oRZ7Dl%MLY\.?d>Mn
+6%Q2oYfNRF$$+ON<+]RUJmC0I<jlL.oXisZ;SYU[/7#<&37rclQKqeJe#,UF7Rgb1
+VNWFKf>nDZ4OTs0S!saG>GGKUlQ*Q?45:CI&4J'_2j<etJICj7e7nPMb=O6S7UOH<
+PO7r\I.Hu&e0d&E<.')fERr/l+*W,)q^D*ai5<uuLX.7g/>$XKrcYp0n+Xl_nU*O(
+l[$6Nn+Z_Nq0]s7hs]`XX1nZ8&94a\~>
endstream
endobj
268 0 obj
<</Intent 277 0 R/Name(Layer 1)/Type/OCG/Usage 278 0 R>>
endobj
277 0 obj
[/View/Design]
endobj
278 0 obj
<</CreatorInfo<</Creator(Adobe Illustrator 15.0)/Subtype/Artwork>>>>
endobj
267 0 obj
<</BaseFont/TLLWZT+Meloriac-Regular/Encoding/WinAnsiEncoding/FirstChar 65/FontDescriptor 279 0 R/LastChar 116/Subtype/Type1/Type/Font/Widths[825 0 0 0 0 0 0 0 281 0 0 0 0 0 0 636 0 0 0 0 0 0 0 0 760 0 0 0 0 0 0 0 825 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 669 0 679]>>
endobj
279 0 obj
<</Ascent 1036/CapHeight 759/CharSet(/A/I/P/Y/a/r/t)/Descent -228/Flags 196640/FontBBox[-221 -228 1358 1036]/FontFamily(Meloriac)/FontFile3 280 0 R/FontName/TLLWZT+Meloriac-Regular/FontStretch/Normal/FontWeight 400/ItalicAngle 0/StemV 256/Type/FontDescriptor/XHeight 759>>
endobj
280 0 obj
<</Filter/FlateDecode/Length 541/Subtype/Type1C>>stream
+H\ufffd\ufffd\ufffdOLQ\ufffd\ufffdC\ufffd\ufffd\ufffdvi\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd
+\ufffd\ufffdT\ufffd\ufffd4$\ufffd&P\ufffdD\ufffdP\ufffd\ufffdd	\ufffd\ufffd\ufffdB\ufffdf+L\ufffd(\ufffd\ufffdD\ufffd\ufffd	\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdD=x\ufffdb\u6b6f
\ufffdH\ufffd^\ufffd\ufffd\ufffdd\ufffd|3\ufffd\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd7o\ufffd\ufffd\ufffdI\ufffd\ufffd\u024e!u|j2a\ufffd\u058e\ufffdf\u031a\ufffdY\ufffd(\ufffd\ufffd^\ufffdp\ufffdgY\ufffd\u0646\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd4\ufffd\ufffd\ufffd<\ufffd\ufffd(\ufffd\ufffddE5Sz\ufffd\u018c\ufffd\ufffd\ufffd\ufffd+MU\ufffde\ufffdcS\ufffd\ufffdCj\ufffd0-\ufffd\ufffd\ufffdDr\ufffdZ\ufffd^\ufffdk\ufffd#I#\ufffd7\ufffdn\ufffd\.\ufffdW\ufffd\ufffd\ufffd\ufffd;vIc\ufffd\ufffd\ufffd^r\ufffd\ufffd\ufffda@\ufffd\u7a22j\u020d\ufffd\ufffdB\ufffde4\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffdFQ
+=Go\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffde\ufffdX|6\ufffd\ufffdV\ufffd\ufffdzeVa\ufffdj\ufffd#},O\ufffd\ufffd\ufffdf\ufffd[\ufffd_\ufffd_\ufffdX%\ufffd\ufffd`\ufffd\ufffd\ufffdn\ufffd"\ufffd([\ufffd7\ufffd5!L\ufffd\ufffdc\ufffdp\ufffdJ\ufffd\ufffdKD\ufffd\ufffd\ufffd"[#\ufffd\ufffd\ufffdb\ufffd\ufffd\ufffd\ufffd\ufffdB|\ufffd@\ufffd\ufffd.C\ufffd\ufffd\ufffdkmtD\ufffdFB\u0493?.Xp\ufffd\ufffdC\ufffd\ufffd \ufffdU\ufffd\u0155nP\ufffdE`\ufffdZ\ufffd\ufffd\ufffd\ufffd_Dy\ufffd\ufffd\ufffd\ufffd�\ufffd\ufffd_\ufffd\ufffd\u01bd\ufffd\ufffdm\ufffd\ufffd\ufffd"\ufffd.C\ufffdg\u03ebecBO!\ufffdMs\ufffd\ufffd\ufffd\ufffd|\ufffd\ufffd\u03c3F\ufffd\ufffd%\ufffd^"\ufffd\ufffdhrG\ufffdxN\ufffd\ufffdL\ufffd\ufffdT\ufffd\ufffd\ufffdQgN\ufffd%\ufffdr\ufffd
endstream
endobj
273 0 obj
<</AIS false/BM/Normal/CA 1.0/OP false/OPM 1/SA true/SMask/None/Type/ExtGState/ca 1.0/op false>>
endobj
272 0 obj
[/ICCBased 281 0 R]
endobj
281 0 obj
<</Filter/FlateDecode/Length 389757/N 4>>stream
+H\ufffd\ufffd\ufffduT\ufffdK\ufffdtK\ufffd\ufffd\ufffdKJI,\ufffd\ufffdt(\u074b\ufffd4\ufffdK\ufffd\ufffd\ufffd%\u04b9\ufffdH\ufffd4J#\ufffd\u0492\ufffd(H
+w\ufffd\ufffd\ufffdq\ufffdy\ufffdy\ufffd\ufffd~\ufffd3\ufffd\ufffd\u0319g\ufffd<3\ufffd\ufffd\ufffdY9El
+@\ufffd ]\ufffd\ufffd!O\ufffd\ufffd-@\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd+BVKK
\ufffd\ufffd:\ufffdOX\ufffd~\ufffd\ufffd\ufffd\ufffd\ufffdWCa\ufffd\ufffd\ufffdiHKL\ufffd\ufffd\ufffd0\ufffdq\ufffdY\ufffd\ufffd\ufffd	`\ufffd5\ufffdc\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd
+X\ufffd]\ufffdx=\ufffd\ufffd\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffd	\ufffdX\ufffd\ufffd\u013f\u05fd\ufffd>\ufffd.\ufffdf\ufffd\ufffd\ufffd#aP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd		\ufffdD^{y8\ufffd\ufffd\ufffd\ufffd\ufffd	\ufffdd\ufffdpH\ufffd\ufffd	st\ufffd\ufffd:Y\ufffd\ufffd\ufffd\ufffd\u05eccxc
I\ufffdV\ufffd?S\ufffd\ufffd!\ufffd:\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd9[\ufffdYbQ\ufffdP\ufffd~\ufffd+rA
+S\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdHh\ufffd\ufffd\ufffdt^\ufffd\ufffd
\ufffd'0\ufffd\u07c5\ufffd�kY\ufffdX\ufffd\ufffdY9\ufffdYq\ufffdq\ufffdp\ufffd\ufffdl\ufffd'\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdz\ufffdE\ufffd\ufffd\ufffd\ufffdE$\ufffd%D>,\ufffd\ufffd^|t*K)\ufffd%/\ufffd`\ufffd\ufffd\ufffd\\ufffd\u04ab\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd&D\ufffd\ufffd\ufffd\ufffd[\ufffd7\ufffd\ufffddplDa5\ufffd|\ufffdmb\ufffd\ufffd\ufffd4\ufffd,\ufffdy\ufffdy\ufffd\ufffd{\ufffde\ufffd\ufffd5\ufffd
\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffd\ufffd\ufffd\u2685,t+w\ufffd\ufffdh\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdA
\ufffd\ufffd
\ufffd	\ufffdmk
+\ufffd\ufffdxYU\ufffd\ufffd\ufffd\uf4c0H\ufffd&%\ufffd\ufffd\u0224
+\ufffdq\ufffd\ufffdO'M\ufffdz\ufffd3\ufffdK\ufffdT\ufffd@v[NUnn^\\ufffdo\ufffd]\ufffda\ufffdb\ufffdTr\ufffd\ufffdt\ufffdl\ufffd\ufffdmE]e~U\ufffd+\ufffdj\ufffd\u05d0\ufffdZ\ufffd:\ufffdz\ufffd\ufffda\ufffdq\ufffdi\ufffd\ufffd\ufffd\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd};\ufffdC\ufffdS\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffd\_\ufffd\u06c6w\ufffd\ufffd\ufffd\ufffd\ufffdC\ufffda\ufffd\ufffdQ\ufffd1\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;>\ufffdL$Lz}4\ufffd\ufffd:%8M7\ufffdl\u030e\ufffd\ufffd\u03a7/\ufffd}\ufffdXT^\ufffd]\ufffdX>\\ufffdYm[\ufffd\ufffd\ufffdn\ufffd!\ufffdycsk\ufffd\ufffdk\u01b6\ufffd\u02b7;\ufffd\ufffdv{\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffdI\ufffds\ufffd\ufffd\ufffd0\ufffd\ufffd\ufffdX\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u076f\ufffd3\ufffds\ufffd\U000dd2d2\ufffd&\ufffd$\ufffd\ufffdW\ufffdWW\ufffd*\ufffd\ufffd)\ufffd\ufffd\ufffd!\ufffd$\ufffd$\ufffd%\ufffd!e$c\ufffd\ufffdHNOAKIMEq\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0195;KL\ufffdw\ufffd@\ufffd\ufffdY\ufffdX;\u061a\ufffd\ufffd8^\ufffd+\ufffdDsp\ufffd\ufffd\ufffd\ufffdf\ufffd\ufffd\ufffdK\ufffdO\ufffd\ufffdTC\ufffdP\ufffdp\ufffdJ%\ufffd\ufffd\ufffdD=\ufffd\ufffd+\ufffd+\ufffd\ufffd\ufffdO%$*\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd8\ufffdI\ufffdZ\ufffd\\ufffdZ\ufffd^\ufffdU\ufffdK\ufffd_wL\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd"d\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd9\ufffd=\ufffd;\ufffd\ufffds\ufffd\ufffd\ufffd_G\ufffd8/\ufffd\u0339N!G\ufffdz\ufffd[<\ufffd=\ufffd\ufffd2\ufffd|B}\ufffd\ufffd\ufffd\ufffdP\ufffdQ\ufffdz\ufffdl\ufffdH0Wc(E\ufffde\ufffdn\ufffd|\ufffdPds::5&8
 9\ufffdy\ufffdF\ufffdT"o\ufffd\ufffdd\ufffd\u4cd4\ufffd\ufffd\ufffdi\ufffd/Z\ufffdK^&gd:fg\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdl\ufffd
\ufffd\ufffdkJ\u0425\ufffde\ufffd\ufffd\ufffd\ufffdJ\ufffd*\ufffd+\ufffd\ufffd\u7bcdk\ufffdj5\ufffd\ufffd\ufffdU\ufffd\ufffd\ufffd[\ufffdZU\ufffd\ufffd\ufffdh\ufffd\ufffd0\ufffd|\ufffde\ufffdm\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd6\ufffd]B\ufffd@\ufffd`\ufffdP\ufffdp\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd?QM1Ms\u03c8\ufffd*\ufffdi\u03db.\ufffd\ufffdZ[JY\ufffdZ)X-]\ufffd\ufffdR\ufffd\u07b8\u047a\u067e\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffd\ufffd@\ufffd\ufffd?\ufffd\ufffd5\ufffd \u01d6'v\ufffdN\ufffd\ufffdg\ufffd\ufffd\ufffd\ufffd
+\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffdg\ufffd\ufffd\ufffd\ufffdL\ufffdC#u!\ufffd\ufffdM\ufffdM\ufffdM\ufffdE\ufffdvAms\u02d4F\ufffdV\ufffdN\ufffd\ufffd\ufffdA\ufffd\ufffd\ufffd\u031dGL\ufffdw\ufffdA\ufffd\u032c,\ufffd\ufffdl\ufffdl\ufffd\u063fs\ufffd\u075b\ufffd\ufffd\ufffd\ufffdn\ufffd\ufffd\u037d\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd!B\ufffd�"\ufffd\ufffd<b\ufffd\ufffd4$\ufffd\ufffd\ufffd\ufffd\u0747kR\ufffd\u0493\ufffd\ufffde\ufffdd\ufffd\ufffd\ufffdk*\ufffdJ\ufffd\ufffdY*/TS'<\ufffdS\ufffdV\ufffd\u0488\u050c\u040a\u040e\u0509\u040d\u040b\u040f0\ufffd4\ufffd2\ufffd\ufffd\ufffd\ufffd?M4I~\ufffdf\ufffd\ufffd\ufffd\ufffd\ufffds-\ufffd,\U000e1170"+\ufffdu\ufffdM\ufffdm\ufffd]\ufffd}\ufffdC\ufffdc\ufffdS\ufffdQ\ufffd\\ufffdR\ufffdZ\ufffd\ufffds\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdG\ufffd\ufffdi\ufffd\ufffdH\ufffd\ufffd\ufffd\ufffd3G\ufffdF\ufffdFaG\ufffdD\ufffd\u01ac\ufffd\ufffd\u010d\ufffd\ufffd&\ufffd$V''g\ufffd$\ufffdF\ufffd\ufffd\ufffdLG\ufffd\ufffd\u02f0\ufffd4\u0342d\ufffd\ufffd\ufffd\ufffdj\ufffdi\ufffdkh\ufffd\ufffdC\ufffdf%V\ufffdNe\ufffd\ufffdAq\ufffdYU\ufffd\u06aaG^/\ufffd\ufffd\u0543\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffdZ{\ufffdV\u06b1:\ufffd;\ufffd`\ufffd\ufffd=\ufffdc}\ufffd\ufffdn\ufffdK\ufffd
\ufffd\ufffd\ufffdFv\ufffd(\u0783\ufffd\ufffd> 'R&k?\ufffd\ufffd\ufffd3\ufffd?\ufffd4+:\ufffd6o\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffd\\ufffd\u04b1\u06bf6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffd\ufffd\u029d\ufffdo\ufffd\ufffd\ufffdF?L\ufffd\ufffd\ufffd\ufffdT;\ufffd:\ufffd>\ufffd::>\ufffd:\ufffd;\ufffd\ufffdeq\ufffdvx^sa\ufffd\ufffd\ufffdw\u0765\ufffd\ufffd\u0295\ufffd\ufffd'\ufffd_\ufffdE\ufffdF\ufffdO\D\ufffdK\ufffdLtAnF\ufffdF)F\ufffd
 |\ufffd\ufffd\ufffd\ufffd\u052d6\ufffd\\ufffd`\ufffd@z?\ufffdm+F\ufffd;\ufffdL\ufffdwiAh\ufffdy\ufffd\ufffd\ufffd\u0356\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffdg\ufffdw\ufffd~_
\ufffd@\ufffd\ufffd\ufffdZH_XA,\ufffd"F)\ufffd%\ufffd/\ufffd*9\ufffd\ufffd\ufffda\ufffdZ:\ufffdQ\ufffd\ufffd\ufffd,\\ufffdB^_AU\U000614802\ufffd
+\ufffd*\ufffd\ufffd\ufffd\ufffd'[j\ufffd\ufffdo5[\ufffd\ufffd\ufffd\ufffduR1u\ufffd\ufffdh`f\ufffdm$1\ufffdxJgBdr\ufffdl\ufffdt\ufffdl\ufffdy\ufffdy\ufffdE\ufffde$\ufffdfe\ufffdg-g#`\ufffddGbwj\ufffd\ufffd0\ufffd\ufffd\ufffdTOC9;\ufffd\ufffd\ufffd \ufffd\u0728\ufffd\ufffd\u077fx\ufffdz6z\ufffdx\ufffd\ufffd8\ufffd\ufffdI\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd=A\ufffd\ufffd\ufffd!.\ufffd\ufffda\ufffdAx\u06d1\ufffd\ufffd\u03ca\ufffd\ufffd\ufffd\ufffd}\ufffdb\ufffdG\ufffd-\ufffd\ufffd\ufffd\ufffd\u0792\u0113\ufffd\ufffd\ufffd\ufffdx\ufffd`\ufffdG\ufffd/\ufffd\ufffd\ufffd\ufffd\u051c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffd_\ufffdO\ufffd?\ufffd0\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u06ec\u056d\u042e\u02ef\u01f0\u0131�\ufffd\ufffd\ufffd\ufffd�\u0176\u0237\u0378\u04f9\u06fa\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \ufffd0\ufffd@\ufffdR\ufffdf\ufffdz\u018f\u01e6\u023e\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd*\ufffdG\ufffdc\u0400\u045f\u04bf\ufffd\ufffd\ufffd\ufffd'\ufffdL\ufffds\u065b\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdF\ufffds\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffd6\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffdZ\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffd?\ufffd~�\ufffd\ufffd~i\ufffd\ufffd~L}\ufffd\ufffd~cbA\ufffd~\ufffdDa\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffd~t\ufffdy\ufffd~W\ufffd\ufffd\ufffd\ufffd~O\ufffd\ufffd>~\\ufffd\ufffd\ufffd/~\ufffd\ufffd\ufffd|\ufffd~\ufffd\ufffd\ufffd`\ufffd\ufffd\ufffdC\ufffd\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}%\ufffd\ufffdH}\ufffd1\ufffdX}%\ufffdz\ufffd\ufffd}K\ufffd\ufffd\ufffd}\ufffd\ufffd
{N}\u05cb<_\ufffd~7\ufffd\ufffdA\ufffd~\ufffd\ufffd-\u03c8\ufffd\ufffd|
 \ufffd\ufffd\ufffd|\ufffd\ufffd\u01f2|+\ufffd\ufffdE|[\ufffd\ufffd\ufffds|\ufffd\ufffd\ufffdz}\ufffd\ufffd^\ufffd}w\ufffdO@\ufffd}\ufffd\ufffd-\ufffd~\u010b\ufffd\ufffd	{G\ufffdu\ufffd\ufffd{D\ufffdz\ufffd{]\ufffd\u012c\ufffd{\ufffd\ufffdf\ufffd{\ufffdZx\ufffd|[\ufffd\ufffd]\ufffd|\u03d5M?\ufffd}R\ufffd\ufffd<}\u018e\ufffd\ufffd\ufffdz\ufffd\ufffd]\ufffdYz\ufffd\ufffdH\u0127z\ufffd\ufffd\ufffd\ufffd|z\ufffd=\ufffd\ufffd{L\ufffdNw\ufffd{\ufffd\ufffd\ufffd\\ufffd|=\ufffd\ufffd>\ufffd|\ufffd\ufffdv|\u06d0I\ufffd8z/\ufffdr\ufffd
z\ufffd;\ufffdbz'\ufffds\ufffdMzd\ufffd6\ufffd\ufffdz\u026cqv\ufffd{D\ufffd[\ufffd{\ufffd\ufffd0>|;\ufffd|\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffda\ufffdIy\ufffd�\ufffd?y\ufffda\ufffd\ufffdzY\ufffd\ufffdvz\u076e\ufffd[{^\ufffd\ufffd=c{\u0424\ufffdI{R\ufffd\ufffd*y\ufffd\u07c4\ufffd\ufffdyf\ufffd\ufffd\ufffdUy`\ufffd\ufffdVy\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffduKz\ufffd\ufffdZi{\ufffd\ufffd<\ufffd{z\ufffd%\ufffdz\u020e\ufffd\ufffd\ufffd~+\ufffd~\ufffd}\ufffd\ufffd\u0347}W\ufffd\ufffd\ufffd0}3\ufffd\ufffd\ufffd}Ht\u0404\ufffd}\ufffdZk\ufffd\ufffd}\ufffd=\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffdz\ufffd\ufffd\u0247\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd!\ufffd~\ufffd\ufffd\ufffd\ufffd\u0404d\ufffd*s}\ufffd\ufffdY\ufffd\ufffd\ufffd<9\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffdS\ufffdw\ufffdu\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffdVrU\ufffd\ufffd\ufffdW\ufffd\ufffd\u0608|;,\ufffd\ub1d4\ufffd\ufffd{\ufffd\ufffd\ufffdR\ufffds\ufffd\ufffd\u0472\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;\ufffd\ufffd\ufffd\ufffd:\ufffd8\ufffd\ufffd\ufffd\ufffdq)\ufffdP\ufffdCV\ufffd\ufffd\ufffd:4
 .\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffd\ufffd\u0204\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\U000610a1?\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffdV\ufffdu\ufffd\ufffd9S\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffd\ufffdb\ufffd\u0583\ufffd\ufffd\ufffd\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffd\u0541N\ufffd\ufffdn\ufffd\ufffd	\ufffd\ufffdU\ufffd\ufffd38\ufffd\ufffd\ufffd8\ufffd\ufffd\ufffdA\ufffd/\ufffd\ufffd\ufffd\ufffd\u036c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u03b4z\ufffd\ufffd6\ufffd\u07c6\ufffd\u04e9\ufffdn1\ufffd\ufffd\ufffd\ufffdT\\ufffde\ufffd\ufffd7\u0740t\ufffdXT\ufffd\ufffd\ufffd\ufffd)\ufffd$\u0315\u032f\ufffd6\ufffd;\ufffd\ufffd\ufffde\ufffdC\ufffd\ufffd\u02b7\u02c6	\ufffdi\ufffd\ufffdmw\ufffd3\ufffd\ufffdS\u0180\ufffdV7M\ufffd
+\ufffd\\ufffd\ufffdl\ufffdG\ufffdN\ufffd\ufffd\u063b\ufffd\u0681\ufffd\ufffdN\ufffd\u0101\ufffda\ufffd5\ufffdt\ufffd\ufffdN\ufffd\ufffdzl\ufffd\u07f4\ufffdS<\ufffd\ufffdH6\ufffd\ufffd\ufffd*\ufffd\ufffd\ufffd<\ufffda|\ufffd\ufffdk\ufffdz|C\ufffdV\ufffd\ufffd|\ufffd\u01cd|\ufffd\ufffd\ufffd\ufffd|Ik\ufffd\ufffd\ufffd|\ufffdRu\ufffd\ufffd}26\ufffd\ufffd'~2\ufffd\ufffd\ufffd\ufffdF\ufffd-\ufffd\ufffd\ufffd\ufffdB\ufffd\ufffd\ufffd*\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffd\ufffd\ufffd\ufffd\ufffdQ^\ufffd\ufffd\ufffd@5z\ufffdI\ufffd`\ufffd\ufffd\ufffd\ufffd\u0673\ufffd\ufffd$\u011d\ufffd"\ufffd\ufffd\ufffd\ufffdc\ufffd\u07d8\ufffd\ufffd\ufffd&\ufffdU\ufffd\ufffd\ufffd\ufffdij\ufffd\ufffd\ufffd|PJ\ufffd\u02c7v4v\ufffdy\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd.\ufffd2\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u843ehS\ufffd\u63bcO[\ufffd\ufffd\ufffd3\ufffd\ufffd�\ufffd(\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\u044cx\ufffd&\ufffd$\ufffd\u051es\ufffd\u0489h\ufffd
+~\ufffd2\ufffd\ufffdgK\ufffd>\ufffd-N}\ufffdo\ufffd\ufffd2\u0646\ufffd\ufffd
N\ufffd%\ufffd\ufffd\u0567\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffdw\ufffd\ufffd\ufffd\u05a3A}\u21e4\ufffd\fX\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffd\u0758\ufffd2,\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdK\ufffd\ufffd\u0510\ufffd3\ufffd\ufffd\ufffd\ufffd\ufffdg\ufffd\ufffd\ufffd�\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffd}
+\ufffd0\ufffde\ufffd\ufffd6\ufffd\ufffdM\ufffd_\ufffd\ufffd1\ufffd\ufffd\ufffd?\ufffd\ufffd\ufffd1\u04e3\ufffd\ufffd\ufffd\u01fe\ufffd\ufffd\ufffdI\ufffd\ufffd^\ufffd\ufffd\ufffd\ufffdI|B\ufffd\u032fd\ufffd\ufffd\u072awL\ufffd\ufffd\ufffde1$\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdr\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd
\ufffd\ufffd1\ufffd\ufffd\ufffdS{\ufffd\ufffdz\ufffd|di\ufffd\ufffd\ufffd\ufffdL
\ufffd\ufffd\ufffdg0\ufffd\ufffd\\ufffd\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd{[\ufffd\ufffd\ufffdG{!\ufffd\ufffd\ufffd\ufffd{	\ufffd\u0794`{&y\ufffdE{xbi\ufffde{\ufffdJr\ufffd\ufffd|\ufffd/c\ufffd5}~
+~\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffdf\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffdKx+\ufffdC\ufffd\ufffda|\ufffdu\ufffd\ufffdI~\ufffd\ufffd\ufffd\ufffd.y\ufffdW\ufffd\ufffd	\u03ce\ufffd\ufffd\ufffd\u04d9\u07ce\ufffd\ufffd\ufffd%\ufffd�\u5518\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffdw!\ufffd^\ufffdT`\ufffd\ufffd\ufffd\ufffd^H\ufffd\ufffd*\ufffd\ufffd-\ufffd\ufffd\ufffd\ufffd\ufffd	5\ufffdG\ufffd\ufffd\u0228\ufffd\u760e\ufffd\ufffd=\ufffd\u03a0\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd\ufffdr\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd_\ufffd\u048dRG\ufffd\ufffdf\ufffd\ufffd,\u078b\u030b\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffd,\ufffd\ufffd\ufffd\u0195\ufffd\ufffd\ufffd\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0498\ufffdt\ufffd\u0655\ufffd^\ufffd\ufffd1\ufffd\ufffdF\ufffd\u0151\ufffd,;\ufffd'\ufffd\ufffd<\ufffd!\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffdl\ufffd~\ufffdJ\ufffd\ufffd\ufffdJ\ufffd\ufffdt\ufffdS\ufffd#]\ufffd\ufffd\ufffd\ufffd'FA\ufffd4\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd;\u06caL\ufffdP\ufffdf\ufffd&\ufffd\ufffd\u0254\ufffd\ufffd\u079d\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0568\ufffds@\ufffd\u590f]\ufffd0\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffd+:\ufffd\ufffd\ufffd\u0587SS	\U00027828\ufffd\ufffdjVPp,<XQ)\ufffdXVl\ufffd(Js\ufffd&\ufffdJ!\ufffd\ufffd\ufffd\ufffdK{\ufffd@B\ufffd\ufffdE\ufffd.\ufffde\ufffd\ufffd\ufffdWqQ\u4193\ufffd\ufffd\ufffd~3\ufffd\ufffd7\ufffd\ufffd\ufffdF\ufffdHI^\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u04e1\ufffd\ufffd\ufffd+j&Y\ufffd\ufffd\ufffdb\ufffddML\ufffd\ufffd\ufffd{#\ufffd\ufffd\ufffd\ufffd\ufffd)F\ufffd\ufffd\ufffdA\ufffd;q\ufffd\ufffdT0\ufffd\ufffd_\ufffd
^\ufffd\ufffd9I\u0764\ufffdx\u05ba\ufffd\u01a2YFh\ufffd9\u0545\ufffdhX;J\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd
 n+j\ufffd\u0121\ufffd(\ufffdm,\u05bcJ\ufffd\ufffd\ufffd\ufffd\ufffd(Va\ufffdV/\ufffd\ufffd\ufffda\u0611\ufffd@\ufffdQ~.\ufffd8_]\ufffd\ufffd\ufffd7]\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdg\ufffd|\ufffdF\ufffd)-\ufffd/\ufffd\ufffdMH\ufffd|\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd8\ufffd%\ufffdoFx\ufffd\ufffdC\ufffd\ufffd<\ufffd\ufffdR\ufffdl\ufffdA\ufffd^\ufffd\ufffd\ufffd\ufffdQ\ufffdl\ufffd\ufffdz\ufffdrJAU\ufffdU\ufffd\ufffd\ufffd\ufffdd*\ufffd\ufffd\ufffd\ufffdN\ufffd$i\u070f\ufffd
#\ufffdv
b7F\ufffd*4\u0782\ufffd\ufffd\ufffd
+
\ufffd\ufffd\ufffdpv\ufffdi\ufffdx\u0596\ufffd\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffdJ\u06f1\ufffd#\ufffd
+\ufffd\ufffdW\ufffd\ufffdh\ufffd\u0509\ufffdl\ufffd"\ufffdkxwVjG\ufffdDz\ufffd\ufffd\ufffd*\ufffd\ufffd\u07dcx\ufffdW\ufffd\ufffd\ufffd:\u01a9d\ufffd\ufffdP\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffd4W\ufffdM\ufffd\ufffd[\ufffd\ufffd,]\ufffd\u02ab$\ufffd\ufffd\ufffdW\ufffd\ufffd$I\ufffd&\ufffd\ufffdN\ufffd\ufffd\ufffd}\ufffd7�
s\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd1@\ufffd9\ufffdT\u024e.\ufffdE\ufffd\ufffdzN\ufffdDf\ufffd\ufffd*uwr \ufffd\ufffd\ufffd\ufffd	\ufffd*\ufffd#\ufffd\ufffd\ufffd\ufffd,\ufffdh\u0605\ufffd\ufffd"\ufffd8=\ufffd\ufffd\ufffdN\ufffd
\ufffd%\ufffd=(\ufffdp\ufffd\ufffd\ufffdQu\ufffd9s\ufffdL\u04d3(\ufffd&\ufffd\ufffdw\ufffd\u06be\ufffd?\ufffd\ufffdER\ufffdAHi.R\ufffd~	\u0504\ufffd6\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd*t\u04143*\ufffd\ufffd\ufffd\u06f1\ufffdx#\ufffdm?r~3\ufffd\ufffd2\ufffd+\ufffdw\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd6\ufffdyXa\ufffdTO\ufffd#\ufffd\ufffd
+U\ufffd�<\ufffd_)\ufffdI\ufffd(\ufffd\ufffd}\ufffd\ufffdW2S\ufffdX U\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd
M\ufffd\ufffdf\ufffd_T\ufffd)\ufffd\ufffd\ufffd\ufffd?k\ufffd\ufffdYYF\ufffd\ufffdK8\ufffd\ufffdu;J$\ufffd\ufffd�*1T\ufffd>,\ufffd\ufffd#h\ufffd%T\ufffd,\ufffdQ\u06e5{[\ufffd\ufffds\ufffd:\ufffd\ufffd9\U000c5f13\ufffd&^!\u0553\ufffda\ufffd\ufffd@\ufffd!\ufffd\ufffd"y\ufffd
+\ufffd\ufffd.\ufffd\ufffdJl6m\ufffdHj\ufffdu\ufffd,b\ufffdU6\ufffd+s\ufffd\ufffd\ufffdh\u0738d\ufffd-\u02a5\ufffd}\ufffdwi\ufffd\ufffd-s\ufffdun=0\ufffd\u013d\ufffdi-_\ufffd*)U\ufffd\ufffd_\u02c8\ufffd\ufffd\ufffd\ufffdb$\ufffd\ufffdna+;\u03e7T\ufffd;p\ufffdpA7\ufffd\ufffd\ufffd\ufffdC\ufffd4\ufffd\ufffd.*\ufffdI\u07e5\ufffda\ufffd8\ufffd\ufffdM\ufffd\ufffdm\ufffd.\ufffd\ufffd\ufffdACi\ufffd\ufffd\ufffd7\ufffd\j|fi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u052b)\ufffd\ufffd]\u07ad\ufffdj\ufffd\ufffd\ufffd\ufffd\u0284\ufffd\ufffd\ufffdU\ufffd]\ufffd3(�\ufffd\ufffdwh\ufffdJ\ufffd\ufffdc\ufffdh-\ufffd4x7\ufffd\ufffd\ufffdh\u05ff*P0\ufffdH\ub40eL\ufffd\ufffd\ufffd\ufffd\ub787\u06a1u\ufffd\ufffd�\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd,\ufffd{\ufffdBz}\ufffd\ufffd8\ufffdv\ufffdg\ufffdg\ufffd\u04b2\ufffdd[\ufffd!XTZ\ufffdZ.\ufffd\ufffdvl\ufffdA\ufffd\ufffd\ufffdg\ufffd\ufffd
+{;S\ufffdm\ufffd`v\ufffd\ufffd\u063f`~\ufffd?g\ufffda.\ufffd
+3\ufffd�\ufffd{\ufffd\ufffd\ufffd\ufffdL\ufffd^\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffde\ufffd4\ufffd\ufffd]\ufffdL\ufffd<pq\u07b4\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd!\ufffd\ufffdG\ufffd\ufffd]\ufffdlv\ufffd\ufffd\ufffd:DeH\ufffd\ufffdXq\ufffd\ufffdE\ufffd\ufffdK4kHoS|\ufffdX\ufffd\u05bdO\ufffd7\ufffd\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd*\ufffd*\ufffd+\ufffd\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffdh\ufffd`\ufffd\ufffd\ufffd?\ufffd\ufffd\ufffdk6\u0764g\ufffd\ufffd\ufffd,\ufffdM{ST3\ufffd\ufffd`\ufffdb5\ufffd\ufffdXE\ufffd#*\ufffd\u0456}\ufffdz\ufffd#C\ufffd//\ufffd\ufffd\ufffd\ufffd\ufffd7\ufffd\ufffd}\ufffd\ufffdV;\ufffd9\ufffdT\ufffd\ufffd)?\ufffd\u0788\ufffd\ufffd\ufffd2[\ufffd\u064f\ufffd]\ufffdn\ufffd$\ufffd~\ufffd\ufffd\ufffd\ufffdf\ufffd\u040c,\ufffdd\ufffd\ufffd\ufffdp,\ufffd\ufffdB\ufffdAdrH\ufffd\ufffd]`u\ufffd\ufffdP\ufffd\ufffdV\ufffdk\ufffdaEV\ufffdvYN\ufffd\ufffdU5/y\ufffdfD.\ufffd\u0761\ \ufffd1\ufffd\ufffd\ufffd\ufffdQ\ufffda#K\ufffd\ufffdE\ufffd:\ufffd|\ufffd\ufffdN[k\ufffd=\ufffd&[],\ufffd\ufffd\ufffd\ufffd1$\ufffd\ufffd\u03be\ufffdB\ufffd\ufffd\ufffd0Y\ufffd(\ufffd\u07caq$\ufffd\ufffd\ufffd]\ufffd!{Ik5\ufffdU\ufffd3\ufffdj\ufffd=Or\ufffd\ufffd\ufffd)\ufffd<V\ufffd\ufffd
A8H\ufffd\ufffd:YjD!\ufffd\ufffdL_\ufffd\ufffd|O\ufffd\ufffd\ufffd\ufffdl\ufffdxE{EY[\ufffd\ufffd9\ufffd\ufffd#Ev\ufffdx\ufffd\ufffd\ufffd2\ufffdE\ufffd\ufffdas=\ufffd[R\ufffd\ufffd\ufffdQ\ufffd\ufffdi\ufffd\ufffd*\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd66\ufffd`\ufffd\ufffd\ufffd\ufffd\ufffd\u03ce,\ufffd\ufffd+\ufffd#\ufffd,i\ufffd\ufffd1\ufffd\ufffd\ufffd\ufffdA2\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffd
 \ufffd\u01aa\ufffdW\ufffd\ufffd\ufffdm\ufffd\ufffd\ufffdH\ufffdXJ\ufffdNP\ufffd+\ufffd)\ufffd\u0327\ufffd+\ufffd\ufffd=l\ufffd\ufffd$\ufffdzU\ufffdkb\ufffd\ufffd]\ufffdi\ufffd\ufffd[:\ufffd\ufffd<\ufffd\u65f0\ufffd\ufffdA\ufffd\ufffdr)<\ufffd\ufffd\ufffd\ufffd\ufffd+e.\ufffd\ufffd
+\ufffd%\ufffd\ufffd\ufffd\u04c2\ufffdB\ufffds\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffd\u010f[\ufffd\ufffd~\ufffd}F.+}W\ufffd\ufffd\ufffd\ufffdt\ufffd=\ufffd\ufffd 
+\ufffd\ufffdK\ufffde&\ufffd\ufffd,\ufffd^\ufffd\ufffd-\ufffd\ufffdv\ufffda\ufffd(0\ufffd\ufffd\ufffd\ufffd\ufffdt\ufffdtz\ufffdS\ufffd\ufffd\ufffdw\ufffd0D\ufffd\ufffd6j\ufffd\ufffdtl\ufffd\ufffd.\\ufffdlV\u0564\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd-g\ufffd	[\u046d\ufffd'\ufffd\ufffdx\ufffd|\ufffd|D\ufffdD\ufffd\u07f5\ufffd\ufffd\ufffd\ufffd\ufffdv\ufffd\ufffdwi\ufffd\ufffd\ufffd8\ufffd\u01b0=\ufffd\u074b\ufffdbY\ufffd\ufffd
+\ufffd\ufffd\ufffdTC7j\ufffdKI\ufffd\ufffd\ufffdX\ufffd7\u043e\ufffds\ufffd{\ufffd\ufffdW|}\ufffd\ufffd&\u9977MR\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffdrs\ufffd%5\u052f1\ufffdG\ufffd\ufffd\ufffd*=\ufffd\ufffdV\ufffdDM\ufffd\ufffd\u9da2l\ufffd\ufffd\ufffd`JY\ufffd\ufffd\ufffd\ufffdKe\ufffd\ufffd\ufffd\+\ufffd\ufffdkl\ufffd=\ufffd\ufffd\u05bcsr\u034c\ufffd
+\ufffd\ufffd\ufffd\ufffd_L\ufffd\ufffd\\ufffdE\u070b\u02ae\u0724H)\ufffdB\ufffd\ufffd\ufffd"\ufffdn\u0115)J\ufffd\u06d9\ufffd\ufffd3g\ufffd\ufffdY\ufffdi&M{&M\u0374I\ufffd\ufffdB+!%\ufffd\ufffd,O\ufffd\ufffd\ufffd=Y>7o\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd\ufffd!w\ufffd\ufffd\ufffd\ufffdI\ufffd~\ufffdIr\ufffda^=\ufffdC\ufffd#Z\ufffd\ufffdh\ufffd\ufffd`W\ufffdu}p\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffd"\ufffdz\ufffd7ff&\ufffd3\ufffd\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffd\ufffd\ufffdJ8\u04b65\ufffd\ufffd\ufffdm\ufffd
+u\ufffd\ufffdR\ufffd_,^V\ufffd\ufffdS&\ufffdaR\ufffd~Pf\ufffd\ufffdLL_Dw\ufffd\ufffd*\ufffd\ufffd`\\ufffd-\ufffd9]q\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdT\ufffdI\ufffd6)\ufffd>u6	D\ufffd`e\u0362/\ufffd\ufffd\ufffdxq\ufffdY%\ufffd9\ufffd\ufffd\u029c\ufffd;\ufffd�O\ufffd\ufffdd\\u02fe\ufffdP\ufffd&eR\ufffdz\ufffd\ufffd;\ufffd]\ufffd\ufffd\ufffd\ufffd.\ufffdR\ufffd<o\ufffd\ufffd\u03a1\ufffd]\ufffdP{?\ufffd:\ufffdr\u0328\\ufffd\ufffd\ufffd\u02bbb	\ufffd\u04a4\ufffd3|\ufffd\ufffd\ufffd\ufffdm \ufffds\ufffd\u061f\ufffd\ufffd\ufffdW\ufffd9\ufffd\ufffd\ufffd\ufffdoZt]Rn\ufffd\ufffd�\\ufffdc\ufffdW\ufffd#+\ufffdn\ufffdI&\ufffdg\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffdAjs\ufffdN\ufffd06\ufffdHiD\ufffd\ufffd\ufffd\ufffd'@\ufffd\ufffd\ufffd\ufffdJ+\ufffd\ufffda5V~\ufffdcR\ufffdI\ufffd\ufffd\u032b\ufffdvwtU\ufffd\ufffdc[3+?F|l(\ufffd\ufffdi\ufffd\ufffdU\ufffd\ufffd\ufffd\ufffd\ufffd^+O\ufffd?R\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\ufffd1\ufffdHqil\ufffd\ufffd$W�h\ufffd\ufffd\ufffd\ufffd=\ufffd\ufffd\ufffd(\ufffdRE
+\ufffd\ufffd1\ufffdB\ufffd\ufffdv\u045f\ufffd\ufffdn\ufffd\ufffdF/\ufffd\ufffd
Bs\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffdY\ufffd\ufffd\ufffd\ufffd9>\ufffd\u07163\ufffd\ufffd\u0217qI\ufffd\ufffd
\u06a3\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd_\ufffd1\u0223\ufffd\u03b2\ufffd\ufffdi\ufffd\ufffdJiX\ufffd0\ufffdWV\ufffd\ufffd\ufffdH[8g\ufffd\ufffd_\ufffd/\ufffd\ufffd\ufffd
+n3\ufffd`\ufffd	\ufffd\ufffd\ufffd38A.|\ufffdf|\u04580I\ufffd\ufffd6\ufffdb\ufffdv\ufffd%\ufffd&\ufffd ;Y\ufffd\ufffd\u3fdc\ufffd\u0484#\ufffdd\ufffd\ufffdD.)\ufffd\ufffd.p\ufffd'\ufffd\ufffd3\ufffdJ\ufffd12K[D\ufffdu\u0265$s8\ufffdI<\ufffdR\ufffdi\ufffdm\ufffdJ\ufffd\ufffd8\ufffd}\ufffd\ufffdf\ufffd\ufffd \ufffd\ufffd\ufffdDJ\ufffd\u0180\u0e83ws\ufffd!\ufffd\u02ab\ufffd\ufffd\ufffdr\ufffd\ufffdRX\ufffd\ufffd-\y^\ufffd*\ufffd\u030fLd'\ufffd\u96f29?)
"\ufffdq\ufffd\ufffd^\ufffd\ufffd5\ufffd/<4\ufffd\ufffdi
+\ufffd\ufffdQ<\ufffd\ufffd\ufffd\ufffd
+\ufffd\ufffd;/\ufffd\ufffd\u0531\ufffdJB"\ufffd\ufffd\ufffd7\ufffd\ufffdt\u035a\ufffd\ufffd,m\ufffd\ufffdXd\u06be^\ufffd;\ucd1e\ufffd\ufffd&s\ufffd`\ufffdY\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffd\ufffd\ufffd\ufffd\ufffd{>\u018a\ufffd.\ufffd\ufffd\ufffdz^48\ufffd\ufffde!\ufffd\ufffdR\ufffd6}\ufffd\ufffdvc\ufffd\ufffd\ufffd\ufffdMi\ufffdoz\ufffd\ufffd\ufffdo\ufffd0\ufffd'\ufffd=\ufffd~\ufffd\ufffd\ufffdi,3\ufffd:?-\ufffd\ufffd\ufffd?oS,\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd#\ufffd\ufffdR\ufffdOa\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd;\ufffd	?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffdB\ufffd\ufffd\ufffd\ufffd
+\ufffd\u059eI\ufffd\ufffd\ufffd\ufffdO\ufffd\u075f\ufffde#}\u052f\ufffdN$\ufffd\\ufffdl?\ufffd]\ufffd,\ufffd\ufffd\ufffd\ufffdy,\ufffd\ufffd>&\u0420\ufffd\ufffd\ufffd\ufffdq]\ufffdyh\ufffd0Aq\ufffd\ufffdK)\u011dB\ufffdF\ufffd\ufffd\u048dcH:\ufffd\ufffd-h-\ufffd\u01dfc\ufffd\ufffd\ufffdf)\ufffdK9T\ufffd\ufffd127]\ufffd\ufffd\ufffd\ufffdq\ufffd\ufffdEjL\ufffd\ufffd\ufffd<>h\ufffd\ufffd;\ufffd|\ufffdU
+\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdd\ufffdp\ufffdG
+\u01ab\ufffd`\ufffd&!\ufffd\ufffd\ufffd8a\ufffd\ufffdl\ufffd\ufffd\ufffd`83>\ufffd.\ufffd\ufffdq\ufffd\ufffd\u0242\ufffdn\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdA\ufffd9
+;\ufffd\uf821\ufffd\ufffd\ufffd`\ufffd\ufffdH\ufffd\ufffdB\ufffdy\ufffdg\ufffd\ufffd\ufffdKB\ufffd\ufffd\ufffd*k\ufffd\u3c172fF\ufffd=#\ufffd\ufffdOM\ufffd\ufffd \ufffdeT?
+m\ufffd\ufffdTm\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffdOB\u06caV\ufffd\ufffd<\u0246F('\ufffdn3u\ufffdG~\ufffd\u022e#\ufffd7\u040a\ufffd9\ufffd\ufffd[\ufffd\ufffd\u0661`N\ufffds\ufffd.\ufffdP..\ucf64'Knp\ufffd\ufffdF\ufffd\ufffd\\ufffd?
\ufffdB>\ufffd\ufffd\ufffd-\ufffd\ufffd\ufffd\ufffd`\ufffd\ufffd\ufffd\ufffdN\ufffd\ufffdW\ufffdO\ufffdOW\ufffdB\ufffd\ufffd\ufffdl\ufffdf\ufffd\ufffdx\ufffd\ufffdW\ufffd^\ufffd<x==\ufffd\ufffd\ufffdZ/~\ufffd4/\ufffd.*g�\ufffdP\u02b2\ufffd<*V-}&\ufffd\ufffd\ufffd\u065f\ufffdw\ufffdz\ufffd\ufffdWq=g?:\ufffd\ufffd;[\ufffd\ufffd\ufffd-\ufffd(\ufffdZ6*<\ufffd\u0208\ufffd\ufffd`p?\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffdeQ\ufffdy\u045e>\ufffdb\ufffd\ufffd\ufffd-_\ufffdx&*/\ufffd\ufffd(\ufffdj\ufffd\ufffd\ufffd\ufffd_\ufffd=\u07c6\U000d12a2\ufffdzF\ufffd\ufffd\ufffd`\ufffdLd\ufffd\ufffdE:\ufffd\ufffd\ufffdSN\ufffd\ufffd\u0294@S\ufffd 0\ufffd\ufffd\ufffd3\ufffd|T\ufffdO\ufffdKo\ufffdk\ufffd\ufffdt\ufffd\ufffdo}bF\ufffd\ufffd\ufffdz$4\ufffd\ufffd\ufffd-\ufffd\ufffd\ufffd,\ufffd.m\ufffd\ufffd'j*J\ufffd\ufffd\ufffd|)J\ufffd6\ufffdB\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdP^\ufffd3ew\u072bpX\ufffd\ufffd\ufffd.\ufffd\ufffd*\ufffd\ufffd,0\ufffd\ufffd7xP\ufffd\u06b3\ufffd:2\ufffdX\ufffdOT\ufffd21|"7\ufffd\ufffd=<J}|\ufffdwl\\ufffd\ufffd}vGic\ufffd\ufffdQ\ufffd\ufffd\ufffd\ufffdS\ufffd]\ufffd<\ufffdC\ufffdj\u0239*	@8\ufffd-f\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0742={�(
\ufffd\ufffd\ufffd\ufffd]\ufffdx\ufffd\u0468\ufffdn\ufffd\ufffd\ufffd?\ufffd\u03d1]\ufffdq\ufffdO\ufffd\ufffd\u02cf\ufffdExyU\ufffd\ufffd\ufffdc\ufffd0\ufffd\ufffdt\ufffdM\ufffd]\ufffd\ufffdu3\ufffd\ufffd\ufffdj \ufffdo)(Co\ufffd\ufffd~2\ufffds\ufffd
 l\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd\ufffd\u0599\ufffd\ufffd
\ufffd{\ufffd\ufffdL\ufffd7z<\ufffd\ufffd"\ufffd!s\ufffd\ufffd\ufffd[\ufffd\ufffdH\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd*\ufffd{\ufffd\ufffd\ufffd1\ufffd\ufffdl\ufffd\ufffd1\ufffd\ufffd,V\ufffd\ufffd&I*[\ufffdv\ufffd$\ufffd#1/\ufffd\ufffd5\ufffdZ\ufffd\ufffd\ufffdp(3\ufffd\ufffd]\ufffd8\ufffd\ufffdi2|(\ufffd2\ufffd| z\ufffdD\ufffd\ufffd5 N\ufffds\u05ac\uf13f\ufffd\ufffd\ufffd\ufffdviV\ufffd`D\ufffd0�\ufffd\ufffd\ufffd]\ufffd\ufffd\ufffdR)L\ufffd!'n\ufffd\ufffd"\ufffd <v~\ufffdx\ufffd\ufffd)\ufffd~\ufffdif\ufffd\ufffd
+wnK\ufffd\u0711QV\ufffdB\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffd\u053dp\ufffd\ufffd *\ufffd+\u062a\ufffdED\ufffd\ufffd\ufffd*\ufffd \ufffd\ufffd\ufffd\ufffd\ufffd(\ufffd\ufffd\ufffdo	B\ufffd'{p\ufffd\ufffd\ufffdwH\u0606\u02b4*J\u046amA-n\ufffd\ufffdWjGE\ufffd\ufffd\ufffd\u07af\ufffdy~\ufffd~?r\ufffdI^WO\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffdl)\ufffd\ufffd\u01b6\ufffdW\ufffd\ufffdgiX\ufffd\ufffd\ufffd"\ufffdC\ufffd#\ufffdk\ufffd\ufffdnA\ufffd\ufffd\ufffd\ufffd\u02fb\ufffdr\ufffd\ufffd\ufffd)b\ufffd!\ufffdU\ufffd\u06b2I\ufffd\ufffd\ufffdb=\ufffd\ufffd>\ufffd0\ufffd\u07f4\ufffd\ufffd\ufffdy}\u0138B)H\ufffd[\ufffd\ufffd\ufffd\ufffd\ufffdFs\ufffd\ufffd\ufffdV\ufffd+\ufffd\ufffd\ufffd\u032f+Y(I\ufffd\ufffd\ufffd(\ufffd\ufffd\ufffd\ufffdx&\ufffd\ufffd9JAI\ufffd\ufffd\ufffd'tXm\ufffdy\ufffdG\ufffd=\ufffdX[8\ufffdTK\ufffd)\ufffd2\ufffd<\ufffdTSR\ufffdv\ufffdx\ufffd\ufffdl\u0213GO\ufffd|\ufffdg\ufffd/\ufffd{\ufffd>\ufffd\ufffd\ufffd4\ufffd\ufffd/\ufffdg\ufffdR\ufffd\ufffdF\ufffd\u0236\ufffd\ufffd&\ufffdA\ufffd5\ufffd\ufffd\ufffd2\ufffdu\u042f*B<\ufffdi\ufffd\ufffd\ufffd0\ufffdg\ufffdr+O\ufffd\ufffdA\ufffd\ufffd,0\ufffd\ufffd\ufffd-\ufffdb\ufffdu\ufffdg[\ufffd\~\ufffd-\ufffd\ufffd\ufffd\ufffd4:I>\u5e43A\ufffd\ufffduF\ufffd\u01de\u0467\ufffd\ufffdu\ufffdD\ufffd\ufffd\ufffd)B\ufffd,\ufffd*\ufffd?n\ufffd`	'qQIz\ufffd\ufffd\ufffdK\u0597\ufffd4\ufffd{\ufffd\ufffdB_g\ufffd6\ufffd8\ufffd#\ufffd\u02892.A\ufffd$69\ufffd!\ufffd\u0312\ufffdub1&D\ufffd3Q\ufffdx\ufffd\ufffd"\ufffd>\u024fn\ufffd\ufffd\u03bdx\ufffdVG\ufffd&\ufffd\ufffdT\u06e8\ufffd\ufffd\ufffd\ufffd�)\ufffdsx\ufffdd-5\ufffd\ufffdKx\ufffd\ufffd\ufffd\ufffd\ufffd\u07e3D&\ufffd\ufffd1\ufffd\ufffd\ufffd�\ufffd\ufffd\ufffdj\ufffdd\ufffd\ufffdG
 jJ\ufffd\ufffd|\ufffdJ\ufffd\ufffd{\ufffd\ufffdZ\ufffd\ufffd\ufffd\u07b2\ufffdf6\ufffd/vT\ufffdp\u0304ub\ufffd\ufffd
\ufffd\ufffdP\ufffd\ufffdmBU#g\ufffd\ufffd\ufffdB\ufffdg\u02f7\ufffd)\ufffd\ufffd-*\ufffdE
+ar\ufffd\ufffd\ufffd>\ufffd>\u01b5rn\ufffd[\u026d\ufffdF\ufffd-I\ufffd\ufffd\ufffdBy\u0478P\ufffd=\ufffd\ufffd\u0136K\ufffdUC
w\ufffd\ufffdG\ufffdD\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffd"\ufffd\ufffdvN\ufffd\ufffd.p\ufffd]\ufffd]Q\ufffd\ufffd8u\ufffdY\ufffd\ufffd{\ufffd#q\ufffd\ufffdC\ufffd\ufffdv}sa\ufffd\ufffd\ufffdx_o\ufffd\ufffdy\ufffdiN\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffd
d8a\ufffdw\ufffd2C\ufffdQ\ufffd}V\ufffd8\ufffdUWO\\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffdyk\ufffd@\ufffd\ufffdd\ufffd\ufffd\ufffdc\ufffd\ufffdZ\ufffdt\ufffd\ufffd\ufffd9$\ufffd\ufffdu
+p\ufffd\ufffd-\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffdz(\ufffd=\ufffdf)
+\ufffdv\ufffd\ufffd\ufffd\u011b9\ufffd\ufffd\ufffd\ufffd2\ufffd w	u\ufffd\ufffd\u717c\ufffd\ufffd\u05ea\ufffd\ufffd#\ufffd\ufffd\ufffd\ufffd{P6\ufffd+D\ufffd\ufffdq3HIi\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffdB\ufffdC\ufffd\ufffdb\ufffd!\ufffd\ufffd\ufffdkc5\ufffd&U	):X\ufffd$\u070e\ufffd\ufffd\ufffd[\ufffd\ufffdb\ufffd2\ufffd*@\ufffdPkc\u04d8\ufffdd\ufffdoT\ufffdB_L1Uwi"\ufffd)\ufffd\ufffd=\ufffd2#\ufffd\ufffd\ufffdpI9,\ufffdR\ufffdO>\ufffdT@>\ufffd;\ufffdbn\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffdPuC\ufffd\ufffd\ufffd\ufffdfk\ufffd\ufffd\ufffd^\ufffd^\ufffd\ufffd\\ufffd\ufffdG~\ufffd
 \ufffd\ufffdo\ufffdL\ufffdRc\ufffdHq\u072e=-8^5O\u0144\ufffdy*9\ufffd\ufffd:-\\ufffdg8:T<\ufffd\ufffd?*\ufffd\ufffd\ufffd\ufffdC;\ufffd\ufffd[\ufffd\ufffd\ufffdy\ufffdX\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffdI\ufffd;\ufffd\ufffdlRL\u07ed\ufffd$D\ufffd\ufffdvY\ufffdTQ6\ufffdDy\ufffd\ufffdVm\ufffd\ufffdfy%/sIs\ufffd\ufffdmXP1\ufffdL\u057c\u022d\ufffd\ufffd\ufffd\ufffdvow)\ufffdQB\ufffdb\ufffd\ufffd\ufffd\ufffd_L\ufffdV\ufffdwu\ufffdp\ufffd\ufffd\ufffd\ufffde\u0117\ufffd\ufffd\ufffdO*\ufffd\ufffd|\ufffd+\ufffd]\ufffd(uH\ufffd\u05f04\ufffdW\ufffdU\ufffd\ufffd.\ufffd{ \ufffd4\ufffd\\ufffdm.Q\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffd\ufffdR~MAi\ufffd\ufffd\ufffdRz+%\ufffdB\ufffd\ufffd\ufffd\ufffdK\ufffd\ufffdz\ufffd?'\ufffd{\ufffd\ufffd\ufffd\ufffdk\ufffd\u0489\ufffda\ufffd\ufffda\ufffd{\ufffd\ufffd\ufffdH]\ufffd\ufffdsX}d\ufffd\ufffd\ufffd\ufffda~\ufffd3\ufffd\ufffd_\ufffdau\ufffd\ufffd\ufffdQz\ufffd	\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdVM\\u0135v5I0\ufffdL\ufffdM\ufffd)\ufffd\u01c4\ufffdp\ufffd\ufffd\ufffd1\ufffd\ufffd:5\ufffd
 \ufffd,\ufffd&\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd%\ufffd\ufffd\ufffd!$}o\ufffd\ufffd\ufffdc\ufffd\ufffd\u07a4\ufffdA\ufffd]R^x\ufffd\ufffd\ufffdT\u25ecM&/B\ufffd:D\ufffdwA\ufffd\ufffd2\ufffd4\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffdc\ufffdd&g]5\ufffdb\ufffd\ufffd\ufffd4\ufffd\ufffd\ufffda?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdi\ufffd\u01d0\ufffd\ufffd  \ufffd\ufffd\u0108\ufffd\ufffd.OA
6\ufffdvfv\ufffds\ufffdd\ufffd\ufffd(5yT\ufffd\ufffdH\ufffd\ufffd\ufffd/P\ufffd\ufffd=\ufffd(\ufffda\ufffd\ufffd;zUs\ufffd\ufffdb\ufffdW\ufffd\ufffdx\ufffdDa\ufffd)E\ufffd\u02bc\ufffd	$\ufffdsg\ufffdPJ\ufffdr\ufffde\ufffdY\ufffd3\ufffdw\ufffd\ufffd`\ufffdc\ufffd\ufffdF\ufffdo\ufffd0|U[j5k\ufffd\ufffd.\ufffd5\ufffdJ\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffd\ufffde\ufffdT\ufffd\ufffdo\ufffdr	\ufffd\ufffdÈ´\ufffd\ufffd}I	l\ufffdp\ufffdjC\ufffd\ufffd\ufffd8c\ufffd\ufffd\ufffd5\ufffdJ=g\ufffd%U\ufffd\ufffdo\ufffd|L5\ufffd\ufffd8E"
+\u0650\ufffd\ufffd\ufffd[Ak]\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\u0346\ufffdVB\ufffdM\ufffd"{\ufffdN\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdih\u0426@\ufffdY?\ufffd\ufffd6\ufffd\ufffd^\u07ebZW\u066f\ufffd]\u0630\ufffd\ufffd\ufffdc\u060bh\ufffdKS\u01c8:>\ufffdO
\u0272\ufffd\ufffd\ufffd.\ufffd\ufffd\ufffd\u0770\ufffd\ufffdQ\ufffd{5mm<\u0677?^\ufffdv"\ufffd\ufffd}\ufffd\u044aw\ufffd\ufffd9\ufffd\ufffdO\ufffd\ufffd&\ufffdv\ufffd\ufffdX\ufffd7\ufffdkm[	\ufffd,70n\u03927|\ufffd\ufffde\ufffd\ufffdP\ufffd\ufffd\I;<\ufffd\ufffdu\ufffd^`u\ufffd!\ufffd\ufffd$P\ufffd\ufffd\ufffd\ufffdB
+ET9\ufffd\ufffd\u0672F\ufffd\ufffdW\ufffd\ufffdc\ufffd\ufffd\ufffd\ufffdm$\ufffd\ufffd="G
+}K\ufffde\ufffd\ufffd6\ufffd~\u0594G_\ufffd\ufffd\ufffdM\ufffdD\u053f\ufffds`\ufffd g\ufffd]\ufffdv\ufffdp-9\ufffd\N\ufffdd{:\ufffd:\ufffdgv\ufffdH\ufffd_3fC;}\ufffd\u0193P\ufffd\ufffd\ufffdN\ufffd\ufffd\ufffdp\ufffdH\ufffd\ufffd\ufffdd\ufffdU9u\ufffd;\ufffd\ufffd\ufffd9$8w\ufffd\ufffd\ufffd\ufffd\ufffd3\ufffdr\ufffd#\ufffdA\ufffdF\ufffdiD1\ufffdn\ufffd\ufffd\ufffd\ufffd\ufffd-}\ufffd\ufffdt\ufffde\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffdH\ufffd!5$\ufffd\ufffd,I\ufffdQ:\ufffd\u0216R\ufffd\ufffd\ufffd1\ufffd3\ufffd\ufffd<\ufffd7\ufffd\ufffd\ufffdj\ufffd1\ufffd[\ufffd\u040aT\ufffd\ufffdm\ufffd\ufffd\ufffdWwzU\ufffdx\ufffd\ufffd|\ufffd\ufffd\ufffd\ufffd\u057e+\u0584{\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\ufffd>\ufffd\ufffdp\ufffd\ufffd\ufffd:\u02a4\ufffdJRqY\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffd`\u01ef\ufffd<\ufffd~\ufffdj\ufffd\ufffd!m\ufffdr.\ufffdB\ufffd+\ufffd\ufffd'\ufffd\ufffd\ufffdOyY+\ufffd\ufffdfN*\u017ct
\ufffdW\ufffd$\ufffd\ufffdW\\ufffd2\ufffd\ufffd\ufffd\ufffdM_\ufffdc[\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdjj\ufffd%WuU{{\ufffd,_\ufffd\ufffdp\ufffdW\ufffd\ufffdn%}P\ufffdI^\ufffdW\ufffd|n�;c!\ufffdp\ufffd\ufffd\ufffdu\ufffdc\u02a8\ufffdN!k#\ufffd\ufffd\ufffd)k\ufffd\ufffdsd\ufffd\ufffd5n\ufffd�\ufffd6Q{H10\ufffd\ufffd\ufffdU\ufffd
+\ufffd\ufffd\ufffd-\ufffd"{\u2807TZG \ufffdR\ufffd,\ufffd\ufffd\u0247j\u08f6Zw8j	ICF\ufffd\ufffd\ufffd:\ufffdb[	\ufffd\+\ufffd?\ufffd
+\ufffd\ufffd\ufffdoA
n'a
+
+\ufffd\ufffdO\ufffdj0\ufffd\ufffd\ufffd`\ufffd%\ufffd\ufffd|\ufffd^\ufffd/si\ufffd_\ufffdX\u01e3\ufffdLqi\ufffdw]\ufffdI\ufffd\u03ad\ufffdD"J\ufffd\ufffd\ufffd!y\ufffd!\ufffd\u0536\ufffdn\ufffd\ufffd0\ufffdR\ufffd	z\ufffdWC\ufffd\ufffdc\ufffdc\ufffdh\ufffd\ufffd\ufffd\u016bK\ufffd_R
[\ufffd\ufffd*)!
OSo\ufffd\ufffdu\ufffd\ufffd\ufffdO\u0577\ufffd\u070cW\ufffd\ufffd\ufffdze\ufffdW\ufffdC\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\u03dd\ufffdL\ufffd\ufffd\ufffd/\ufffdQB\ufffdo\ufffd_\ufffd\ufffdk\ufffd/cg\ufffd\ufffd\ufffd&MV?\ufffd\ufffd\u05ab5z\ufffd\ufffd !g\ufffd\ufffd\ufffd\ufffd"?w\ufffd\ufffdP\u035a\ufffdI\ufffdQ"\ufffd\ufffd\ufffd\ufffdP\ufffdAdtE)q4\ufffd\ufffdj\ufffd\ufffd\ufffdG\ufffds\ufffd\ufffd\ufffdn\ufffd{"\ufffd\ufffd\ufffd\ufffd}e\ufffd\ufffdUM\ufffdrk\ufffd\ufffdzvi89C}\ufffd\ufffd\ufffdX\ufffdLB1W\ufffd".\ua55d^M\ufffd\ufffd\ufffd\ufffd\ufffdt?WK\ufffdL\ufffdw\ufffdDP]t\ufffdU\ufffd\u63ca1r\ufffdJ\ufffd\ufffd\ufffd\u0578K\ufffd\ufffdV\ufffd\ufffd\ufffd\ufffdGM;ph\ufffd\u0577m\ufffd \ufffdv>\ufffd\ufffd-wg\ufffd\ufffd\ufffd\ufffdFN\ufffd\ufffd\ufffdcI\ufffdP\ufffd#q\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffd;\ufffdN\ufffd\u0676\ufffd\ufffdA\ufffd)\ufffd\ufffd\ufffdH~\ufffd7i\ufffd t\ufffdhl\ufffd~\ufffd\ufffd~\u01f3\ufffdY\ufffd
C\ufffd\ufffd\ufffd\ufffdx\ufffd2>*c&\ufffdm\ufffdb\ufffd\ufffd\ufffd\ufffd{9f\ufffd1X*\ufffdL\ufffd\ufffd	\ufffd#>\ufffd\ufffd\ufffd
+
V@\ufffd\ufffd\ufffdg\u84bc]7n249=M\ufffd\ufffd\ufffd\ufffdK%
\ufffd;\ufffd\ufffd,\ufffd\ufffd\ufffd\ufffdF\ufffd\j\ufffd\ufffd1\ufffd\ufffdkl\ufffdZ\ufffdi\ufffd\ufffd\ufffd\u060a\ufffd\ufffd\ufffd\ufffd\ufffd\u0390\ufffd.|Q\ufffd\ufffd9\ufffd\ufffd\u0430\ufffd$_.!\ufffd\ufffd;\ufffd\u033f\ufffdl\ufffd\ufffd\ufffdE\ufffd,\ufffd\ufffd\ufffd\ufffd\u0265Di\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd}D\ufffd\ufffd3^\ufffda`Y5\ufffdg{J=m\ufffd\ufffd\u0273\ufffd\ufffd\ufffdy\ufffd3\ufffd\ufffd\ufffdC\ufffdM'\ufffdjM\ufffd-i\ufffd\u0426\ufffdm\ufffd\ufffd\ufffdn5?	\ufffdSJ\ufffdE+U~ \ufffd;\ufffd\ufffd\ufffd\ufffdq.t\ufffdXd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd~p*Q\ufffdeS\ufffd\ufffd%\ufffd.\ufffd\ufffd\u040b\ufffd"\u01b0\ufffd\ufffdBs\ufffd\ufffd\ufffdZ\ufffd6-\ufffd\ufffd\ufffd\ufffd\ufffd6[\d;\ufffd^z4\ufffd`;64\u85f8\ufffd\ufffd\ufffd\ufffd\u0371w\ufffd\ufffd\ufffd;\ufffd\ufffd\ufffd\ufffd|\ufffd+&\ufffdA\ufffdf\ufffdLU\ufffd3\ufffd\ufffd\ufffdX\ufffdT\ufffd\ufffdm\ufffd\ufffd\ufffd)l\ufffdF\ufffd'l
\ufffdV\ufffd\ufffd\u027a\ufffdgcG\ufffdOb\ufffdb\u025c9\ufffd;v\\ufffdC\ufffd\ufffdL,\ufffd>B?\ufffdKGC\ufffd\ufffde"\ufffdz-@\ufffd\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd</\ufffds\ufffd=/\ufffd\u144dY\ufffd\ufffd\ufffd{\ufffd\ufffdP\ufffd\ufffdw\L\ufffd1A\ufffd|U{\ufffd_\ufffd\ufffd\ufffd\ufffd"\u0489w\ufffd+Gm\ufffd
\ufffd$\ufffd#\ufffdn\ufffd\ufffdo\ufffd\ufffd\ufffdx\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffd\ufffd}M\ufffd9\ufffdMb\u03a5\ufffd_@T\u0732\ufffd'1 \ufffd,\ufffdq\ufffd\ufffd$;\ufffd\ufffd!\ufffd\ud5c1h1kb\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdBo
+\ufffd\\ufffd\ufffdw\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffduY/|\u03d5d<w\ufffd\ufffd\u03a4c\ufffd~\u03ce\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd�\ufffd#d\ufffd\ufffdg3\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd\ufffdg\ufffd�\ufffd xT2\ufffd\ufffd\u0235\ufffd\ufffd6s3\ufffdi75\ufffd\ufffd\u01bb\ufffdZ\ufffdE\1\ufffd\\ufffd\u027a\ufffdW\ufffdA' \u05f2\ufffd\ufffd M	}?;\u0282\ufffd8|R\ufffd0S\ufffd#\u2763\ufffd\ufffd\ufffdC\u06ffU\ufffd\ufffdb0\ufffd\ufffd\ufffdL7\u05bd`\ufffd\ufffd\ufffdhcEk\ufffdT\\ufffdm\ufffd+	6\ufffd&\ufffd=\ufffd\ufffd\ufffd\ufffdB\ufffd9)\ufffd\ufffd\uaccc\ufffd\ufffd\ufffd\ufffd
\\ufffd@\ufffd^jk\ufffd\ufffda\ufffd\u019a\ufffd\ufffdPh\ufffd<\ufffd\ufffd=T\ufffd\ufffd6\ufffdK^MK\ufffd\u034b=\ufffd\u074a\ufffd$\ufffdQ\ufffd\ufffd\ufffd\ufffd-\ufffdU\ufffd&\ufffd>ILp<\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd'\ufffd\ufffd\u0489\ufffd\ufffd\ufffd\ufffd\ufffd$>\ufffd\ufffd8#\ufffdg\ufffdL\ufffd2\ufffdm\ufffd	\ufffd\ufffdc\ufffd\ufffd\ufffd\ufffd\ufffd1
\ufffd\ufffdc\ufffd\ufffd\ufffdF\ufffdw)\ufffdP\ufffd\ufffd+\ufffdr\ufffdkC
q\ufffdp/\ufffd\ufffdu8#\ufffd!\ufffd*g\ufffd\ufffd�\ufffdPa\ufffd`v\ufffdu\ufffd\ufffd@\ufffd\ufffdo\ufffdH\ufffd`"\u017d\ufffd\ufffd:\ufffdz\ufffd\ufffd\ufffd_\ufffd\ufffdQ<,D\ufffd>'\u04c5\ufffd\ufffdWP\ufffd\ufffd\ufffd .\ufffd\ufffd\ufffd\ufffd`\ufffdx\ufffdW\ufffd\ufffd3\ufffd|!6\ufffd\ufffd	\ufffd
+\ufffd5\ufffd\ufffd\ufffdEl\ufffd["\ufffd,0\ufffd	e\ufffd\ufffd\ufffd[Oz\ufffd\ufffd0~l\ufffdU\ufffdO\ufffd\ufffd+\ufffd\ufffd\ufffd\ufffd&x\ufffd\ufffdkP\ufffd\ufffdc|u\ufffd\ufffd$k\ufffd.\ufffd?\ufffd{Qp""k\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdr\ufffd6\ufffd\ufffdisV\ufffda\ufffd\ufffd\ufffd=~\ufffd@\ufffdW\ufffd_\ufffd
+.<\ufffd7\ufffd
+\ufffd\ufffd2\ufffd#h?c~\ufffdm'r\ufffd\ufffdE\ufffd_\ufffdxs\ufffd\ufffd6\ufffd\ufffd\ufffd\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdG\ufffd+\ufffd\ufffd\ufffdK1\ufffd\ufffd4\ufffd\ufffd\ufffdL^kUp\ufffd^^\ufffd\ufffd_\ufffd\ufffdm\ufffdS^d\ufffd\u0428\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd}\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd$:\u03c4!E\ufffd\ufffd[\ufffdb\ufffdJx&\ufffdn\ufffd t\ufffd(\ufffd\ufffdm\ufffd;Z\ufffd\ufffds\ufffdF5u\ufffdq\ufffdX\ufffd.\ufffd\u0542\ufffdBqKP\ufffd\ufffd\ufffd *\ufffd\ufffd\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd%{\ufffd\u0653{\ufffd'\ufffd\ufffdf';\ufffd,TT,\ufffdb\ufffd\ufffd\ufffdh\ufffdUq\ufffd2Z\ufffd\ufffd\ufffd3\ufffd\ufffd\ufffd;\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffdT9\ufffdvw\ufffd\ufffdR\ufffdR;GD\ufffd
+K\ufffd*\ufffd\ufffd/@hUv\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$\ufffdj\ufffd!\ufffd@\ufffd
\ufffdvy\u05d1m\ufffd\ufffd\ufffd,W\ufffd|-\u0362	\ufffd^\ufffd
\ufffd~\ufffdD\ufffd_\ufffd\ufffd\U00106b4d\ufffd"\ufffd\ufffd\u0109\ufffd\ufffd\ufffd\ufffd#c\ufffd\u7998\ufffd*\ufffdX/\ufffd\ufffd\u03dc\ufffde>\ufffd|\ufffdXH\ufffd\ufffd;\ufffd:\ufffd\ufffd)\ufffd\ufffd\ufffdd9g\u0196\ufffd4\ufffdaB\ufffd\ufffd\ufffd\ufffdQ4\ufffdE\ufffd\ufffdw\ufffd,C
+\u06efB\ufffdU\ufffd#\ufffd>\ufffdSV\ufffd$L\ufffd-\ufffd\ufffd5g\ufffdV	\u03ef*\ufffdB\ufffd\ufffd\ufffd\ufffd#\ufffd\ufffd}\ufffdnp\ufffd�\ufffdtd\ufffd\ufffd\ufffd\ufffd\ufffdU\ufffd$D\ufffdb&$^\ufffd\^\ufffd&Z"/\u02fa+\ufffd-}\ufffd\ufffd%\ufffdZ\ufffd\ufffd\ufffd:}\ufffd\ufffd9\ufffd\ufffd\ufffdA\ufffd\ufffdYu\ufffd\ufffd	\ufffd\ufffdrT\ufffdlP0\ufffd"\ufffd\ufffd\ufffd~!	\ufffd\u035a*@5K\ufffd?\ufffd\u07ebZ\ufffd-\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd=j\ufffd>\ufffd\ufffd\u0708\ufffd[\ufffd\ufffdO?)\ufffda5\ufffd
+\ufffd\ufffd\ufffd\ufffd\ufffd?\ufffd\ufffdW\ufffd\ufffd\ufffdUs\ufffd\ufffd\ufffd\ufffdy\ufffd5^(ge\ufffd${C\ufffd\ufffd\ufffd\ufffdm>\ufffd	"\ufffd\ufffd\ufffdG\ufffd\u0563+\ufffd$\ufffd\u8e3f\ufffd\ufffd\u03eb&\ufffd\ufffd
Xw\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd8?\ufffd\ufffdg\ufffd\ufffd,'\u014d\ufffd=\ufffd"\ufffd\ufffd\ufffd\ufffd/x\ufffd\ufffd\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffdM)\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdEF\ufffd\ufffdq\ufffdrf\ufffd
C\u012fQ9ZY\ufffd$r!\ufffd\ufffd\ufffd6m<YZ\u0421.\ufffd<\ufffd\ufffdV^\ufffdz{U\ufffdS=\ufffdP
+k\ufffdX%3\ufffdx\ufffd\ufffdfj\ufffd\ufffdn%^\ufffd\ufffd\ufffd\ufffd\ufffdi\U00034d7b\ufffd\ufffd\ufffds\ufffd\ufffd\ufffd3\ufffd0\ufffd\ufffd\ufffdq\ufffdh\ufffd$\ufffd\ufffd`k\u072f\ufffdD&\ufffd\ufffd!\ufffdM\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffdW\ufffd}\ud6cc1r\ufffd\ufffd\ufffd\ufffd=2N\ufffd\ufffdSd\ufffdk\ufffdb\ufffd\ufffd\\ufffd\ufffd\u0140\ufffdp\ufffd\ufffd\ufffdd\ufffdW}^\ufffd'\ufffdS^}\ufffd+P\ufffd0iC\ufffd\ufffd1\ufffdR\ufffd 0hDz[P\ufffd\ufffd\ufffd&!\ufffd\ufffdv@\ufffdB\ufffd\ufffd]P]V< \ufffdS\u0712G\ufffdL\ufffdO\ufffdNgK]+&\ufffd\ufffd-A
+\ufffd2\ufffd\ufffd\ufffd#\ufffdsL4\ufffdj\ufffd\ufffd&\ufffdD\ufffd\ufffd\ufffdi\ufffdb&,\ufffdA\ufffd\ufffdMS\ufffd\ufffd\ufffdU\ufffdD\ufffd\ufffd9\ufffd\ufffd\ufffdy\ufffd
+v\ufffd\ufffd\ufffd98\ufffd\ufffd\ufffd\ufffd\ufffdj\ufffdc7MI\ufffd~\ufffd(\ufffdsL#\ufffd}\ufffd3\ufffd\ufffd\ufffd(M\ufffd^N\ufffdi\ufffdE\ufffdK\ufffdE8\ufffdmi\ufffd	u\ufffdzI\ufffd$N\ufffdr|}*\ufffd\ufffd+\ufffd'\ufffd4\ufffd\ufffdw\ufffd\ufffd\ufffd{\ufffdy%\ufffd\ufffdF $\ufffd\ufffd8\ufffd\ufffd@\ufffdN\ufffdz\ufffd\ufffd^G.g\ufffd\ufffd\ufffd\ufffd-1Vfk\ufffd)\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffdu\ufffd6K"\ufffd\ufffd\ufffdK\ufffd\ufffd\ufffd1\ufffdp\ufffd\ufffd\u039b\ufffdP\ufffd\ufffd8\ufffd\ufffd\ufffd\ufffdr\ufffd\ufffd\ufffd>\ufffd)\ufffd4\ufffd
\ufffd\ufffdV\ufffd9\ufffdk\ufffdJ\ufffd$#\ufffd\ufffdF\u044c\ufffdX\ufffd\ufffd\u0665\ufffdC\ufffd\ufffdp\ufffd[\ufffd\ufffdg\u0327)C\ufffd\ufffd\ufffdS\ufffd;rFP#\ufffdI\ufffdm\ufffdK\ufffdG<\ufffd\ufffdh/\ufffd\ufffdU\ufffd-,C\ufffd\ufffdO\ufffdkOK\ufffdYY\ufffd;\ufffdMH-\ufffdt\ufffd\ufffd%\ufffd^N\ufffd\ufffd\u03be\ufffdB\ufffd\ufffd\ufffd7"
+\ufffd\ufffd\ufffdO\ufffdaj\ufffd\ufffdX\ufffd_84\ufffdV(N\ufffd\ufffd-{D)\ufffd\ufffdF\ufffd0\ufffd$\ufffd!\ufffdo\ufffdJ\ufffd\ufffdd\ufffdv/_\ufffd\ufffd(\ufffd\u01c0\ufffd\ufffdU\ufffdH8\ufffdB\ufffdc\ufffd1\ufffd\ufffd\ufffd\ufffdf\ufffdb5u\ufffd\ufffd&\ufffd*\ufffd\u04bd\ufffdn\ufffd2s\ufffd\ufffd\ufffdG40:\ufffd\=Y2\ufffd\u07ef	\ufffd$bi\ufffd8\u4eb5M\ufffd$\u0499:ut\ufffdN\ufffd)\ufffd\ufffdEh\ufffd\ufffdDh\ufffd\ufffdd\ufffdj\ufffd21|\ufffd*T\ufffd\ufffdV\ufffd\u02f0\ufffd\ufffd\ufffdT\ufffd5\u022eM7-\ufffd^\ufffd\ufffdS\ufffd\ufffd\ufffd84Te\ufffd\ufffdhR\u04a8j\ufffd[\ufffdU\ufffdG\ufffd\ufffdU\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffdK{\ufffdNh6v\ufffdg\u05a8\ufffd+\ufffd\ufffdG?\ufffd\ufffd\ufffd`
l\u0754$Rq-\ufffd.\u07a62\ufffd\ufffdS\ufffde\ufffd8pS\u0556\ufffdk!\ufffdX\ufffd\ufffdC\ufffd\\ufffdz0\ufffd0	nlh\ufffd\ufffdj\ufffd<~I\ufffd\ufffd\ufffd\ufffd\ufffd,K\ufffd\ufffd\ufffdr\ufffdL\ufffd)\ufffdIM\ufffd\ufffd\ufffd\ufffd9M\ufffd_\ufffd\ufffd\ufffdc+"v\u049c\u0764\ufffdL\ufffd\ufffd\ufffd$>\u027a\ufffd\ufffdz\ufffd\ufffd\ufffdj>>\ufffd\ufffdX\ufffd9,\ufffdZL-j\ufffd\ufffdIb\ufffdk\ufffd\ufffd\u02098\ufffd\u02da?v\ufffdt\ufffd\ufffd\ufffd\ufffd\ufffdx\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdP\ufffdIO}\ufffd_ay@\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd|Ve\ufffd6\ufffd\ufffd\ufffd\ufffd\ufffdubd/e\ufffd3<\u05ad\ufffdz\ufffdt\ufffd\ufffde\ufffda\ufffd\ufffd'\ufffdc\ufffdLaM
+\ufffdlz&,f^\ufffd_!\ufffd\ufffd?\ufffdl\ufffd\ufffd\ufffd\ufffd2x2\ufffdX\ufffdy\ufffd\ufffd\ufffd\u0144\ufffd3D\ufffd\ufffd\ufffd\ufffd)\ufffd\?\ufffdy\ufffde\ufffd~\ufffd\ufffd4\ufffd\ufffdO\ufffd+9$\ufffd
\ufffd
+\ufffd\ufffd\ufffdE\ufffdV\ufffdD<\ufffdO0\ufffdVbj&\ufffd\ufffdmLB\ufffd2Z\u0708\ufffdb9\ufffd\ufffdU\ufffd\ufffd;n\ufffd\ufffd\ufffd6L0	\ufffd+\ufffd\ufffdo\u02c7Cr\ufffdE.~\ufffd>T\ufffdS\u0613\ufffd7X\ufffd\ufffd\ufffd\ufffd?MM\ufffd!\ufffd\ufffd\ufffd\u053cu\ufffdO\ufffd\ufffdt\ufffd\ufffd\ufffd\ufffdPCbt;\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd\u07b0\ufffd\ufffda\ufffd\ufffd@gW\ufffd\ufffd#\ufffd@\ue7d6\ufffd\ufffd4c\ufffd9.D\ufffd\ufffd\ufffdo\ufffdz2>M\ufffd5\ufffd\ufffdi\ufffd~\ufffdu0\ufffd\ufffdq\ufffds\ufffdw\uebb4Q\ufffd9\ufffd\u01f8Lt\ufffd\ufffd\uc09f\ufffdMz)>\ufffd\ufffd\ufffdk\u025d\ufffd\ufffd\ufffdI\ufffd;\ufffd\ufffd\ufffdio\ufffd"\ufffd\ufffd\ufffdU)\ufffd\ufffd]$Y\ufffd\ufffd\ufffdL
>\ufffd$\ufffd\ufffd\ufffd\ufffd$T\ufffd\ufffd\ufffd\ufffd:gUo$\ufffd\ufffd\ufffdUK\ufffd\ufffd\ufffd,\ufffdC\ufffd`sCMAJM�\ufffd\ufffdK\ufffd\ufffdC(\ufffd\ufffdg]\ufffd\ufffd\ufffd\u066e9\ufffds\ufffdU\ufffdG\ufffd0?\ufffd\ufffd\ufffd\ufffdL\ufffd5\ufffd\ufffd\ufffd\ufffdQM%\ufffd\ufffd0O\ufffdl\ufffd\ufffd5&\ufffd\ufffd\ufffd`\ufffd\u01911,\ufffd\ufffdx\ufffd'\ufffd\ufffd\ufffd{\ufffd\ufffdk+\ufffdmY\ufffd}\ufffd\ufffd\ufffd\ufffd-J\ufffds#\\ufffd\ufffdd\ufffd\ufffd\ufffd:\ufffdi/\ufffdN\ufffdK\ufffd\ufffd\ufffd\ufffd\ufffd\8\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffdstQ#\ufffd\ufffd-\ufffdND\ufffd)\ufffd.s*\ufffdZ\ufffd\ufffd\ufffdy\ufffdm\ufffdn\ufffdf\ufffd\ufffd\ufffd\ufffd\\ufffd1l\ufffd\ufffd\ufffd\ufffd{\ufffd\ufffd(E\ufffd=\ufffdVGW\ufffd\ufffd9\ufffd\ufffds\ufffd:\ufffd\ufffd?\ufffd\ufffd\ufffdw\ufffd\ufffd\ufffd\u01df\ufffdQ\ufffdZ\ufffdsC\ufffd\ufffd6\ufffd\ufffdA\ufffd1\ufffd\ufffd\ufffd\u0183\ufffd\ufffd6K\ufffd@\ufffd8\ufffd\ufffdO\ufffdUY\ufffd^\ufffd\ufffd`\ufffd\ufffd
 \ufffd7\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdj6\ufffd@\ufffd9?,y\ufffd\ufffd\ufffd\ufffdt4&\ufffd}"\ufffdT\ufffd\ufffd-
+\ufffd\Y&k\ufffd\ufffd\ufffdV\ufffd\ufffdx\ufffd\ub1633\ufffd\ufffd9\ufffd\ufffd1\u0675qQ\ufffd=\ufffdb\ufffdeMq\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd`/n\u0146|\ufffd\ufffd\ufffd2\ufffd\ufffd\u034cJkz\ufffdD\ufffdm\u036b\ufffdIR4\ufffd\~5Nl\ufffd\ufffd\u0585\ufffd\ufffd\ufffdK\u0241Z]T\ufffdC\ufffd3\ufffdl\ufffd\u0305\ufffd\ufffdD\ufffd3jSS\ufffd)\ufffdt\ufffd\ufffdWw$IX\ufffd[\ufffdw\ufffdV\ufffd\ufffd
+WT\ufffd\ufffd\ufffdU\ufffdw^P\ufffdeU\ufffd\ufffd\ufffd\ufffdh\ufffdWE\ufffd^\u0613~W\ufffdc\ufffdh\ufffd\ufffd\ufffds\ufffds\ufffd\ufffdI\ufffd\ufffdg\ufffd\ufffd\ufffd\ufffd\ufffd`\ufffd\ufffdw\ufffd\ufffdg\ufffds
(\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdmr\ufffd\ufffd\ufffd\ufffd\ufffd]\ufffd\ufffd\ufffdB`7Jf\ufffdA\ufffd\ufffd\ufffd\ufffdaA\ufffd3\u0193\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd?{\ufffdO[\ufffd?\ufffdx\ufffdj\ufffd/\ufffd\ufffd\ufffd\ufffdZ\ufffd*7\ufffde\ufffdx\ufffd\ufffdX\ufffdz\ufffd
\u0386\ufffd\ufffd})\ufffd\ufffdC\ufffd\ufffd\ufffd?`\ufffd\ufffdK\ufffdc\ufffdM\ufffd\ufffd\ufffd\ufffd\u054c\ufffd\ufffd&)\ufffd\ufffd\ufffd\ufffdY\ufffd5\ufffd\ufffd\ufffd\ufffdJ]q':]$\ufffd\u061e\ufffd]Yvx\ufffd(\ufffd\ufffd\ufffd\ufffd\ufffd\u0131\ufffd\ufffdH1\ufffd\ufffde\ufffdU\ufffd\ufffd\ufffd\ufffd>\ufffd_0\ufffdb\ufffd?*\U00078a0e\ufffdb\ufffd\ufffd\ufffd\ufffd�\u060c\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd\ufffd\ufffd;W\ufffdxm]|N\ufffd7U\ufffd\ufffd13*\ufffd;\ufffd\ufffd.\ufffd=\ufffd\ufffd>\ufffd\ufffd\ufffdS\ufffd�j)\ufffd\ufffdCM\ufffd\ufffd>\ufffd\ufffd.\ufffd\ufffde\ufffdI\ufffd\ufffd\ufffd\ufffd1\ufffd\ufffd\ufffd/\ufffdQ\ufffdv\ufffd\u041d\ufffd\ufffd\ufffd6T\ufffdkk+\ufffd\u019cn\\\ufffdF\ufffdF\ufffd\ufffdV#\ufffd\ufffd\ufffdXd\ufffd\ufffd\ufffde\ufffd&~\ufffdWE\ufffd\ufffd7\ufffd"\ufffdbj\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffd^I@\ufffdj@\ufffdbQ\ufffdW\ufffd\ufffdk\ufffd\ufffd8\ufffd\ufffd\ufffdw\ufffd\ufffd_\ufffdD\ufffd\ufffd^\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd
x\ufffdZ\ufffdKA\ufffd_`\ufffdT}\ufffd]
+x\ufffd}\ufffd\u0401\ufffdM0S\ufffd,r\ufffd\ufffd\ufffd\ufffdV+	K\ufffd\ufffdO&\ufffd\u0188\ufffd`\ufffd;\ufffdE{irf0F\ufffd]\ufffd\ufffd w86f\ufffd\ufffd\ufffd\ufffd\ufffdfm_8\ufffd\ufffd\ufffdc3\ufffd\ufffd\ufffd\ufffdV\ufffd<)\ufffdr1\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffd +h\ufffd\ufffds|p\ufffd\ufffd!Q\ufffd\ufffdP'\ufffd\u0542\ufffd\ufffd\u029b\ufffd\ufffd\ufffd\ufffd2\ufffdr\ufffd\u04e4e\ufffd\ufffdj4Y\ufffd
r\ufffd\ufffd\ufffd,
\ufffdr\ufffd?4\ufffd! U\ufffd\ufffdq\ufffd]f\ufffd(\ufffd\ufffd*&umM+\ufffd;\ufffd1\ufffd
+-\ufffd\ufffd\ufffdc\ufffd8\ufffdC\ufffd\ufffd\ufffdj\ufffdL=L\ufffd\ufffd1\ufffdTDJ\ufffd\ufffd\ufffd7\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd\ufffd)BH\ufffd*\ufffdc\ufffdHY}~\ufffdxI,{\ufffd\ufffd7\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdjW\ufffd\u07a7\ufffd\u0287\ufffd\ufffdh\ufffdg\ufffd_\ufffd\ufffd\ufffdYov\ufffdMKi\ufffd\ufffdN>\ufffd\ufffd\ufffdQ\ufffd\ufffdR\ufffd\ufffd\ufffd\u01e7}\ufffd\ufffdA\ufffd\ufffdQ\ufffdj^\ufffd\ufffdG\ufffds\ufffd\ufffdyJG"\ufffd?txt,L\ufffd\ufffd>\ufffd\u058dp\ufffd\ufffd_\ufffd\ufffd>\ufffdPo$\ufffd\ufffd^<\ufffd%}\ufffd\ufffd\ufffdK\ufffdD\ufffd\ufffdS4\ufffd
+\ufffd*S\ufffd<\u0716\ufffdy\ufffdd;\ufffd\ufffd\ufffd�IJ\ufffd\ufffd~J\ufffdM\ufffdn>\ufffd\ufffd\u0238cI6\ufffd\ufffdu\ufffd\ufffd\ufffd\u0256\u0698\ufffd\ufffd\u4a4ai77\ufffd_\ufffd5W\ufffd2'	9\ufffd\ufffdt\ufffd^}/\ufffd\ufffd8%wd\ufffd\ufffd\ufffd0k\ufffd\ufffd)\ufffd\ufffd\u0366\ufffdF9\ufffd\ufffd\ufffd\ufffdk\ufffd\ufffd\ufffd\ufffdih\ufffd\ufffd3\ufffdSh\ufffd\ufffdPB\ufffdU\ufffdLz\ufffd\ufffds\ufffd\ufffd\ufffd'0\ufffd$Y\ufffd/L3\ufffd\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffdl\ufffd\ufffd\ufffd|\ufffd\ufffdf\ufffd\u026a\AW#\ufffdsi\ufffd\ufffdS\ufffd-\ufffdO^\ufffdI\ufffd\ufffd+\ufffd3\ufffd\ufffd6\ufffd\ufffd\ufffdxas\ufffd\ufffd \ufffd\ufffd\ufffd@M\ufffd\ufffd
+\ufffdAh\ufffd\ufffdm\ufffd4\ufffd5V\ufffd-\ufffd\ufffd'\u0475\ufffd1\ufffd\ufffd\ufffdS+\ufffd\ufffd~*\ufffd\ufffd%~k\ufffd\ufffd\ufffd\u02dd\ufffd\ufffd\u0289l
\ufffd*\ufffd
+\ufffdl\u0643\ufffd=\ufffd3\ufffd\ufffd\ufffd_2~\ufffd\ufffd\ufffdOgP\ufffd\ufffds
+\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd[\ufffda\ufffd\u06d2{<\u0425\ufffd\ufffdj\ufffdA	{! \u07f2\u06d3\ufffd\ufffd\ufffd;O'\ufffd\ufffd9+wEH\ufffdE\ufffd\ufffd\ufffd\ufffd\ufffd&\ufffdJ\ufffd\ufffdV\ufffd?f\ufffdi\u04fa j0\ufffd5\u7036bhW\ufffdZx\ufffdo=\ufffd\ufffd\u01ba0\ufffd\ufffd\ufffdz\ufffd\ufffd\ufffdhK5\ufffdm\ufffd\ufffd\ufffdo\ufffd\ufffdv(Y\ufffdOu\ufffd\ufffd\ufffdt\ufffd;\ufffd\ufffd\ufffde=\ufffd\ufffdR\ufffd*\ufffd\ufffdyMV\ufffdn\ufffd,\ufffd$v:\ufffd\ufffdQ\ufffd\u06b3E\ufffd\ufffd.\ufffdy\ufffdVl\ufffd;\ufffd\ufffdsvn\ufffd\ufffd,\ufffd\ufffdWi.[\ufffd\ufffd\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd\ufffd\ufffd34S\ufffd\ufffdD_!\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffdF\ufffd>J\u67e3ND \ufffd\ufffd@$\ufffdY\ufffd~\ufffd-\ufffd\ufffd\ufffd\ufffdC\ufffdMu(+lBp\u0411\ufffd\ufffd^\ufffd\ufffd#$\ufffd~\ufffd2�
/@\u0323\ufffd6 3\ufffdn\ufffdh\ufffd
+\ufffd;\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u06ea.\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd3F\ufffd\ufffdq3\ufffd\ufffd\\u064ev\ufffdZn\ufffdZ"/\ufffd\ufffdvNF\ufffd\ufffd\ufffd\ufffdN\ufffdJ2V{\ufffd#\u039aV\ufffds\ufffd\ufffd\ufffd\ufffde_\uc46e\ufffdT\ufffd\ufffda\ufffd8C�\ufffd!\u0397\ufffd\ufffd>F\ufffd\ufffdL\ufffd\ufffd\\ufffd\ufffdM{\ufffd\ufffd\ufffd5\ufffd\ufffdeH~7;F\ufffd\ufffd	\ufffd	\ufffdA\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdB?\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdY\ufffd=\u06e9\ufffd\ufffdQ i9\ufffdJ.s\u04ffc%\ufffd\ufffdFVb\ufffdd\u0565iL\ufffd\ufffd`\ufffda)kD\ufffd\ufffd\ufffd=W\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \n\ufffd\ufffd\ufffd\ufffde\ufffd>\ufffdN\ufffdX7\u0191�2I\ufffd\ufffdYf-\ufffdto7\ufffd\ufffd\ufffd/\ufffd~\ufffd\ufffdU\ufffd\ufffdas[\ufffd\ufffd`W\ufffd\ufffd*v3_\ufffd`~\ufffd\ufffd\ufffd\ufffd:k\ufffd\ufffd\ufffd\ufffdj\ufffdR("\ufffdE
+*\ufffd\ufffd\ufffd
+\ufffd\ufffde)DDI\ufffd\ufffdss\ufffd\ufffd,\ufffdf_n6\ufffd"\ufffd\ufffd\ufffd:hm\ufffdh+\ufffd]Aq�\ufffd\ufffdQq\ufffd\ufffdS\ufffda\ufffd\ufffd\ufffd\ufffd9\ufffd{~8\ufffd|\ufffd~b\ufffdh6\ufffdG\ufffd\ufffd\ufffdZ\u0120\u05ddN\\ufffdh\ufffd\ufffd+\ufffd\ufffd(E3\ufffd0\ufffd~\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdk\ufffdT\ufffdMG\ufffd\u03b2\ufffd\ufffd\ufffd\ufffd1\ufffd:zk\ufffda'L\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd2\ufffd>\ufffd\ufffd\ufffd\ufffd,gt\ufffd\ufffd\ufffdX&\ufffd@\ufffd?e%\ufffd
+\ufffd\ufffd\ufffd\ufffd\ufffd=@\ufffd\ufffdIh\ufffds\ufffd\ufffd\ufffd\ufffd)H\ufffd\ufffdU\ufffdOeX^m\ufffd\ufffd7R7\ufffd~\ufffd,\ufffd\ufffd\ufffd,\ufffd\ufffd\j\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\u050cf\ufffd\u036c\ufffd\ufffd\ufffd\ufffd\ufffd8!*\ufffd]\ufffdJR:\ufffd\ufffdW\ufffdR\ufffd]\ufffdM\ufffd\u025a\ufffd\ufffdP\ufffd\ufffdZ\ufffd\ufffd;\ufffd\ufffdJ\ufffdN\ufffd.8\u0266\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd,\ufffd[\ufffdr*\ufffd\u0391\ufffd]M\ufffd\ufffdM"wa\ufffdX)Lbjd\ufffd`\ufffd>:\ufffd?\ufffd\ufffd\ufffd\ufffd|:?u\ufffd\ufffd>^\ufffd\ufffdG\ufffd\ufffd\ufffd$\ufffd\ufffdfa\ufffd\ufffd.\ufffd
+\u02a5_\ufffdS\ufffd\ufffd%\ufffdED\ufffd8\ufffd\ufffdJ\ufffd\ufffd=\ufffd\u0115K\ufffd\ufffd\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd6rz\ufffdG\ufffd\ufffdG\ufffd\ufffd \ufffd\ufffd\ufffd\ufffd\ufffdU\ufffdi\ufffd<\ufffd\ufffd\ufffd\ufffdK\ufffdg\ufffd\ufffd"\ufffd\ufffd\ufffd^ \ufffdq\ufffd
+\ufffd\ufffd\ufffd\ufffdI6\ufffd\ufffd\ufffd\ufffdvP\ufffd\ufffd\ufffd\ufffdW\ufffdy^,\ufffd\ufffdu\ufffdc/5\ufffd\ufffd@\ufffd:\u01f9+[\ufffd\ufffdN\ufffd\ufffd+\ufffdl\ufffdi\ufffd{\ufffd\ufffdP\ufffd#^\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffdv\ufffd,�\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd-\ufffd\ufffdN\ufffd\ufffd\ufffd\u0473H\ufffd\u2ea3<\u05a1g\ufffdx\ufffd\ufffd\ufffdV\ufffd</\ufffd\ufffd\ufffdnb\ufffd\ufffd\ufffd6\ufffd\ufffd\ufffd\U000f4cdc\ufffd\u03a1 \ufffd+nhB\u02fe\ufffdP\ufffd\ufffdoT(\ufffdW\ufffd\ufffd#\ufffd#\u0109Tw\ufffdZU}\ufffd w-\ufffd\ufffdv\ufffd\ufffdT\ufffd\ufffd\ufffd\ufffd-9O\u1b7aHI\ufffdz)\ufffd\ufffd\ufffd\ufffd\ufffd \ufffdz\ufffd9\ufffd\ufffdR'\ufffdd\ufffdI5\ufffd\ufffda\ufffd\ufffdZ\ufffd\ufffdGS\u02df\ufffdag\ufffd\ufffdW=\ufffd\ufffd.\ufffdP1\u065c y?\ufffd\ufffd\ufffd\ufffd2\ufffd\ufffd\ufffd\ufffdX\ufffd)r\ufffd4VaG\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffd\ufffd\ufffd\ufffdBe\ufffd`9\ufffdQ1\ufffd\ufffd\u035a@8\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$\ufffd\ufffd\ufffdW?\ufffdD\ufffd}\ufffd\ufffdz\ufffd\ufffd2\ufffd*\ufffd
+\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffdt\ufffd+\ufffd\ufffd\ufffd\ufffd;Br\\u0715\ufffd'>\ufffd\ufffd\ufffd-\ufffd\ufffdv\ufffd\ufffdC\ufffdNe\u0294\ufffd\ufffd\ufffd\ufffd\ufffdL-\u028c\ufffdq\ufffd\ufffdK\ufffdH\ufffd\ufffd\ufffdr\ufffd7\ufffdI\ufffd
d<\ufffd\ufffd\ufffd\ufffd\ufffdB\ufffdgNelB^\u0583R\u03b3F2\ufffd\ufffdA\ufffdqCR\ufffd&\ufffdt\ufffd\ufffd\ufffd7\u07c4\ufffd\ufffd{"D9\ufffd\ufffd\ufffd\ufffdu)\ufffd\ufffdC\ufffd\ufffdw\ufffd\ufffd\ufffd1\ufffd\ufffdt\ufffd}?"\ufffd\ufffd\ufffd'\ufffd[\ufffd7o\ufffd\u0329\ufffd~\ufffd1\ufffd{\ufffd>R\ufffdu*\ufffd\ufffd\ufffd\u0296d\ufffdC\ufffd\ufffdl\ufffd\ufffd\ufffdu\ufffdtqf\ufffd2[\ufffdl\ufffd~{S4\ufffd>\ufffdJ$\ufffd\ufffd\ufffd\ufffd.nQ\ufffdnl\ufffdP\ufffd#\ufffdx\ufffd\ufffd])By`r+\ufffd\ufffdw\ufffd\ufffd\ufffd\ufffdLH?\ufffd\ufffd\ufffd\ufffdVD:\ufffd|\ufffd\ufffdiU\ufffdG\ufffd\ufffd~\u056a\ufffd+\ufffd\ufffd&+R\ufffd\ufffdb\ufffd gP\ufffd\ufffd>\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd\ufffdW\ufffd\u0539\ufffdk\ufffdQ\u01d6]WSkq\ufffdw\ufffd\ufffd\ufffdZ
+\ufffdD\ufffdQ\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffdV\ufffd\ufffd\ufffdd\ufffd24\ufffd\ufffd\ufffd\ufffdK\ufffdG\ufffdM\ufffdv\ufffd\ufffd\ufffdU35\ufffd\ufffdK\ufffdJ~\ufffd4&j\ufffd\ufffdw\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffd*\ufffd\ufffdy\ufffd;\ufffd\ufffdX\ufffd\u07c9\u02d4\ufffd\ufffdO\ufffd\ufffd\ufffd@\ufffd\ufffd5\ufffdhw)\ufffd\U00058d15\ufffdo\ufffd-9E:\ufffd\ufffd_\ufffd\ufffd\u0302\ufffdo\ufffd\ufffd\ufffd\ufffd&\ufffd6#\ufffdV\ufffd\ufffd(\u047dS\ufffd-te$\ufffd\u05e4p}\ufffd4\ufffd%\ufffd4m\ufffdrn\ufffdz\ufffd\ufffd\ufffd\ufffdhe4\ufffdKX*\ufffd\ufffdK�\ufffd\ufffd\ufffd\ufffd2\ufffd9\ufffd\u02a9\ufffd~\ufffd\ufffd\ufffd'\u01e4\ufffdl|O5�B\ufffd
+\ufffd;\ufffd^\ufffd\ufffdj\ufffd\u36d1Q\ufffd`\ufffdexH\ufffd\ufffd;\ufffdJ\ufffd\*\ufffd`l\ufffd\ufffd\ufffd\u02f4K\ufffdh\ufffd\ufffdk
+&\ufffd\ufffd\ufffd\ufffdt\ufffd\ufffd\ufffdF|(\ufffd\ufffd8V\u01e1\ufffd\u0737\ufffdR\ufffd\ufffd\ufffd:\u03f3\ufffd\ufffdo\ufffdG*UjSKk\ufffd\ufffdnR\ufffd\ufffd\ufffdgl\ufffd\ufffd\ufffd\u0785-\ufffd6\ufffd\ufffd\ufffd&\ufffd\ufffdN\u0157\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7O\ufffd4\ufffd\ufffdrGm\ufffd\ufffdO[du_T\ufffd\ufffdvY\ufffd{\ufffd\u030fIy\ufffd\\ufffdaR\ufffdKy\ufffd\ufffd&\ufffdP\ufffd7\u076aJ)\ufffdl\ufffd\ufffd\ufffd"\ufffdW\ufffd5\ufffd{K\ufffd\ufffd \ufffd\ufffd\ufffdS_\ufffd\ufffd\ufffd\ufffdj0WSW;\ufffdw\ufffdix\ufffd\ufffdF1\ufffd^l\ufffd\u041e\u4f34^\ufffd'\ufffd1\ufffd\ufffd\ufffdb\ufffd%\ufffdOA\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffdhq)L\ufffd7\ufffd\ufffdj\ufffd}=\ufffd9PX\ufffd\ufffd=\ufffd\ufffdn\ufffd\ufffd`\ufffd\ufffd\u0257KX#C�\ufffdA
*7{\ufffd \ufffdj\ufffd\ufffdW\u0734T\ufffdBy\ufffd\ufffd\ufffd\ufffd\ufffduf\u05db\ufffd\ufffd\ufffdd=\ufffdA\ufffd\ufffdf\ufffd\ufffd]\ufffd\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffd=\ufffd_u*`\ufffdq\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd+\ufffd_i\u074b\\ufffd^`BaE\ufffd|\ufffdS&\ufffd\ufffd\ufffd\ufffd%Z\ufffd\ufffda\ufffd8\ufffd\ufffd\ufffd\ufffd+Q\ufffd\ufffdg\ufffdQ\ufffd[\ufffdIK\ufffd\ufffd-\ufffdj\ufffd\ufffdIKr2T\ufffdcju\ufffd=A\ufffd\u02a7\ufffdQ\ufffd"7\ufffd\ufffd{\u066e\ufffd\ufffd\ufffd\u05dd*\ufffdX|,Y\ufffd\ufffd\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd\u047d\ufffd\ufffd\ufffd\ufffd\ufffd}\ufffd\u0188f:\ufffdjCo[>\ufffd]\ufffd\ufffdx^\ufffd\ufffd\ufffdh\ufffd\ufffd\ufffd\ufffdlhNr\ufffd\u03f3EDk\ufffd\ufffdc\ufffdC\ufffd\ufffd\ufffd\u01ea
\u05ea9\ufffd\ufffdc	\ufffd\ufffd\ufffdH\ufffdt<)\ufffd\ufffd}\ufffdz\ufffd\ufffd!\ufffdhE~DB\u04f3\ufffd2\ufffdS\u0346\ufffd\ufffdi{;\ufffdo\ufffd\ufffdu\ufffd
 I\ufffd\ufffdp\ufffd??\u78034\ufffd6\u067a\ufffd\ufffd^"\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd1\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd<\ufffd-\ufffd\ufffd65s\ufffd\ufffdj\ufffdp\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdSjqi6\u01f3\u06be\u0130\ufffd\u7d08\ufffd\ufffd4\ufffd\uf2c61\ufffd.\ufffd\ufffd$\ufffd5E\ufffdG\ufffd9\ufffd\ufffd\ufffd:\ufffd\ufffd=\ufffd\ufffdo\ufffd\ufffd\ufffdb\ufffd\ufffd\ucf84v#\ufffd\ufffd[\ufffd\ufffdx\ufffd\ufbe6\ufffdAF\ufffd+T\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(C@RQF\ufffd\ufffd7\ufffd7\ufffd2\ufffd\ufffdI$\ufffd\ufffd^a$\ufffdEq\ufffd\ufffd>\ufffd.\ufffdAE\ufffd\ufffdb\ufffd\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffdO0\ufffd\ufffd\ufffd\ufffd\ufffd]\u0422\ufffdK5\u03abP�\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd
\ufffd\ufffd\ufffd\ufffdZ\ufffdd\ufffd\ufffdJ\ufffd\ufffd\ufffd*\ufffd$d\ufffd\ufffd\ufffd\ufffd^\ufffd}E\ufffd*\u05a4\ufffd>?\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0184\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd$d\ufffd\ufffdO\ufffd\ufffd\ufffd	\ufffd_t\ufffdl\ufffd%\ufffd\ufffd$^7\ufffd\ufffd[\ufffdK\ufffd\ufffdS\ufffd\ufffdECq\ufffdz\ufffd"$]\ufffd*\ufffd\ufffd\ufffdB]\ufffd\ufffd}\ufffd\ufffdW\ufffd
zT[Rk\ufffd"\ufffd\ufffd\ufffd\ufffd\ufffdn\ufffd]\ufffdE\ufffd\ufffdU\ufffdYv\ufffd\ufffdFU\ufffdW\\ufffdB\ufffd\ufffd6\ufffd-RB\ufffd^M\ufffd\ufffde\ufffd2B\ufffd4\ufffd<ZR\ufffdV\ufffd\ufffdjV\ufffdy\ufffd~\ufffd\ufffdO\ufffd\ufffd
+W>\ufffd\ufffd/w\ufffd\u037a\ufffdh\ufffd4E\ufffd\ufffdk\ufffd5\u02d6\ufffd<1\ufffdU\ufffd\ufffd\ufffd[\ufffdt\ufffd\ufffd\ufffdD\ufffd\ufffd>\ufffdQ!\ufffd.kR\ufffd\ufffd\u6da7\ufffd7\ufffdu\ufffdJ\ufffd\ufffdc\ufffd>\ufffdc\ufffd\ufffd
+l\ufffd\ufffd\ufffd/\ufffd\ufffdi^\ufffd\ufffd3;i\ufffd\ufffd\ufffd\ufffd\ufffd\u0690\ufffd0\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\u0100\ufffd\ufffdZ\ufffdn\ufffdS\ufffd
+\ufffd\ufffd\ufffdq\ufffdW7\ufffdN\ufffd\ufffdp:\ufffd([\ufffd\ufffd\ufffd5\ufffd6\ufffd8\ufffd\ufffd\ufffdV\ufffdi\ufffdAF\u079c\ufffd~h\ufffd9\ufffdP\ufffdld�j\ufffd2\ufffddO
+\ufffd+\ufffd\ufffd\ufffd\ufffd6\ufffd\ufffd1\ufffd--\ufffd\ufffd1E\ufffd\ufffd\ufffdwv\ufffd\ufffd	\ufffd=JCH\ufffd\ufffdW\ufffd3\ufffd\ufffd4\u070f&\ufffdx\ufffd\ufffd8,\ufffd\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffd\ufffd#Rc\ufffd3D\ufffdvz\ufffd6\ufffd\ufffdRS\ufffd\ufffdyu\ufffd_N/nm\ufffd\u0643\ufffd\ufffdvT\ufffd\ufffd\ufffd\ufffd\u05a5Y\u02fc?\ufffd\ufffdRF\u05f0Kz\ufffdn\ufffd\ufffd9\ufffd\ufffd\ufffd\ufffdQ\ufffd\ufffd4\ufffdg\ufffdC\ufffd^\ufffd5l`\ufffdP\\u0732\ufffd\ufffd\ufffd\ufffdG\ufffd&\ufffd\ufffd\ufffd\u07ab`\ufffd\ufffd
\ufffd\ufffd9\ufffdP\ufffd\ufffd\ufffd\ufffd\u049e\u0672X\ufffd\ufffd\ufffdr\ufffd6\ufffd\ufffd\ufffd
+V4,\ufffd\ufffd{\ufffda\ufffd\u0604\ufffd\ufffd\ufffd\tcY`]l\ufffd\u01ff\u053e\ufffda\ufffd\ufffd\ufffdr\ufffd\u9d2f\u060f=b\ufffd\ufffd!\ufffd\ufffd&\ufffd\ufffd\ufffd\ufffdY\ufffdb

\ufffd^[\\ufffdaYt\ufffd$w	
+\ufffd\ufffd\ufffd[\ufffd\ufffdR\ufffd)\ufffd\ufffd\ufffdi\ufffd\ufffd[\ufffd{$\ufffd\ufffd7f"\ufffd\ufffdo\ufffd\ufffd\ufffdX\ufffd\ufffdp
+\ufffd\ufffdz\ufffdBz\ufffd\ufffd\ufffd\ufffd'h\ufffdO|\u014c4\u01d0\ufffd|-\ufffdj\ufffd\ufffd
+:\ufffd\ufffd\ufffd}\u0334a\ufffd%Tv\ufffd\ufffd5\ufffd\ufffdY9QK\ufffd \ufffdd0?\ufffd$\ufffd\ufffd\u0107H|\ufffd#\ufffdu\ufffdD\ufffd3\ufffdp\ufffd\ufffdh\ufffd\ufffd\ufffdr\ufffdd\ufffd@,@Xm\ufffd\ufffdVKY\ufffd\ufffd@o\ufffd\ufffdu\ufffd\ufffd([\ufffd\ufffd\ufffd8#!OM~\ufffd.\ufffd7SoJn%<\ufffd\ufffdI\ufffd\ufffddZ\ufffd\ufffd=\ufffd1\ufffdD3\ufffd!P#4\ufffd\ufffd\ufffd\ufffd(|:]SYd\ufffd\ufffd\ufffd_\ufffd\ufffdkG\ufffd\ufffd\ufffd\ufffd\ufffdRh\ufffd+Ot\ufffdB\ufffd\ufffd\ufffd%\ufffd/e\ufffd\u4c56\ufffd&]\ufffdh\ufffd\ufffdr5\ufffdsl\ufffdor\ufffd\ufffdQ\ufffd\ufffd\ufffd\ufffd"F\ufffd,b\u0553\ufffd*2~\ufffd\ufffd:\u02bc\ufffd\ufffdi\ufffd\ufffd[\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdt\ufffd\ufffd\u02e6\ufffd\ufffd\ufffd\ufffd~M
+\ufffdU\ufffd6\ufffdDU\ufffde\ufffd"udPO:\ufffd\ufffd\ufffd]\ufffdx+\ufffd\ufffd\ufffd\ufffdG\ufffd\ufffdB\ufffd\ufffd\ufffd]\ufffd\ufffdq:\ufffd\u02a5\ufffd'\ufffd:\ufffd-ML3\\ufffdF$\ufffd7\ufffdK\ufffd3\ufffdC\ufffd\ufffd*s\ufffd2\ufffd\ufffdz\ufffdF\ufffds\ufffd'\ufffd�\ufffd\ufffd\ufffd\ufffd\ufffd\u033cK\ufffd\ufffd\ufffds\ufffd\ufffd\ufffd\ufffd\ufffd\u04da\ufffd\ufffdw\ufffdER\ufffd\ufffd	\ufffd!`%aT\ufffd\ufffdH\ufffd\ufffdv\ufffdR\ufffdW\ufffd\ufffdSP\ufffd\u0185T\ufffd\ufffd\ufffd}FVArB\ufffd[\ufffd\ufffdSS &\ufffd\ufffd}p\ufffd`\ufffd	\ufffd~\ufffd\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd1{\ufffd,y\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd{\ufffd30\ufffd\ufffd[\ufffdb\ufffdK\ufffd\ufffd\ufffd:w\ufffd3\ufffd\ufffdMn\ufffd\ufffd\ufffd\ufffde6\ufffdsz/0<x\ufffd&\ufffd3\ufffdnj\ufffd\ufffd\ufffd@\ufffd\ufffd\ufffd_d
\ufffdK\ufffdB\u0653\ufffd! t\ufffdr\ufffd\ufffd!\ufffd6<\ufffd\ufffdr\u0195\ufffdKjT\ufffd;\u04bd\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffdZ\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd.,\ufffd\ufffd68\ufffdMUl\ufffd\ufffd{D6v\ufffd\ufffd\ufffd\ufffd@)tmp\ufffdy\ufffd_.>OG\ufffd"
+�3N\ufffd\ufffd|\ufffd\ufffd\ufffd/\ufffd'\ufffd\ufffdO\ufffd\ufffd-R_\ufffd1Vh&\u05faN\ufffdPz8de\ufffd\ufffd\ufffd
\u52caZTH;X\ufffd\ufffd\ufffd\ufffdQ\ufffd6\ufffd}\ufffd\ufffd+\ufffd\ufffd\ufffd'h\ufffd\ufffd_\ufffd|\u020b\ufffd\ufffdCc\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffdH\ufffd\ufffdj\ufffdBA\ufffd,\ufffdN\ufffdOS\ufffd\ufffd\ufffd{\ufffd3\ufffd\ufffd\ufffd	L\ufffd\ufffd\ufffd`]\ufffd\ufffd\ufffd1\ufffd\ufffd> A\ufffd\ufffd\ufffd
\ufffd\ufffdrx\u04f4\ufffd*E^\ufffd.\ufffd\ufffd\u0610`\ufffd\ufffd\ufffd\ufffdQ5\ufffdv{`=W6\ubf1f\ufffd\9a\ufffd\ufffd\ufffd\ufffdvGO\ufffd\ufffdXc&
v\ufffd\ufffd1\ufffd\ufffd\ufffdw\ufffd~\ufffd\ufffd\ufffd\ufffd0\ufffdW\ufffd:\u028e~\ufffd\ufffdf\ufffd\ufffd:
0\ufffd/\u02f5\ufffd\ufffd%\ufffdm\ufffdKRK\ufffdA\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdc\ufffdR\ufffd%\ufffd	\ufffdP\ufffd#CS\ufffd\ufffd\u07e5\ufffdf\ufffdmD\ufffd5\ufffdoEx\ufffd\ufffd1\ufffd7B\ufffd\ufffd\ufffd\ufffd0\ufffd\ufffd\ufffd\ufffd<&\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdYd\ufffd8"1\ufffd\ufffdw\u07215\ufffd\ufffd TaaJ3p\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd7\ufffdA\ueabc>\ufffd\ufffd+\ufffd\ufffdy\ufffd\ufffdI\ufffd\ufffdM\ufffd\ufffd\ufffdc\ufffdu\ufffd\ufffd
Zd?\ufffdB\ufffd\ufffdk1\ufffd\ufffd\ufffdx-\ufffd\ufffd\ufffdr\ufffdsV\ufffd\ufffd9s\ufffdH6p]D\ufffdG\ufffdg\ufffdO|y\ufffd\ufffd5\ufffdS\ufffd$a\ufffdE\ufffd`$\ufffdLs
+[\ufffd\ufffdYm\ufffd
\ufffd~u\ufffd8\ufffd\ufffdp`6*I\u07d5\ufffd`S8\ufffd\ufffd\ufffd8s\ufffdn\ufffd\ufffd9O3nX\ufffdOE/7f\ufffd^\ufffdl\ufffdbN\ufffd[\ufffdPB\ufffdF\ufffdO\ufffd\ufffd.\ufffd9\ufffd\ufffd\ufffd\ufffdZ\ufffd\ufffd_.\ufffd5\ufffd>\ufffdF	\ufffd\ufffd\ufffdS\ufffd\ufffd\u0309\ufffdR\ufffd'}\u03aa\u046c`_d\ufffdX\ufffd|\ufffd{\ufffdd\ufffd\ufffdHX\u053e3\ufffdQlZe7P\ufffdR\ufffd\ufffdq\ufffd\u0634\ufffdO5\ufffd\ufffd\ufffd\ufffdOkZ\ufffd\ufffdr\ufffdx5u`a\u01c2:\ufffd\ufffd*`\ufffdT\ufffd)\ufffd\ufffd,\ufffd
+DPQ\u02ae\ufffd\ufffd\ufffdd\u07d3\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd\ufffdRk=H+
+*\ufffd#u)\ufffd\ufffd\ufffdh\ufffd\ufffd) \ufffd\ufffd)B\ufffd6\ufffd\ufffds\ufffd9\u07f9\u778f\ufffd\ufffdH\ufffdZG\ufffdz\ufffdG\ufffd\ufffd\ufffdT\ufffd"9\ufffd\ufffd3h\ufffdD\ufffd\u037a\ufffd\ufffds\ufffd\ufffdr|\ufffd\ufffdb\ufffd4\ufffd\ufffdy	\ufffd$\ufffd\ufffdTK	\ufffd\ufffd\ufffd"\ufffd$\ufffd\ufffdI\ufffd\ufffd~\ufffd$\ufffdv(\ufffdB\ufffd\ufffd#].\ufffd\ufffdqi\ufffd\ufffd?\ufffdC\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\u07b1\ufffd|\ufffd\ufffd\u0737\ufffdLcO\ufffdn\ufffd\ufffd\ufffdT~\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdvxj\ufffd\ufffd\u03265<.\ufffd\ufffdf\K<\ufffd\ufffd2p\ufffd:Cp\ufffd\ufffd\ufffdS\ufffdy,66\ufffd\ufffd>|z\ufffdC
+\ufffd\ufffd\ufffd\ufffdE
+T)\ufffd\ufffdf/\ufffd\ufffd:X1\ufffd}J+\ufffd\ufffd>\ufffd\ufffd\ufffd_\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffdQ;\ufffd^\ufffd\ufffd\u31aavs&\ufffd\u06f8>\ufffd.\ufffdk\ufffd7\ufffd\ufffdyZ\ufffd\ufffdS\ufffd\ufffd:\ufffd\u02e9\u370d\ufffdr\ufffd\u0756\u06dc\ufffd\ufffd\ufffdaKa\ufffd\ufffd\ufffd!l\ufffd\ufffd.g5\ufffd\ufffd\ufffd7\ufffdKv\ufffd0\ufffd\ufffd!;\u0697\ufffdf\ufffd\ufffd\ufffd\ufffde\ufffd\ufffd\ufffd%\ufffd]"X\ufffdT\ufffd\ufffdJ3\ufffda\u056a\ufffdlwV\ufffdj=v\ufffd\u59e0\ufffd\u03b1\ufffd\ufffd\ufffde=b\ufffdI/\ufffd\ufffdg\ufffdH&\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffdg,(y	27\ufffd>a\ufffdb\ufffda\ufffd8\ufffd\ufffd\ufffd8f\ufffd\ufffdVV\ufffdq\ufffd\ufffd\u024cT\ufffd\ufffd\ufffd0\ufffd\ufffdN\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u0249B\ufffd\ufffd\ufffd\ufffd\ufffd`(\ufffd_"f\ufffd\ufffdo!\ufffd\ufffdt}Wg\ufffd\ufffd_0}H\ufffd\ufffd\ufffdX\ufffd9\ufffd,\ufffdQ\ufffd\ufffd\ufffdx\ufffd\ufffd\ufffd=\ufffd~J\u0679\ufffdx\ufffd>\ufffd\ufffd\ufffd\ufffd\u04f1e\ufffd9\ufffdM\ufffd\ufffd\ufffd2mF\ufffd\ufffdS\ufffd\ufffd)\ufffdVk\ufffd\ufffd\ufffd\ufffd-eZF\ufffdF\u0665bt\ufffdg0\ufffd\ufffdO?\ufffdD\ufffd\u01d0%7ey\ufffd\ufffd\u069a6\ufffd\ufffdW\ufffd\ufffdS\ufffd\ufffdC\ufffd\ufffdy\ufffde\ufffd\ufffdUS}\ufffd\ufffdl\ufffd`a\ufffd8\uf46ei	\ufffd\ufffdg"1\u043bJ\ufffd"\ufffd|P\ufffdK\u069d\ufffdc\ufffd,\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffd+\ufffd&\ufffd\ufffd\ufffdP\ufffd\ufffd\ufffd\ufffdv\ua5b4GBoj_t4I\ufffdvq\ufffdf\u719a(\ufffde\ufffd\ufffdC\ufffd\ufffd!\ufffd\ufffdb\ufffd\u05fc\ufffd^\ufffdS\ufffd\ufffdb\ufffdYi1\ufffd\ufffd\ufffd�;2\ufffd\ufffdW\ufffd`/7u\ufffdh?4
+\ufffd\ufffd\ufffd\ufffd!\ufffd\ufffdz\ufffd\ufffd@#(\ufffd\ufffd\ufffdT\ufffd\ufffd\ufffd6\ufffd\ufffd^\ufffd\ufffd!\ufffdR	S\ufffd\ufffd#\ufffd>E/\ufffdS\ufffdq9\ufffdz_ /G%\u04c80C\ufffd9\ufffd[\u06fc\ufffd@\ufffd(\u0669\ufffd\ufffdP\ufffd\ufffd\ufffd,\ufffd}\ufffd\ufffdX\ufffdT\ufffdOk\ufffd\ufffdp\ufffd\ufffdQ\u022bU\ufffdG6\ufffd\ufffd
\ufffdx\ufffd2\ufffde,\ufffd\ufffd>\ufffd\ufffd\ufffd
-?\ufffd\u03ed\ufffd\ufffdQ\u07acYz\ufffd/\ufffdT\ufffd\ufffd\ufffd5\ufffdFL\ufffd\ufffd^`\ufffdt\u07a9\ufffd\ufffd3\ufffd\#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u032cD\ufffd:\ufffd,\ufffdv\ufffd\ufffd\ufffdw[mDW\ufffd\ufffd\ufffd\ufffd\ufffd)\ufffd\ufffdTB\ufffd\ufffdZ\ufffd\ufffd\ufffd`0\u0556`3t\ufffdBQ\u02dfkk\ufffd\ufffds4\ufffd1y\ufffd	\ufffd`\ufffd\\ufffd\u07b8\ufffdc\ufffdV\ufffd#\ufffd\ufffdz`X\ufffdHhw\ufffdA\ufffd\ufffd0\ufffd\u0686FTy\ufffd\ufffdq\u04f5\u072b*F\u02ea\ufffd%\ufffd\ufffd*\ufffd\ufffd\ufffd\ufffd/>\ufffd9
+\ufffdgS'\ufffd"b'zL=N\ufffd)c\ufffd\ufffds\ufffd*\ufffd\ufffd\ufffd\ufffdb\ufffdR\ufffd\ufffd\ufffd\ufffd\ufffd)W<\ufffd#\ufffdS	\ufffd\ufffd\u765b)K\ufffd\ufffd\ufffd\ufffd
\ufffd\ufffd
+&\ufffd\ufffd\ufffdL\ufffd\\ufffd\ufffd9W\ufffdt\ufffdW!Y1\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7i*\ufffd%\ufffd\ufffd\ufffd\ufffd\ufffdwJ_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\u95a5\ufffdn\ufffdWJ\ufffd!p\ufffd\ufffd\ufffd\ufffd\ufffd-0\ufffdT`\ufffd:K6B\ufffd+\ufffd\ufffdS\ufffd\ufffdz\ufffdl\ufffd\ufffdL,~\ufffd\ufffdJ#ZL\ufffdHBEe\ufffd\u07c8E\ufffdq1
+\u06b8\ufffd\ufffdTD}\ufffdbB;\ufffd\ufffd*O\ufffdTC\ufffdn\u054dl\ufffd$OY\ufffd\ufffdQ\ufffd\ufffd0m\ufffd\ufffdz7\ufffdo\ufffd\ufffd9N\u017b\ufffd|h\ufffd\ufffdDV\ufffd[V\ufffd\ufffde\ufffd\u05a9b7\ufffd\ufffd\ufffdY\ufffd\ufffdZ�\ufffdH\ufffd\ufffdl\ufffd\ufffd\ufffd\ufffd\ufffd~I\ufffd)\u073b\ufffdJ\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdoO\ufffd\ufffd\u0751\ufffd\ufffd\ufffd%(\ufffd\ufffd,\ufffdh\ufffdZ\ufffd\ufffdG\ufffd\ufffd\u04bcmR\ufffdd\ufffd\ufffd\ufffd!\ufffd\ufffd/NEWutV57z;\ufffdj\ufffd\ufffd\ufffdj\ufffd\ufffds\ufffd\ufffd\ufffd^\ufffd^lD\ufffd\u01fe0-a\ufffd\ufffd\ufffd_a\ufffd\ufffdL\ufffd\u0601\ufffd\ufffdw\ufffd\ufffd\ufffd44\u7c0db^\ufffd\ufffdppi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd&n\ufffdX\ufffd	\ufffd\ufffd\ufffd\ufffdu\u01bb-\ufffd\u0742
\ufffd-c\ufffdY4\ufffd\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdg	?\ufffdj\ufffdG\ufffdI\ufffdfH\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffdJ\u0482[\ufffd\ufffd%\u03e9\ufffdC6OzvW\ufffdz\ufffd\ufffdoZ\ufffdt\ufffdA\ufffd\ufffd\ufffd\ufffd$\ufffd?z\ufffd\ufffd\ufffd;\ufffd\ufffd\u063c\ufffd\ufffd\ufffdFT2\ufffd/+\ufffd\ufffd0\ufffd\ufffd\ufffd@\ufffd\ufffd@S<@>0b\ufffd\ufffdS\ufffduq\ufffdw;j4S\ufffd'\ufffd/4s\ufffd\ufffd\ufffd\ufffdE\ufffd\u0569(P[\ufffd\ufffd\ufffd\ufffdV\ufffd^\ufffd5\u018aH\ufffd\ufffdk\ufffdg/\ufffd\u06c4\ufffdw\ufffd\ufffd\ufffd\ufffd0\ufffd\ufffd*\ufffd\ufffd\u05ad \ufffda\ufffdj\ufffdyB\ufffd\ufffd5\ufffdTC\ufffd\ufffdJ(\ufffd_\ufffd\ufffdF\ufffd4\ufffd\ufffd\ufffd\ufffd!\ufffdm\ufffd,R\ufffd\ufffdN\ufffd
\ufffd?S\ufffd\ufffd\ufffd\ufffd9\ufffd\ufffd
:\u05f4\ufffd\ufffdO\ufffd\ufffdf\ufffd\ufffdO\ufffdV\ufffd\ufffd"\u0575\u06871\ufffd\ufffd\ufffd,V)S\ufffd\ufffd@\ufffd._
+\ufffd\ufffd\ufffd#\ufffd\ufffdQ\ufffd`\ufffdK\ufffd\ufffd\ufffd|\u0368%c\ufffdj\ufffd\ufffd/&\\ufffd\ufffd:
[\ufffd\ufffdF\ufffdt\ufffd^Z"\ufffd\ufffdq\ufffd\u0664Jm\ufffd\ub64ajMar\u05d7\ufffd`VCg
+\ufffd\ufffdw"\ufffd~><\ufffd\ufffd
\ufffd8\ufffdi\ufffd\ufffd\ufffd\ufffd}\ufffdX\ufffdT8\ufffd\u01f3Q\ufffd\ufffdVY<\ufffd\ufffd<\ufffdJ=\ufffd\ufffdE\ufffd\u06cf7G8v6\ufffd\ufffdZ:\ufffd%\ufffd\ufffd\ufffdhB�\ufffd94^\ufffd\u0525m!1\ufffd\ufffd\ufffdOD>\ufffdp%\ufffdH\ufffd\ufffd\ufffdG\ufffd\ufffd\ufffd\ufffd\ufffd/\ufffd�`rq\ufffd;\ufffd\ufffdN\ufffdm\ufffd~M\ufffd\ufffd\ufffds\ufffd\\ufffd\ufffd/\ufffd\ufffd\ufffdZ\ufffdh\ufffd:\ufffd(\ufffd\ufffdMX\ufffd\u0430^F\ufffd.\ua70b\ufffd.\ufffdY\ufffd\ufffd\ufffd\ufffds}5\ufffd`a\ufffd\ufffd\ufffd\ufffd(\ufffd(X0\ufffdT\ufffd+JS\ufffd\ufffd\ufffd4\ufffd&\ufffd\ufffd~\ufffd\ufffd|iB!!
!)$\ufffd)\u02b0\ufffd\ufffd\ufffd\ufffdWF\ufffdY]E\ufffd\ufffd\ube0e3x,\ufffd\ufffd\u02fd\ufffd}\ufffd\ufffd\ufffd|d\ufffd\ufffdc\ufffd
+\ufffd\ufffd|\ufffdi-\ufffd\ufffd0\ufffdWs\ufffd\ufffd
+Q_G\ufffdpRj\ufffdy\ufffd0\ufffd\ufffd\ufffd\u05ff\ufffdt\ufffd\ufffd\ufffd\ufffdj\ufffd\ufffdT\u030e\ufffd\u050d\ufffd\ue1c9D1\ufffd\ufffd\u0685\ufffd\u068d�N\ufffd:ka?\ufffd\ufffd\ufffd7\ufffde\ufffd\ufffd\ufffdk\ufffd\ufffd_\ufffd%]a;\ufffd\u05d6\ufffd\ufffd\ufffdF\ufffd=\ufffd9\ufffd\ufffd-b=&\ufffd\ufffdMm0-\ufffdvD\ufffd'^\ufffdj\ufffd\ufffd+\ufffd\ufffd/5(er\ufffd^\ufffd+E\ufffd\ufffdL
F1\ufffd$\ufffd1K\ufffd\ufffd\ufffdWE|f\ufffd\ufffdO\ufffd\ufffdFMK\ufffd\ufffd\ufffd\ufffd\ufffdm\ufffd\ufffd:\ufffd:1`\ufffd\u06a5f\ufffd\ufffdX\ufffd\u0429M\ufffd*i\ufffd9\ufffd\ufffd
+l?+Lw?-Nx\ufffd\ufffd\u0348\ufffd\ufffdw\u0273\C0\ufffd\ufffd\ufffd\u7443f	\ufffds\ufffd\ufffd\ufffd\ufffdM;i\u0111`\ufffd\ufffd$\ufffd\ufffd\ufffd\ufffdO\ufffd\ufffd\ufffd0z\ufffd\ufffd*R\u0679\ufffdB9\ufffd@\ufffd"\ufffdk\ufffd\ufffd5\ufffd\ufffd\ufffd\ufffd\ufffdv\ufffd\ufffd~\ufffd.l\ufffdB?\ufffdug\ufffd]\ufffded\ufffd\ufffd\ufffd\ufffd\ufffd8J\ufffdA\ufffdj\ufffd\ufffd\ufffd\u0379um\ufffd.\ufffd\ufffdD\ufffdO\ufffd\ufffd^^\ufffd\ufffdv:\ufffdy;\ufffd\ufffdske\ufffd\ufffd+,L\ufffd�v\ufffd\ufffd\ufffd\u015d\ufffd\ufffd\ufffd\u04bc\ufffd\ufffd\u062e\ufffd\ufffd\ufffd\ufffd\ufffdd\ufffd\ufffd_\ufffd\ufffd5\ufffdZ\ufffd\ufffd\ufffd\ufffd;q\ufffd#\ufffdk>\ufffd\ufffd\ufffd\ufffd \ufffdMU\\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd{l*\u035f\ufffd\ufffd\u0491\ufffd3Do\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd"UDc\ufffd\ufffd\ufffd\ufffd\ufffdu\ufffd\ufffd#H\ufffd)BP\ufffd\ufffdit\ufffd\ufffd/	v\ufffd`\ufffd_\ufffdS\u029d\ufffd{\ufffde\ufffd5mp\ufffdPpy\ufffd=\ufffd-2\ufffd\ufffd[\ufffd\ufffd\ufffdm\ufffd+v\ufffd\ufffd6*.\ufffdW\u06ff\ufffd\ufffdS\u01d4\ufffd\ufffd]\ufffd
+^DMk\ufffd\ufffd,2\ufffd.#\ufffd\ufffd\u0272\ufffd\\ufffd\ufffd\ufffd!{\ufffd^\ufffd\ufffdI4\ufffd\u0508\ufffd\ufffd.~\ufffd�\ufffdlDc\ufffdBU\b\ufffd"c
\ufffdj\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffdJ\ufffdG\ufffd|\ufffdH`_\ufffd\ufffd2\ufffdr\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdH\ufffd\ufffd\u0465\ufffd
\ufffd\ufffdt\ufffd\ufffdHH\uf8de\ufffd\ufffd\ufffdBaG\ufffd	:\ufffd\ufffd\ufffd\ufffdB\ufffdf\ufffd\ufffd{\ufffd'\ufffd9
+[\ufffdj\ufffd\ufffda\u0427\ufffd\ufffde
+&h\ufffd\ufffdz6F\ufffdd\ufffdy?\ufffd>g\ufffd\u06d1x&\ufffdl$\ufffd\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffd:\ufffd\ufffd\ufffd\ufffd^\ufffd\ufffd\ufffdn\ufffd\ufffd\ufffd\ufffdx-'-\ufffd\ufffd\ufffd\ufffd]\ufffdO 5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd@S\ufffd U\ufffd\ufffd\u068fy]\ufffdTu \ufffd_,z\ufffd\ufffdWPT\ufffd|BJ,\u0255}`8\ufffd\u07f4y?p\ufffd7g\u02e2u\ufffd\ufffd\JO(_\ufffd\ufffdvOUue4\ufffd\ufffd\ufffd+Q\ufffd\ufffd\ufffd\ufffdbi\ufffd?A.j\ufffd\ufffd\ufffd\ufffdCxy\ufffd\ufffd\ufffdR\ufffd\ufffd\ufffdJ\ufffd\u99e5\ufffdP\ufffd\ufffdt\u3e32r\ufffd\ufffdT\ufffd\ufffdfd\ufffdd$\u05ba\ufffdFR>P\ufffda\ufffdL\ufffd\ufffd\ufffd'\ufffd\ufffd\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffd2M\ufffd\ufffd\ufffd*\ufffd\ufffd\u05f5\ufffdT\ufffd]`W\ufffd\ufffd*\ufffdcD\ufffd*\ufffd\ufffdh\ufffdA\ufffde#\ufffd"\ufffd\u0246KO9\ufffdJ\ufffd\ufffd\ufffdKL\ufffd\ufffd2\ufffd\ufffdJ\ufffd\ufffd\ufffd\ufffd(KgK3j\u0509f\ufffd\ufffdZ\ufffd\ufffdnL\ufffd\ufffd5\ufffd\ufffdo\ufffd\ufffdM(\ufffd_\ufffd\ufffd\ufffd>\ufffdFO\ufffd\ufffd\ufffd\ufffd\u04f9Gi}<\ufffd\ufffd\ufffd@w\ufffd\ufffd#Nd\ufffd\ufffd\ufffd\ufffdhoo4\ufffdY\ufffd\u033e\ufffdF\u06782\ufffd\ufffd\ufffd\ufffd\ufffdY\ufffdA\ufffd\ufffdz$\ufffdW\ufffd\ufffd\u059c5\ufffd\ufffdCopl\ufffdi\ufffd\ufffd\\ufffd\ufffd\ufffd\ufffd3\ufffd2\ufffdl\ufffd;\ufffd\ufffda\ufffd<;\ufffdS\ufffd?B\ufffd>\ufffd<A\ufffd\ufffda\ufffdrL>\ufffdz\ufffd\ufffdpr\ufffdj\ufffd\ufffds\ufffdm\ufffd\ufffd1t\ufffdZ\ufffdc\u0325\ufffd\ufffd{\ufffds\ufffd/\ufffd\ufffd\ufffdJ{\ufffd\ufffdc\ufffd*\ufffd#\ufffd3\ufffd\ufffd\u0780f\ufffd\u03e1ne\ufffd\ufffd\ufffdh\ufffd\ufffd-\ufffd>Bc9SJ\ufffd\ufffd\ufffd"\ufffd\u0579O8\ufffd'\ufffd8\u0780 `yH
 \ufffd\u03e4u\ufffd-\ufffd*`\ufffd\ufffd	x[c')Oy\ufffd\ufffd\ufffd\ufffd\x!\ufffdQ\ufffd\ufffd\ufffdS9q<o\ufffdc\ufffd\ufffd\ufffdWSR^\ufffd\ufffd[H\ufffd{\ufffde\ufffdU\ufffd\ufffd\ufffd!.$\ufffd\ufffd,]\ufffd\ufffd\ufffd\ufffd(\ufffd\ufffd1
+\ufffdoe\ufffd*\ufffd\ufffd
+\ufffdp\ufffd\ufffd\ufffd}\ufffd\ufffd\ufffd\ufffd%\ufffd\ufffd
+K\ufffd"G\ufffd*\ufffd
yE\ufffd%\ufffd\ufffdS\\ufffd#\ufffd\ufffd\ufffdV\ufffd9\ufffd\ufffd\u06e62\ufffd4=\ufffd\ufffd\ufffdZH\ufffdW}d\ufffd\ufffdUU\ufffd\ufffd$\ufffdU\ufffd\ufffd\ufffd>*;\ufffd$;\ufffdd'=\ufffdNY\ufffd\ufffd,|\u07363\ufffd4\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffdT\ufffd=\ufffdka%\ufffd\ufffd\ufffdh\ufffds\ufffd\ufffd\u4b3a\ufffd\ufffdU\ufffdX7Fl\ufffd\ufffd[\ufffd\ufffdo\ufffd\ufffd1a\ufffdpuxf\ufffd9\ufffd\ufffdQ\ufffdGk4\ufffd;e
+\u02f8\ufffd7\u8347\ufffd5\ufffd\ufffdxB:\ufffdy\ufffd\ufffd\ufffd\ufffdZd\ufffd\u036b,\ufffd`2\ufffd\ufffd?_\ufffda[0\ufffd~9iYFs\ufffd3\ufffd\ufffd\ufffdg\ufffd\ufffd	\ufffd�9u\ufffd\ufffd\ufffd\ufffd<,yx\ufffd87\ufffd\ufffd\ufffd \ufffd1\ufffd\ufffd\ufffd\ufffd\ufffdJa\ufffd\ufffd\ufffd,O\ufffd@/g\ufffd\ufffd\ufffdO\ufffd\u351b\ufffd9\ufffd4 \ufffd|.]\ufffd1\ufffd6\ufffd\ufffd'\ufffd^\ufffd\ufffd@1'\ufffd\ufffdp:Xt\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdwL,j\ufffd\ufffdV\ufffd\ufffd\ufffdQv@\ufffdwl{\u03ad\ufffd\ufffd\u0331\ufffd\ufffd\ufffd\\ufffd?R^\ufffdUV\ufffd\\ufffdGI\ufffd+\ufffd\ufffd\ufffd\ufffd\ufffd9\ufffd\ufffd\ufffd\ufffd\ufffdD\ufffd0\ufffd\ufffd\ufffd3o\ufffd\ufffdy\ufffdd\ufffd[R<\ufffd"\ufffd"\ufffd\ufffd"
+.\ufffd\ufffd2\ufffd}\ufffd\ufffd"!<\ufffd4t\ufffdH~(\ufffd\ufffd-r\ufffd\ufffd2\ufffd\ufffd5D\ufffdH@\ufffd\ufffdl\ufffd\ufffd"K\ufffd\ufffd\ufffd\ufffd\ufffd\u6fe3,\ufffd\ufffd/S}\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd"+\ufffd\ufffd\ufffd~w\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdF}V
dR\ufffdz\ufffd,\ufffd\ufffd:\ufffdw&?\ufffd\ufffdC~Fq\ufffd\ufffdJ}J\u0762\ufffd\ufffd\ufffdJ\ufffd\ufffdi\ufffd\ufffd\ufffdrjzE\ufffdgU\ufffd#\ufffd\ufffdp]ZF\ufffd\ufffd\ufffd%\ufffd\ufffd+\ufffd\ufffd\ufffd[\ufffdPje\ufffdw\ufffdVjl\ufffd\ufffd\ufffdW\ufffd7\ufffd\ufffdwR\ufffd\ufffd/*\ufffd\ufffdC%\ufffd%\ufffdj\ufffd\ufffdG\ufffdx\ufffd@EFH)&0_\ufffd\ufffd\ufffd\ufffd\u0555\ufffd|Xu\ufffd
+D\ufffd\ufffd\ufffdRNXA\ufffd\0JS\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffd30\ufffd\ufffd7\ufffd\u035b7\ufffd3C\ufffdWc+\ufffd\ufffdU#\ufffdr#aQOL4E\ufffd\u0459?\ufffds~\ufffd{\ufffd\ufffd\ufffds\ufffdI\ufffd\ufffd\ufffdy\ufffd?\ufffdy>\ufffd\u0492L\ufffd\ufffd\u05b8Kd-\u07a3J1\ufffdv\ufffd*fH
\ufffd6\ufffd\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdz\ufffd+~B\ufffdO\ufffd:I\ufffd\ufffdQq\ufffdZ\ufffd\ufffdU\u054d\ufffdP\ufffd[\ufffdU\ufffd\ufffdD#\ufffdBM\ufffd	\ufffd\ufffd>$\ufffd	\ufffdz|\ufffd\ufffd?\ufffd\ufffd^\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd!J0\ufffd\ufffdW8\ufffdN\ufffd	\ufffd\ufffdW\ufffdzX\ufffd\ufffdf\ufffd\ufffd\ufffd\u0449@'h\ufffd\ufffd<\ufffd
+%sd\ufffdR\u06d4e\ufffd[\ufffd$z\ufffd,\ufffd\ufffdZ\ufffd2\ufffdH5\ufffd\ufffd\ufffd\ufffd[&Ht	L\ufffd\ufffd\ufffd
\ufffd\ufffdU\ufffdO\ufffd\ucdef\ufffd<\ufffdu\ufffd\ufffd\u024erE\ufffd\u1f80{i\ufffd,8+\u05dfwM2\ufffd\ufffdO\ufffd\ufffd\\ufffd\ufffd7I8\ufffd\ufffdi\ufffdl\ufffd2\ufffdewkv"9k\ufffdr6�\ufffd\ufffdU\\ufffdR\ufffd\ufffd*\ufffdq\ufffd\ufffdo\ufffdGCxxy\ufffd\ufffd\ufffd;\ufffd:j\ufffd\ufffdY\ufffdE)a\ufffd\ufffd\ufffd\u03b0!Xid\ufffdj\ufffd\ufffd
q(\ufffd\ufffd\ufffd8\ufffdS\ufffd\ufffd=\ufffd\ufffd\ufffdl\ufffd(\ufffdP\ufffd\ufffd9Iue\ufffd&\ufffd\ufffdk)\ufffd\ufffd\ufffdW1\ufffd\ufffd\ufffd\ufffd=k\ufffd\ufffdZ\ufffdb;8\ufffdzB\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffd4\ufffd\ufffd\u0695a\ufffdv\ufffd\ufffd?\ufffdsu\ufffd\ufffdUuP\ufffd\ufffd\ufffd\Vf\ufffd>+\ufffd5\ufffd2\ufffd\ufffdj&\ufffdP\ufffd6\ufffd\ufffd\ufffduR\ufffd\u026e\ufffd!
+a\ufffd+\ufffdr\ufffd\ufffd\ufffdk\ufffd!\ufffdo\ufffd4	\ufffd\ufffd`\ufffd\ufffd\u0717\ufffdP)f\ufffd\ufffd%\ufffd\ufffdV\ufffd\ufffdQ\ufffdT\ufffd\ufffdF\ufffd(Z\ufffd]s\ufffd\ufffd\ufffd,\ufffd\ufffdTR\ufffd|O)O?\ufffd\ufffdh\ufffdo\ufffd# ]\ufffd6y\ufffd\u043b\ufffd)\ufffd\ufffdO\ufffdU\ufffd,F\ufffd\ufffd\u0660\ufffd\ufffd\ufffd\ufffdE})\ufffdg\ufffds\ufffd\ufffd\u0674G\ufffdy\ufffd\u0498p/kw~\u02d6\ufffd\ufffdI'Y\ufffd\ufffd;Td\ufffd\ufffdg\ufffdY\ufffdU\ufffd\ufffd\ufffd'\ufffd\ufffdI8\ufffd@F\ufffd*\ufffd	\ufffd8$\ufffdI\ufffd\ufffd+A2((\ufffd+y\ufffd8O\ufffd\ufffd\u03cbW\ufffd\ufffd\u0217E\ufffd\ufffd
{\u0562\ufffdb\ufffdW\ufffd"@\ufffd}@\ufffdC\u05cc\ufffdt\ufffde\ufffdY\ufffd\ufffdgv\ufffd\u0588\ufffd\ufffd\ufffdH\ufffd\ufffd\ufffdo\ufffdfE`\ufffdea\ufffd<o\ufffdV\ufffd	\ufffdF\ufffdC\ufffd\ufffdk2\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd* ]v%\ub166L\ufffdy|\ufffdKJ\ufffd\ufffd\ufffd3\ufffd\ufffdP\ufffdnW\ufffd(\ufffd\ufffd<\ufffdyiBVO\ufffd\ufffdh\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffd\ufffdq'\ufffd9["\ufffd<c-\ufffd\ufffd\ufffd\ufffd\ufffdp\ufffd\ufffd\ufffd\ufffd!p\ufffd\ufffdw5\ufffd\u03d4\ufffdr\ufffd)\ufffd\U001018ae^.,\ufffd8L\ufffd\ufffd\ufffdo\ufffd\ufffd\ufffd\ufffd\u049br\ufffd7\ufffd\ufffd\u0236\u01eb\ufffd.\ufffd@P\ufffdp\ufffd\ufffd\ufffd"\ufffd\ufffdX\ufffdSI\ufffd3\ufffd\ufffd\ufffd\ufffdI\ufffd\ufffd\ufffd\ufffdk\ufffdTGm\ufffd\ufffd\ufffdW\ufffd\ufffd\ufffd\ufffdVb\ufffdu6\ufffd\ufffdG\u0784\ufffd\ufffd\ufffd\ufffd`]O\ufffd\ufffd\ufffd\ufffdZQ\ufffd\ufffd\ufffd&'l\ufffdT\ufffdR&"N\ufffd!\ufffdv\ufffdG{\ufffd%\ufffd\ufffd\ufffd^}T\ufffd1\ufffdv\ufffd:\u0208\ufffd\\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd(\ufffdIW\ufffdf\ufffd\ufffd*\ufffd\u06ae\ufffd
 \ufffd\u0283u\ufffd\ufffd*\ufffd\ufffd\ufffd\ufffdlg\ufffd\ufffdw\W\ufffdd?\ufffd'\ufffd~\ufffd|S6\ufffd|\ufffd\ufffd\u0256)\u0779\ufffd\ufffdE< \ufffdK\ufffd\ufffd7\ufffd\ufffd\ufffdb\ufffd%\ufffd\ufffd\ufffd\ufffdJ\ufffd\\ufffd*\D\ufffd)\ufffd\ufffde\ufffd
+\ufffd\ufffd2\ufffdG\ufffd\ufffd2\u045bBjx$Z-\ufffd\ufffd\ufffd\ufffdaV#s\ufffd/\ufffdh"\ufffd\ufffd\ufffdK6WZ,\ufffd\u0273\ufffd\ufffd\ufffd\ufffdL\ufffd9\ufffd0\ufffd~G\ufffd"~4\ufffd\ufffd5"[\ufffd\ufffd\ufffdK\ufffd\ufffd4\ufffdh\ufffd\ufffd\ufffd\ufffd\ufffdq\ufffd\ufffd\ufffd\u0255\ufffd\ufffd\ufffd\ufffd\ufffdF\ufffd\ufffd\ufffda\ufffd\ufffd1U\ufffd_\ufffd\ufffdK\ufffd\u012a\ufffd)\ufffd\ufffdP\ufffd\ufffd
?Q\u03a29\ufffd\u0792"\ufffd\ufffdz\u072ei$\ufffd\ufffd5I\ufffd\ufffd0\ufffd]x\ufffd\ufffdo\u072c\ufffd\ufffdUJ&\ufffd]\ufffd:QS{%K\ufffd\ufffdz\ufffd\ufffd\ufffd\ufffd<\ufffd\ufffd~m\ub30b\ufffd/7\ufffd\u01a3\ufffd\ufffdi_\ufffd\ufffdy
+I<G\ufffddk~\ufffd\ufffdx\ufffdk\ufffd\u06d2\ufffd\ufffd1\ufffd\ufffde'w\ufffd7\ufffd\ufffd\ufffd\u06f2\ufffd\ufffd\ufffd\ufffd\ufffdU\ufffdy\ufffd\ufffd\u02aa\ufffd\ufffd\ufffd\ufffd\\ufffd\ufffd\ufffdP\ufffd\ufffdx\ufffd\ufffdV\ufffd\ufffd\ufffdnL"\ufffdN6t\ufffd\u0126>\ufffdgbN\ufffd_\ufffd\ufffd\ufffd\ufffd\ufffd4\ufffd!/\ufffde%\ufffd\ufffd\ufffd\ufffdO;m\ufffd\ufffd\ufffdht\ufffd\ufffdWv6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd[\ufffd\ufffd\ufffdi\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdyF\ufffdy\ufffd\ufffd\ufffd4\u0294a\ufffdtV\ufffd]\ufffd\ufffd
au\ufffd\ufffd\ufffd
\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffdYm3rM\ufffd/q{\ufffd~\ufffd\ufffdtj\ufffd\ufffdD\ufffd\ufffd
\ufffd7\ufffd\ufffd\ufffdf\ufffdi\ufffd\ufffd\ufffd\u0277
\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd \ufffd.=[\ufffdn`4\ufffd\ufffd\ufffdqSh\ufffd\ufffdB\ufffdr\ufffdx_\ufffd5w\u0510\ufffd%\ufffd\ufffdn\ufffdQ\ufffd\ufffd\ufffd\ufffd~x\ufffd'G[	\ufffd`+qb\ufffd]Q\ufffd2\u0538\ufffdi\ufffd=UGn\ufffd~\ufffd\ufffd\ufffd\u068bJ\ufffd(\ufffd\ufffd\ufffd\ufffd\ufffdA\u076a\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffdE\ufffd7\ufffd\ufffdK\ufffdz
+M\ufffd\ufffd]\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd!}\ufffd\ufffdj\ufffdnh-C\u0566_\ufffd\u9b7a\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffda\ufffd\u066d\ufffdD\ufffdfr\ufffdj\ufffd6\ufffd$-\ufffd4\ufffdn\ufffdU\ufffdZ\ufffdF)\ufffdZp\ufffd\ufffdux'\ufffd@\ufffd\ufffd]U\ufffd\ufffd\ufffd/\ufffd\u0673\ufffd\u06ff\ufffd3\ufffdUg`iU\ufffd}\ufffd\ufffd\u06b0\ufffd\ufffdU\ufffdL\ufffd\ufffdW\ufffd\ufffd\ufffdu\ufffd\ufffd\ufffd\ufffd+\ufffd\ufffdS\ufffd\ufffdU\ufffd\ufffd[\ufffd\ufffd\ufffd;u\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdXJP\ufffdv\ufffd\ufffdO\ufffd\u0140\ufffd\ufffd{$\ufffdK
 F\ufffd,q\ufffdQ\ufffd\ufffd\ufffdr\ufffdu\ufffd\ufffdH\ufffd\ufffd.\ufffd\ufffd\ufffd}i\ufffdm\ufffd\ufffd\ufffd\ufffdfZ\ufffdh~a\ufffd\ufffd\ufffdt\ufffd\ufffd\ufffdM\ufffd\ufffd\ufffd\ufffdB\ufffdb0*\ufffd\ufffdiW\ufffd\ufffd\ufffdC\u4da7\ufffd\ufffd\ufffdjZ\ufffd\ufffdm\ufffd\ufffdn\ufffd\ufffd[nKfi\ufffdc\ufffd+.\ufffd&oV.\ufffd\ufffd&\u02ad\ufffd\ufffd{\ufffd\ufffd\ufffd5\ufffd_\ufffds\ufffd9\ufffdd\ufffdm\ufffd\ufffdI\ufffdA. \ufffd*s\ufffd5:	\ufffd1\ufffd\ufffd\ufffd\u016e\ufffd
m!\ufffd|f\ufffd\ufffd\ufffdl'\ufffd6#N\ufffd
+Z\ufffd\ufffd>\ufffd\ufffd\ufffd\\ufffdoM\ufffdk\ufffdCZ8\ufffd)*\ufffd\ufffd\ufffdbEE@\ufffd\ufffd(2\ufffd\ufffd\ufffd7{\ufffdI\ufffd"	$!\ufffd\ufffd0a\ufffd=+vU\ufffdZ\u0141`-x\ufffdE\ufffd\ufffd\ufffdJU\u01fa
+\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd~\ufffd7\ufffd<N\ufffdz\ufffd\ufffd\ufffdQ\ufffd\ufffd\ufffdT\ufffd!w\ufffd\ufffd\ufffd\ufffd\ufffdB,\ufffd\ufffdC)k\ufffd\ufffd\ufffdE\ufffd\ufffd+\ufffd\ufffd+\ufffd\ufffd#\ufffd6\ufffd-\ufffd\ufffd)\ufffd\ufffdp\ufffd*\u3a9dA \ufffd\ufffd\ufffd\ufffd\ufffdAo\ufffd\ufffd\ufffdc\ufffd\ufffdc~\ufffd\_xb\ufffd5\u04fc\ufffd\ufffd\ufffd\ufffd\ufffdz\ufffdg\ufffdQ\ufffd\ufffdu\ufffd}\u07b5\ufffdz\ufffdGe\ufffd\ufffdX~	>T\ufffdS\ufffds\ufffd\ufffdV6\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdi\ufffd1=\ufffd2J\u7706Jh\ufffd@ U\ufffd\ufffd\ufffdu\ufffd;\ufffd\ufffd7!\ufffd0
+\u07fd\ufffd\\ufffd\u91ae\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd%-;\ufffd\ufffd=.\ufffd\ufffde\ufffd/\ufffdT\ufffd7D\ufffd$v\ufffd{\ufffd.\u02ab\ufffd\ufffd\ufffd\ufffd\ufffd|\ufffdZ\ufffd\u046e\ufffdmcD\u05b2+-C\ufffd\ufffdu\ufffd_\ufffd\ufffd{\ufffd>\ufffd1\ufffdH\ufffd1]\ufffd"\ufffdD^n\ufffdR\ufffd
\ufffd\u067a\ufffd:\ufffd\ufffd\ufffd\ufffdE3\ufffd[\ufffdh9\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd7\ufffdTJOW+3v\ufffd�\ufffdLimc
@\ufffd6'\ufffd\ufffd[\ufffdc\ufffd`\u01e68v\ufffd\ufffd\ufffd!\ufffd\ufffd\ufffdb\ufffdR\ufffd{\ufffd\ufffd1\ufffd_\u04f5\ufffd\ufffdu\ufffd\ufffd\ufffdo\ufffd\ufffdP\ufffd\ufffdE\ufffd2\ufffd\ufffd\@;4"\ufffdmO\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdm{\ufffd\ufffd\u07faE1\ufffdd\ufffd\ufffdA\ufffd\ufffd\ufffd\ufffd}C=W\ufffd\ufffd\ufffd\ufffdB\ufffd}[3']\PJ\ufffdG5\ufffdV\ufffd\ufffdmnY\ufffdGXy\ufffdahd\ufffd'J\ufffd[U~	v\ufffd\ufffdW\ufffd\u06c5Wo\ufffd]\ufffdWn\ufffdG\ufffdn\ufffdR\ufffd\ufffd\ufffd9H7\ufffd\u0468\ufffd\ufffdAu\ufffd1\ufffdv\ufffd\ufffd\ufffd\ufffd\ufffdZm\ufffd]lU\ufffdr\ufffd\ufffdT\ufffdV\ufffdA
+sj\ufffd6l\ufffdhm,M\ufffd\ufffdy\ufffd4A\ufffd\ufffd\ufffd\ufffd*0\ufffd\ufffd\ufffd\ufffdv\ufffdJ\ufffd\ufffdR\ufffd?\ufffd\ufffd \ufffd\u0134>\ufffd\ufffd\ufffd2C!*\ufffd#\ufffdq0\ufffdMJ!:\u014f\ufffdC\ufffd\ufffd\ufffd\ufffd\ufffdR\ufffd|\ufffdd\ufffdF\ufffda?\ufffd\ufffd2\ufffd\u0742\ufffdc\ufffdh3\ufffd\ufffddB\ufffd\ufffdz\ufffd\ufffdSI\ufffdt?\ufffd%\ufffdL\ufffd\ufffdm\ufffd\ufffdF[\ufffdA\ufffd\ufffdx\ufffdY\ufffdG\ufffd\u048f0m\ufffd;GY1\u0171h%[\ufffds\u1312@\ufffd9\ufffd
q\ufffd\ufffd_8\ufffdG>r\ufffd\ufffdW\ufffdn\ufffd\ufffd\ufffd)jod\ufffdE\ufffd\ufffdz\ufffdC\ufffd.q\ufffdJviN&\ufffdIf\ufffd\ufffd\ufffd8b\ufffd\ufffdg\ufffd
+\ufffd
\ufffdv|\ufffds\ufffd\ufffdd\ufffd\ufffd%:uT\ufffd\ufffd\ufffdf\ufffd\ufffd\ufffd\ufffd\ufffd&\ufffdL\ufffd\ufffd0\ufffd\ufffd\ufffd~\ufffdp\ufffd\ufffd\ufffd\ufffd.(R\ufffd\ufffd\ufffdU
+;_)\ufffdw%$\ufffd\ufffd/\ufffd\ufffd\ufffdt#\ufffd
+~\ufffd#\ufffdu`u[\ufffdw\ufffd.\ufffd\ufffdq\ufffds\uf4ff\ufffd\ufffd\ufffd\ufffdY\ufffd\ufffd_\ufffd-\ufffd\ufffd\ufffd\ufffd*'\u0333\u0269\ufffd\ufffdk/\ufffd\ufffd\ufffd)2*
i\ufffd9\ufffd\ufffd$\ufffd7fU\ufffdz\ufffdfl\ufffd\ufffd\ufffdc\ufffd9}\ufffd]\ufffd\ufffd,\ud20fWYC\ufffdI\ufffd\ufffd\ufffdkS\ufffd-\ufffd\ufffdt\ufffdy7>\ufffdT!\ufffd\ufffd\ufffd\ufffd<v\ufffd`tF\ufffdW\ufffdV\ufffd\ufffd"\ufffd)\ufffd\ufffd'\ufffd\ufffd\ufffd\ufffdU\ufffd\ufffd\ufffd!\ufffd\ufffd<\ufffd\ufffd\ufffd^\ufffd\ufffdD\ufffdV\ufffd\ufffd"_W\ufffd\ufffd\ud1d6\ufffd\ufffd6!\ufffd{\ufffd9JJ\ufffdj\ufffd\ufffdi_U\ufffd(\ud67d\ufffdc4*j\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd\ufffd\ufffd26\ufffd\ufffd\ufffd\ufffd\ufffdK\u0772\ufffd\ufffd	m\ufffd&c<kQ\ufffd\ufffdJln\ufffd'\ufffdI\ufffdy\ufffdT>\ufffd\ufffd\u04e3h\ufffd\ufffd\ufffd\ufffd'\ufffd..+\ufffdupC\ufffd6\ufffd&@j\ufffd5\ufffdt\ufffd\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd0\ufffd\ufffd\ufffd=\ufffd\ufffdI\ufffd\u02c2\u0116\ufffd\ufffd\ufffd\ufffd
+\ufffd</\ufffd\ufffdB\u0f72Y%\ufffdV(\ufffd\ufffdq/\u0726,\u01d7	\ufffd9(B\ufffd\ufffd0j\ufffdtI4	\ufffdS:\ufffdq\ufffd\ufffd\u0519\ufffd1\ufffd\ufffdK\ufffdh^\ufffd\ufffdChhC\ufffd\ufffdF\ufffd\ufffd\ufffd\ufffd\ufffd( \ufffd|\ufffd|y\ufffd0%o:TA\ufffdB\ufffdQ\ufffd\ufffdyPI\\ufffd;hV\u0293\ufffd\ufffd\ufffd2J
+\u0125[\ufffdQ\ufffdr\ufffd\ufffd_k`\ufffd\ufffd9h\ufffd\ufffd "?7\ufffd<18\ufffd\ufffd\ufffd\ufffd\ufffd~\ufffd\ufffd\ufffd\u0429\ufffd
t]Z*7\u05a1\ufffd^\ufffd\ufffd%A\ufffd\u01cc#\ufffd\ufffd\ufffd7L{Lu\ufffd7\ufffd7]\u010cY	L\ufffd\ufffdL\ufffd;
+\ufffdi\ufffd\WkI\ufffd\ufffdS\ufffd\ufffd\ufffd\ufffdy!KC:\ufffd31hZ\ufffdPf:\ufffd\u07c4\ufffd\ufffd\ufffd0\ufffd\ufffdC\ufffd>C\ufffd{\u07b6$tR:(\u03eduO\ufffd\ufffdR4\ufffd\ufffd\ufffd\ufffd$=\ufffd\ufffdjl\ufffd\ufffd\ufffd\ufffduq\ufffd1?\u05e4\ufffd\ufffd9\ufffd\ufffdS\ufffdi|c\ufffd\ufffdq\ufffdF!\ufffd_z^\ufffdS\ufffd\ufffdK}\ufffd\ufffd`\ufffdd\ufffd%D\ufffdT	\ufffdwV\ufffd>\ufffd;\ufffd<\ufffd'\ufffdV=\ufffd(\ufffd5H\ufffd%j\ufffd\ufffd\ufffdWM\ufffd\ufffdV\ufffd#\ufffd\ufffd9\ufffdY\ufffdD2\ufffd\ufffd\u0593\ufffd\ufffdp~\ufffd\ufffd\ufffd\ufffd\ufffd~J\ufffd\ufffd}\ufffdD\ufffd]\ufffdgN\ufffdS\ufffds\ufffdjJm\ufffdn-\ufffd>,v\ufffdg&S\ufffdL\ufffdl\ufffd#\ufffd\ufffd\ufffd\ufffd\ufffd>\ufffd\ufffd\ufffd^\ufffdi\ufffd\ufffd\ufffd8\ufffd\ufffd\u029e\ufffd\ufffd%\ufffd\ufffd4'\ufffd\ufffdR\ufffd\ufffdJD\ufffd\ufffdh\ufffdRN0hB\ufffdA0\ufffd(r\ufffd0K+\ufffda\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdM\ufffd\ufffdY\ufffd\ufffd|"\ufffdE\ufffdG\ufffd\ufffd\ufffd\ufffdE_R^\ufffdv\ufffd\ufffd\ufffd4\ufffd/\ufffd?\ufffd\ufffdm[\u02e8\ufffdy\ufffdN`\ufffdK/5[\ufffd7\ufffd1\ufffd\ufffd\ufffd[G\ufffd\u0612'\ufffd '\ufffd\u94efR\ufffdG\ufffd\ufffdhq\uab41\ufffd]\ufffd\ufffd>\ufffd\ufffd\ufffdiI\ufffd\ufffdX\ufffd
+5\ufffd'\ufffd\\ufffdGB\ufffd	\ufffd\ufffd\u0107\ufffd\ufffd\ufffd\ufffdd\ufffd^u\ufffd\ufffdx\ufffd+\ufffd\ufffd\ufffd[\ufffd^\ufffd\ufffd%e\ufffd\ufffd	\ufffd\u05aa\ufffdp\ufffd\ufffdxE\ufffd\ufffd
+\ufffd \ufffd6\ufffd%!It\ufffd\u07a8@\ufffd\u04be#%\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd:\ufffd\ufffd*\ufffdh$r\ufffd\ufffd7\u05e9\ufffd\u05c1\ufffd55\ufffd\u05c8\ufffd\ufffd\u0551'I\ufffd+6\ufffd\ufffd*\u042ew\u0230\ufffd\ufffd%U\ufffd#\ufffd\ufffdzD\ufffd+J\ufffdt\ufffd\ufffd \ufffdB\ufffda\ufffdU\u0615	6\ufffd\ufffd\ufffd\ufffd}\ufffd\ufffduO\ufffdr\ufffd\ufffd7\ufffd\ufffdd\ufffd\ufffd\ufffd\ufffdP\ufffd\ufffd\ufffd\ufffd\ufffdCu}FEu\ufffda7\ufffdRV\ufffd"KS\ufffd\ufffd\ufffd\ufffdT\ufffd\ufffd\ufffd20E\ufffd\ufffd\ufffdN\ufffd{\ufffd\ufffd^\ufffd\ufffdlk\ufffd\ufffd\u0195$vW\ufffd\ufffd(\ufffd,\ufffdF7\ufffd\ufffdb\u02e2�\ufffd\ufffdO\ufffd\ufffd\ufffdy\ufffd\ufffd\ufffd\ufffd<"_\ufffd\ufffd)\ufffd\ufffd\ufffd.k\ufffdh\ufffd\ufffd\ufffd[n \ufffd9W\ufffd?g\ufffd\ufffd\u06887\ufffd\ufffdy\u0219\ufffd*\ufffd\ufffd\ufffd\ufffd\u04fc\ufffduA@ \ufffdOp\ufffd\ufffdI\ufffdR\ufffd\ufffdrP\ufffd(\ufffd$e[i<\ufffdH\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd/\ufffd\\ufffdt\ufffd/\ufffd\ufffdG\ufffdinQ\ufffd\ufffda\ufffd@\ufffd\ufffdq\ufffdI\ufffda\ufffd{\ufffdY\u0292\ufffd]\ufffd\ufffde\ufffd\ufffd?D\ufffd\ufffd98\u07d9\ufffd\ufffd\ufffd\ufffdy\ufffd\ufffddx,\ufffd8\ufffd?\ufffd\ufffd\ufffd\ufffdPe\ufffd1\ufffdN\ufffdW\ufffd\ufffdwA\ufffdi\ufffdN,\ufffdB\ufffd\ufffd=\ufffd%P\ufffdK\ufffd\ufffd\ufffd\ufffd~\ufffd\u0488\ufffdG\ufffd!O\u02bd\ufffd\ufffdR=e\ufffd"!\ufffd]:\ufffd:B\ufffdI\ufffd\\ufffd\ufffdMJ1\ufffdj\ufffdG\ufffdK)b'xL"W?D\G\ufffd\u051dC\ufffd\ufffd{\ufffd\ufffd\ufffdA\ufffdA
?u#U\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdUJ\ufffd\ufffd\ufffd\ufffd\u01f9\ufffd	H{\ufffdF[\ufffd5h\ufffd\ufffd\ufffd[N6\ufffd\ufffd){((\ufffd\ufffd%\ufffd\ufffd>
 \ufffdV\ufffdY\ufffdR
+n\ufffd\ufffd#\ufffd\ufffd\ufffd\ufffd(a\ufffd\ufffd\ufffd\ufffdF\ufffdq\ufffd&mq\ufffd3%\ufffd\g?\ufffd%\ufffd\u04c6\ufffd\ufffdM5\ufffd\ufffd\ufffd\ufffd\ufffd\ufffdX\ufffdD3\ufffdb$\u0281W\ufffd\ufffd \ufffd\ufffd\ufffd\ufffd\u01bf\ufffd\ufffd5&\u0354D4\ufffd�K\ufffd\ufffd\ufffdc\ufffd\ufffd\u13ca\ufffd.
+\ufffd\ufffd1Z\ufffdo
+^`\ufffd\ufffd~�`\ufffd6z	\ufffdq\ufffd\ufffd\ufffd\ufffd\ufffdaX\ufffd\ufffd\ufffd\ufffd\u01f0\ufffd)\ufffd\ufffd\u04fc\u0704'\ufffd\ufffd84\ufffdn"Db.\ufffd\ufffd\ufffd\ufffd\ufffdyC<K\ufffd\ufffd\ufffdd\ufffd\ufffd},\ufffd\ufffd{\ufffd*h\ufffd
+\u06b8\ufffdh\ufffd>\ufffd\ufffd\ufffdwMv^c\ufffd\ufffd8\ufffdI\u01bb\ufffd(~\ufffd\ufffdj?\ufffd\ufffd\ufffd
+e\ufffdo\ufffd\ufffdy\ufffd\ufffdl/\ufffd\ufffdDl5\ufffd\ufffd\ufffd\ufffd\ufffd\u017b\u05e8\ufffdp\ufffdy1\ufffd\ufffd\ufffd\u0723\u0735\ufffd\ufffd\ufffd\ufffd\ufffd^004\ufffd{\ufffd\ufffd\ufffd\ufffd\ufffd.\ufffd\ufffd%C\ufffdA2\ufffd\ufffd2\ufffdd\ufffdWu\ufffd\ufffd\ufffd\ufffd\ufffdQ\ufffd>\ufffdo\ufffdkL<\ufffd\ufffd\ufffd\ufffd\ufffd\ufffd5.\u017f\u0220i\ufffdf\ufffd\ufffdfh\ufffd7S

<TRUNCATED>

[42/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGClient.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGClient.m b/sdks/ios/UGAPI/UGClient.m
deleted file mode 100755
index 9d6407a..0000000
--- a/sdks/ios/UGAPI/UGClient.m
+++ /dev/null
@@ -1,1252 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGClient.h"
-#import "UGHTTPManager.h"
-#import "SBJson.h"
-#import "UGMultiStepAction.h"
-#import "SSKeychain.h"
-
-NSString *g_deviceUUID = nil;
-
-@implementation UGClient
-{
-    // the delegate for asynch callbacks
-    id m_delegate;
-    
-    // the mutex to protect the delegate variable
-    NSRecursiveLock *m_delegateLock;
-    
-    // a growing array of UGHTTPManager instances. See
-    // "HTTPMANAGER POOLING" further down in this file.
-    NSMutableArray *m_httpManagerPool;
-    
-    // the base URL for the service
-    NSString *m_baseURL;
-    
-    // the appID for the specific app
-    NSString *m_appID;
-    
-    // the appID for the specific app
-    NSString *m_orgID;
-    
-    // the cached auth token
-    UGUser *m_loggedInUser;
-    
-    // the auth code
-    NSString *m_auth;
-    
-    // the list of currently pending multi-step actions
-    NSMutableArray *m_pendingMultiStepActions;
-    
-    // logging state
-    BOOL m_bLogging;
-}
-
-/************************** ACCESSORS *******************************/
-/************************** ACCESSORS *******************************/
-/************************** ACCESSORS *******************************/
-+(NSString *) version
-{
-    return @"0.1.1";
-}
-
--(NSString *)getAccessToken
-{
-    return m_auth;
-}
-
--(UGUser *)getLoggedInUser
-{
-    return m_loggedInUser;
-}
-
--(id) getDelegate
-{
-    return m_delegate;
-}
-
-/******************************* INIT *************************************/
-/******************************* INIT *************************************/
-/******************************* INIT *************************************/
--(id)init
-{
-    // you are not allowed to init without an organization id and application id
-    // you can't init with [UGClient new]. You must call
-    // [[UGClient alloc] initWithOrganizationId: <your UG org id> withApplicationId:<your UG app id>]
-    assert(0); 
-    return nil;
-}
-
--(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID
-{
-    self = [super init];
-    if ( self )
-    {
-        m_delegate = nil;
-        m_httpManagerPool = [NSMutableArray new];
-        m_delegateLock = [NSRecursiveLock new];
-        m_appID = applicationID;
-        m_orgID = organizationID;
-        m_baseURL = @"http://api.usergrid.com";
-        m_pendingMultiStepActions = [NSMutableArray new];
-        m_loggedInUser = nil;
-        m_bLogging = NO;
-    }
-    return self;
-}
-
--(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID baseURL:(NSString *)baseURL
-{
-    self = [super init];
-    if ( self )
-    {
-        m_delegate = nil;
-        m_httpManagerPool = [NSMutableArray new];
-        m_delegateLock = [NSRecursiveLock new];
-        m_appID = applicationID;
-        m_orgID = organizationID;
-        m_baseURL = baseURL;
-    }
-    return self;
-}
-
--(BOOL) setDelegate:(id)delegate
-{
-    // first off, clear any pending transactions
-    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
-    {
-        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
-        
-        // it's safe to call cancel at all times.
-        [mgr cancel];
-    }
-    
-    // nil is a valid answer. It means we're synchronous now.
-    if ( delegate == nil )
-    {
-        [m_delegateLock lock];
-        m_delegate = nil;
-        [m_delegateLock unlock];
-        return YES;
-    }
-    
-    // if it's not nil, it has to have the delegation function
-    if ( ![delegate respondsToSelector:@selector(ugClientResponse:)] )
-    {
-        return NO;
-    }
-    
-    // if we're here, it means the delegate is valid
-    [m_delegateLock lock];
-    m_delegate = delegate;
-    [m_delegateLock unlock];
-    return YES;
-}
-
-/************************* HTTPMANAGER POOLING *******************************/
-/************************* HTTPMANAGER POOLING *******************************/
-/************************* HTTPMANAGER POOLING *******************************/
-
-// any given instance of UGHTTPManager can only manage one transaction at a time,
-// but we want the client to be able to have as many going at once as he likes. 
-// so we have a pool of UGHTTPManagers as needed.
--(UGHTTPManager *)getHTTPManager;
-{
-    // find the first unused HTTPManager
-    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
-    {
-        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
-        if ( [mgr isAvailable] )
-        {
-            // tag this guy as available
-            [mgr setAvailable:NO];
-            
-            // return him
-            return mgr;
-        }
-    }
-    
-    // if we're here, we didn't find any available managers
-    // so we'll need to make a new one
-    UGHTTPManager *newMgr = [UGHTTPManager new];
-    
-    // mark it as in-use (we're about to return it)
-    [newMgr setAvailable:NO];
-    
-    // tell it the auth to use
-    [newMgr setAuth:m_auth];
-    
-    // add it to the array
-    [m_httpManagerPool addObject:newMgr];
-    
-    // return it
-    return newMgr;
-}
-
--(void)releaseHTTPManager:(UGHTTPManager *)toRelease
-{
-    [toRelease setAvailable:YES];
-}
-
--(void)setAuth:(NSString *)auth
-{
-    // note the auth for ourselves
-    m_auth = auth;
-    
-    // update all our managers
-    for ( int i=0 ; i<[m_httpManagerPool count] ; i++ )
-    {
-        UGHTTPManager *mgr = [m_httpManagerPool objectAtIndex:i];
-        [mgr setAuth:m_auth];
-    }
-}
-
-/************************* GENERAL WORKHORSES *******************************/
-/************************* GENERAL WORKHORSES *******************************/
-/************************* GENERAL WORKHORSES *******************************/
-// url: the URL to hit
-// op: a kUGHTTP constant. Example: kUGHTTPPost
-// opData: The data to send along with the operation. Can be nil
--(UGClientResponse *)httpTransaction:(NSString *)url op:(int)op opData:(NSString *)opData
-{
-    // get an http manager to do this transaction
-    UGHTTPManager *mgr = [self getHTTPManager];
-    
-    if ( m_delegate )
-    {
-        if ( m_bLogging )
-        {
-            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>");
-            NSLog(@"Asynch outgoing call: '%@'", url);
-        }
-        
-        // asynch transaction
-        int transactionID = [mgr asyncTransaction:url operation:op operationData:opData delegate:self];
-        
-        if ( m_bLogging )
-        {
-            NSLog(@"Transaction ID:%d", transactionID);
-            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\n\n");
-        }
-        
-        if ( transactionID == -1 )
-        {
-            if ( m_bLogging )
-            {
-                NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
-                NSLog(@"Response: ERROR: %@", [mgr getLastError]);
-                NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
-            }
-            
-            // there was an immediate failure in the transaction
-            UGClientResponse *response = [UGClientResponse new];
-            [response setTransactionID:-1];
-            [response setTransactionState:kUGClientResponseFailure];
-            [response setResponse:[mgr getLastError]];
-            [response setRawResponse:nil];
-            return response;
-        }
-        else 
-        {
-            // the transaction is in progress and pending
-            UGClientResponse *response = [UGClientResponse new];
-            [response setTransactionID:transactionID];
-            [response setTransactionState:kUGClientResponsePending];
-            [response setResponse:nil];
-            [response setRawResponse:nil];
-            return response;
-        }
-    }
-    else 
-    {
-        if ( m_bLogging )
-        {
-            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>");
-            NSLog(@"Synch outgoing call: '%@'", url);
-            NSLog(@">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\n\n");
-        }
-        
-        // synch transaction
-        NSString *result = [mgr syncTransaction:url operation:op operationData:opData];
-        
-        if ( m_bLogging )
-        {
-            NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
-            if ( result )
-            {
-                NSLog(@"Response:\n%@", result);
-            }
-            else
-            {
-                NSLog(@"Response: ERROR: %@", [mgr getLastError]);
-            }
-            NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
-        }
-        
-        // since we're doing a synch transaction, we are now done with this manager.
-        [self releaseHTTPManager:mgr];
-        
-        if ( result )
-        {
-            // got a valid result
-            UGClientResponse *response = [self createResponse:-1 jsonStr:result];
-            return response;
-        }
-        else 
-        {
-            // there was an error. Note the failure state, set the response to 
-            // be the error string
-            UGClientResponse *response = [UGClientResponse new];
-            [response setTransactionID:-1];
-            [response setTransactionState:kUGClientResponseFailure];
-            [response setResponse:[mgr getLastError]];
-            [response setRawResponse:nil];
-            return response;
-        }
-    }
-}
-
--(UGClientResponse *)createResponse:(int)transactionID jsonStr:(NSString *)jsonStr
-{
-    UGClientResponse *response = [UGClientResponse new];
-    
-    // set the raw response and transaction id
-    [response setRawResponse:jsonStr];
-    [response setTransactionID:transactionID];
-    
-    // parse the json
-    SBJsonParser *parser = [SBJsonParser new];
-    NSError *error;
-    id result = [parser objectWithString:jsonStr error:&error];
-    
-    if ( result )
-    {
-        // first off, if the result is NOT an NSDictionary, something went wrong.
-        // there should never be an array response
-        if ( ![result isKindOfClass:[NSDictionary class]] )
-        {
-            [response setTransactionState:kUGClientResponseFailure];
-            [response setResponse:@"Internal error: Response parsed to something other than NSDictionary"];
-            return response;
-        }
-        
-        // it successfully parsed. Though the result might still be an error.
-        // it could be the server returning an error in perfectly formated json.
-        NSString *err = [result valueForKey:@"error"];
-        if ( err )
-        {
-            // there was an error. See if there's a more detailed description.
-            // if there is, we'll use that. If not, we'll use the error value
-            // itself.
-            NSString *errDesc = [result valueForKey:@"error_description"];
-            NSString *toReport = errDesc;
-            if ( !toReport ) toReport = err;
-            
-            [response setTransactionState:kUGClientResponseFailure];
-            [response setResponse:toReport];
-            return response;
-        }
-        
-        // if we're here we have a good auth. make note of it
-        NSString *auth = [result valueForKey:@"access_token"];
-        if ( auth )
-        {
-            [self setAuth: auth];
-            
-            // if there's an access token, there might be a user
-            NSDictionary *dict = [result objectForKey:@"user"];
-            if ( dict )
-            {
-                // get the fields for the user
-                m_loggedInUser = [UGUser new];
-                [m_loggedInUser setUsername:[dict valueForKey:@"username"]];
-                [m_loggedInUser setUuid:[dict valueForKey:@"uuid"]];
-                [m_loggedInUser setEmail:[dict valueForKey:@"email"]];
-                [m_loggedInUser setPicture:[dict valueForKey:@"picture"]];
-            }
-        }
-        
-        [response setTransactionState:kUGClientResponseSuccess];
-        [response setResponse:result];
-        return response;
-    }
-    else
-    {
-        // there was an error during json parsing. 
-        [response setTransactionState:kUGClientResponseFailure];
-        [response setResponse:[error localizedDescription]];
-        return response;
-    }
-}
-
-// basic URL assembly functions. For convenience
--(NSMutableString *)createURL:(NSString *)append1
-{
-    NSMutableString *ret = [NSMutableString new];
-    [ret appendFormat:@"%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1];
-    return ret;
-}
-
--(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2
-{
-    NSMutableString *ret = [NSMutableString new];
-    [ret appendFormat:@"%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2];
-    return ret;
-}
-
--(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3
-{
-    NSMutableString *ret = [NSMutableString new];
-    [ret appendFormat:@"%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3];
-    return ret;
-}
-
--(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3 append4:(NSString *)append4
-{
-    NSMutableString *ret = [NSMutableString new];
-    [ret appendFormat:@"%@/%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3, append4];
-    return ret;
-}
-
--(NSMutableString *)createURL:(NSString *)append1 append2:(NSString *)append2 append3:(NSString *)append3 append4:(NSString *)append4 append5:(NSString *)append5
-{
-    NSMutableString *ret = [NSMutableString new];
-    [ret appendFormat:@"%@/%@/%@/%@/%@/%@/%@/%@", m_baseURL, m_orgID, m_appID, append1, append2, append3, append4, append5];
-    return ret;
-}
-
--(void)appendQueryToURL:(NSMutableString *)url query:(UGQuery *)query
-{
-    if ( query )
-    {
-        [url appendFormat:@"%@", [query getURLAppend]];
-    }
-}
-
--(NSString *)createJSON:(NSDictionary *)data
-{
-    NSString *ret = [self createJSON:data error:nil];
-
-    // the only way for ret to be nil here is for an internal
-    // function to have a bug.
-    assert(ret);
-    return ret;
-}
-
--(NSString *)createJSON:(NSDictionary *)data error:(NSString **)error
-{
-    SBJsonWriter *writer = [SBJsonWriter new];
-    NSError *jsonError;
-    NSString *jsonStr = [writer stringWithObject:data error:&jsonError];
-
-    if ( jsonStr )
-    {
-        return jsonStr;
-    }
-    
-    // if we're here, there was an assembly error
-    if ( error )
-    {
-        *error = [jsonError localizedDescription];
-    }
-    return nil;
-}
-
-/************************** UGHTTPMANAGER DELEGATES *******************************/
-/************************** UGHTTPMANAGER DELEGATES *******************************/
-/************************** UGHTTPMANAGER DELEGATES *******************************/
--(void)httpManagerError:(UGHTTPManager *)manager error:(NSString *)error
-{
-    // prep an error response
-    UGClientResponse *response = [UGClientResponse new];
-    [response setTransactionID:[manager getTransactionID]];
-    [response setTransactionState:kUGClientResponseFailure];
-    [response setResponse:error];
-    [response setRawResponse:nil];
-
-    if ( m_bLogging )
-    {
-        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
-        NSLog(@"Response: ERROR: %@", error);
-        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
-    }
-    
-    // fire it off. Wrap in mutex locks to ensure we don't get 
-    // race conditions that cause us to fire it off to Mr. Nil.
-    [m_delegateLock lock];
-    if ( m_delegate )
-    {
-        [m_delegate performSelector:@selector(ugClientResponse:) withObject:response];
-    }
-    [m_delegateLock unlock];
-    
-    // now that the callback is complete, it's safe to release this manager
-    [self releaseHTTPManager:manager];
-}
-
--(void)httpManagerResponse:(UGHTTPManager *)manager response:(NSString *)response
-{
-    if ( m_bLogging )
-    {
-        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<");
-        NSLog(@"Response (Transaction ID %d):\n%@", [manager getTransactionID], response);
-        NSLog(@"<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\n");
-    }
-    
-    // form up the response
-    UGClientResponse *ugResponse = [self createResponse:[manager getTransactionID] jsonStr:response];
-    
-    // if this is part of a multi-step call, we press on.
-    for ( int i=0 ; i<[m_pendingMultiStepActions count] ; i++ )
-    {
-        UGMultiStepAction *action = [m_pendingMultiStepActions objectAtIndex:i];
-        if ( [action transactionID] == [ugResponse transactionID] )
-        {
-            // multi-step call. Fire off the action.
-            ugResponse = [self doMultiStepAction:action mostRecentResponse:ugResponse];
-            if ( ![action reportToClient] )
-            {
-                // the action is still pending. We do not report this
-                // to the user. We're done with the httpmanager we were using,
-                // though. 
-                [self releaseHTTPManager:manager];
-                return;
-            }
-            
-            // when the action is complete, we want to immediately break
-            // from this loop, then fall through to the normal reporting
-            // to the user. 
-            break;
-        }
-    }
-        
-    // fire it off
-    [m_delegateLock lock];
-    if ( m_delegate )
-    {
-        [m_delegate performSelector:@selector(ugClientResponse:) withObject:ugResponse];
-    }
-    [m_delegateLock unlock];   
-    
-    // now that the callback is complete, it's safe to release this manager
-    [self releaseHTTPManager:manager];
-}
-
-// multi-step follow-up function
--(UGClientResponse *)multiStepAction: (UGMultiStepAction *)action
-{
-    // different behavior if synch or asynch
-    if ( m_delegate )
-    {
-        // asynch. Fire it off and we're done
-        return [self doMultiStepAction:action mostRecentResponse:nil];
-    }
-    else 
-    {
-        // synchronous. keep calling until it finished or fails
-        UGClientResponse *response = nil;
-        do 
-        {
-            response = [self doMultiStepAction:action mostRecentResponse:response];
-            if ( [action reportToClient] )
-            {
-                // done
-                return response;
-            }
-        } while ([response transactionState] == kUGClientResponseSuccess);
-        
-        // if we're here, there was an error
-        return response;
-    }
-}
-
--(UGClientResponse *)doMultiStepAction: (UGMultiStepAction *)action mostRecentResponse:(UGClientResponse *)mostRecentResponse
-{
-    // clear the pending array of this object
-    [m_pendingMultiStepActions removeObject:action];
-
-    // assume we aren't reporting to the client
-    [action setReportToClient:NO];
-    
-    if ( mostRecentResponse )
-    {
-        // we don't care about pending responses
-        if ( [mostRecentResponse transactionState] == kUGClientResponsePending )
-        {
-            // put ourselves back in the list
-            [m_pendingMultiStepActions addObject:action];
-            return mostRecentResponse;
-        }
-        
-        // any failure is an immediate game ender
-        if ( [mostRecentResponse transactionState] == kUGClientResponseFailure )
-        {
-            [mostRecentResponse setTransactionID:[action transactionID]];
-            return mostRecentResponse;
-        }
-    }
-    
-    // if mostRecentRespons is nil, that means it's the first call to initiate 
-    // the chain. So we continue on with processing.
-
-    // so either we are reacting to a success or we are starting off the chain
-    UGClientResponse *result = nil; 
-    if ( [action nextAction] == kMultiStepCreateActivity )
-    {
-        // create the activity
-        result = [self createActivity:[action activity]];
-        
-        // advance ourselves to the next step
-        [action setNextAction:kMultiStepPostActivity];
-    }
-    else if ( [action nextAction] == kMultiStepCreateGroupActivity )
-    {
-        // create the activity
-        result = [self createActivity:[action activity]];
-        
-        // advance ourselves to the next step
-        [action setNextAction:kMultiStepPostGroupActivity];
-    }
-    else if ( [action nextAction] == kMultiStepPostActivity )
-    {
-        // we just created an activity, now we need to associate it with a user.
-        // first, we'll need the activity's uuid
-        NSDictionary *dict = [mostRecentResponse response]; // dictionary for the response
-        NSArray *entities = [dict objectForKey:@"entities"]; // array for the entities
-        NSDictionary *activity = [entities objectAtIndex:0]; // dict for the activity
-        NSString *activityUUID = [activity valueForKey:@"uuid"]; // and finally the uuid string
-        
-        // fire off the next step
-        result = [self postUserActivityByUUID:[action userID] activity:activityUUID];
-        
-        // advance the action
-        [action setNextAction:kMultiStepCleanup];
-    }
-    else if ( [action nextAction] == kMultiStepPostGroupActivity )
-    {
-        // we just created an activity, now we need to associate it with a user.
-        // first, we'll need the activity's uuid
-        NSDictionary *dict = [mostRecentResponse response]; // dictionary for the response
-        NSArray *entities = [dict objectForKey:@"entities"]; // array for the entities
-        NSDictionary *activity = [entities objectAtIndex:0]; // dict for the activity
-        NSString *activityUUID = [activity valueForKey:@"uuid"]; // and finally the uuid string
-        
-        // fire off the next step
-        result = [self postGroupActivityByUUID:[action groupID] activity:activityUUID];
-        
-        // advance the action
-        [action setNextAction:kMultiStepCleanup];
-    }
-    else if ( [action nextAction] == kMultiStepCleanup )
-    {
-        // all we do in cleanup is update the transaction ID of the 
-        // response that was sent in. We do this to ensure that the transaction
-        // id is constant across the entire transaction
-        result = mostRecentResponse;
-        [result setTransactionID:[action outwardTransactionID]];
-        [action setReportToClient:YES];
-    }
-    
-    if ( !mostRecentResponse )
-    {
-        // if mostRecentResponse is nil, it means we're on the first step. That means
-        // we need to adopt a unique outward transaction ID. We'll simply use
-        // the ID given back by the first transaction in the chain. This also means
-        // we can simply return the first transaction pending response without modification. 
-        [action setOutwardTransactionID:[result transactionID]];
-    }
-
-    // wherever we landed, if it's a pending transaction, the action needs to
-    // know that transaction ID. Also, we need to go in to the pending array
-    if ( [result transactionState] == kUGClientResponsePending )
-    {
-        [action setTransactionID:[result transactionID]];
-        [m_pendingMultiStepActions addObject:action];
-    }
-    
-    // result is now properly set up and ready to be handed to the user. 
-    return result;
-}
-
-/*************************** LOGIN / LOGOUT ****************************/
-/*************************** LOGIN / LOGOUT ****************************/
-/*************************** LOGIN / LOGOUT ****************************/
--(UGClientResponse *)logInUser: (NSString *)userName password:(NSString *)password
-{
-    return [self logIn:@"password" userKey:@"username" userValue:userName pwdKey:@"password" pwdValue:password];
-}
-
--(UGClientResponse *)logInUserWithPin: (NSString *)userName pin:(NSString *)pin
-{
-    return [self logIn:@"pin" userKey:@"username" userValue:userName pwdKey:@"pin" pwdValue:pin];
-}
-
--(UGClientResponse *)logInUserWithFacebook: (NSString *)facebookToken
-{
-    NSMutableString *url = [self createURL:@"auth/facebook"];
-    UGQuery *query = [[UGQuery alloc] init];
-    [query addURLTerm:@"fb_access_token" equals:facebookToken];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
--(UGClientResponse *)logInAdmin: (NSString *)adminUserName secret:(NSString *)adminSecret
-{
-    return [self logIn:@"client_credentials" userKey:@"client_id" userValue:adminUserName pwdKey:@"client_secret" pwdValue:adminSecret];
-}
-
--(void)logOut
-{
-    // clear out auth
-    [self setAuth: nil];
-}
-
-// general workhorse for auth logins
--(UGClientResponse *)logIn:(NSString *)grantType userKey:(NSString *)userKey userValue:(NSString *)userValue pwdKey:(NSString *)pwdKey pwdValue:(NSString *)pwdValue
-{
-    // create the URL
-    NSString *url = [self createURL:@"token"];
-    
-    // because it's read as form data, we need to escape special characters.
-    NSString *escapedUserValue = [UGHTTPManager escapeSpecials:userValue];
-    NSString *escapedPwdValue = [UGHTTPManager escapeSpecials:pwdValue];
-    
-    // create the post data. For auth functions, we don't use json,
-    // but instead use web form style data
-    NSMutableString *postData = [NSMutableString new];
-    [postData appendFormat:@"grant_type=%@&%@=%@&%@=%@", grantType, userKey, escapedUserValue, pwdKey, escapedPwdValue];
-    
-    // fire off the request
-    return [self httpTransaction:url op:kUGHTTPPostAuth opData:postData];    
-}
-/*************************** USER MANAGEMENT ***************************/
-/*************************** USER MANAGEMENT ***************************/
-/*************************** USER MANAGEMENT ***************************/
--(UGClientResponse *)addUser:(NSString *)username email:(NSString *)email name:(NSString *)name password:(NSString *)password
-{
-    // make the URL we'll be posting to
-    NSString *url = [self createURL:@"users"];
-    
-    // make the post data we'll be sending along with it.
-    NSMutableDictionary *toPost = [NSMutableDictionary new];
-    [toPost setObject:username forKey:@"username"];
-    [toPost setObject:name forKey:@"name"];
-    [toPost setObject:email forKey:@"email"];
-    [toPost setObject:password forKey:@"password"];
-    NSString *toPostStr = [self createJSON:toPost];
-    
-    // fire it off
-    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
-}
-
-// updates a user's password
--(UGClientResponse *)updateUserPassword:(NSString *)usernameOrEmail oldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword
-{
-    // make the URL we'll be posting to
-    NSString *url = [self createURL:@"users" append2:usernameOrEmail append3:@"password"];
-    
-    // make the post data we'll be sending along with it.
-    NSMutableDictionary *toPost = [NSMutableDictionary new];
-    [toPost setObject:oldPassword forKey:@"oldpassword"];
-    [toPost setObject:newPassword forKey:@"newpassword"];
-    NSString *toPostStr = [self createJSON:toPost];
-    
-    // fire it off
-    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
-}
-
--(UGClientResponse *)getGroupsForUser: (NSString *)userID;
-{
-    // make the URL, and fire off the get
-    NSString *url = [self createURL:@"users" append2:userID append3:@"groups"];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
--(UGClientResponse *)getUsers: (UGQuery *)query
-{
-    // create the URL
-    NSMutableString *url = [self createURL:@"users"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
-/************************** ACTIVITY MANAGEMENT **************************/
-/************************** ACTIVITY MANAGEMENT **************************/
-/************************** ACTIVITY MANAGEMENT **************************/
--(UGClientResponse *)createActivity: (NSDictionary *)activity
-{
-    // make the URL
-    NSString *url = [self createURL:@"activity"];
-    
-    // get the json to send.
-    // we have to json-ify a dictionary that was sent
-    // in by the client. So naturally, we can't just trust it 
-    // to work. Therefore we can't use our internal convenience 
-    // function for making the json. We go straight to SBJson, so
-    // we can identify and report any errors.
-    SBJsonWriter *writer = [SBJsonWriter new];
-    NSError *jsonError;
-    NSString *toPostStr = [writer stringWithObject:activity error:&jsonError];
-
-    if ( !toPostStr )
-    {
-        // error during json assembly
-        UGClientResponse *ret = [UGClientResponse new];
-        [ret setTransactionState:kUGClientResponseFailure];
-        [ret setTransactionID:-1];
-        [ret setResponse:[jsonError localizedDescription]];
-        [ret setRawResponse:nil];
-        return ret;
-    }
-    
-    // fire it off
-    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
-}
-
-// create an activity and post it to a user in a single step
--(UGClientResponse *)postUserActivity: (NSString *)userID activity:(NSDictionary *)activity
-{
-    // prep a multi-step action
-    UGMultiStepAction *action = [UGMultiStepAction new];
-    
-    // set it up to start the create activity / post to user chain
-    [action setNextAction:kMultiStepCreateActivity];
-    [action setUserID:userID];
-    [action setActivity:activity];
-    
-    // fire it off
-    return [self multiStepAction:action];
-}
-
--(UGClientResponse *)postUserActivityByUUID: (NSString *)userID activity:(NSString *)activityUUID
-{
-    // make the URL and fire off the post. there is no data
-    NSString *url = [self createURL:@"users" append2:userID append3:@"activities" append4:activityUUID];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
--(UGClientResponse *)postGroupActivity:(NSString *)groupID activity:(NSDictionary *)activity
-{
-    // prep a multi-step action
-    UGMultiStepAction *action = [UGMultiStepAction new];
-    
-    // set it up to start the create activity / post to user chain
-    [action setNextAction:kMultiStepCreateGroupActivity];
-    [action setGroupID:groupID];
-    [action setActivity:activity];
-    
-    // fire it off
-    return [self multiStepAction:action];    
-}
-
--(UGClientResponse *)postGroupActivityByUUID: (NSString *)groupID activity:(NSString *)activityUUID
-{
-    // make the URL and fire off the post. there is no data
-    NSString *url = [self createURL:@"groups" append2:groupID append3:@"activities" append4:activityUUID];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];    
-}
-
--(UGClientResponse *)getActivitiesForUser: (NSString *)userID query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:@"users" append2:userID append3:@"activities"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
-}
-
--(UGClientResponse *)getActivityFeedForUser: (NSString *)userID query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:@"users" append2:userID append3:@"feed"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
-}
-
--(UGClientResponse *)getActivitiesForGroup: (NSString *)groupID query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"activities"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil]; 
-}
-
--(UGClientResponse *)getActivityFeedForGroup: (NSString *)groupID query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"feed"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil]; 
-}
-
--(UGClientResponse *)removeActivity:(NSString *)activityUUID
-{
-    NSString *url = [self createURL:@"activities" append2:activityUUID];
-    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
-}
-
-/************************** GROUP MANAGEMENT **************************/
-/************************** GROUP MANAGEMENT **************************/
-/************************** GROUP MANAGEMENT **************************/
--(UGClientResponse *)createGroup:(NSString *)groupPath groupTitle:(NSString *)groupTitle
-{
-    // make the URL
-    NSString *url = [self createURL:@"groups"];
-    
-    // make the post data we'll be sending along with it.
-    NSMutableDictionary *toPost = [NSMutableDictionary new];
-    [toPost setObject:groupPath forKey:@"path"];
-    if ( groupTitle )
-    {
-        [toPost setObject:groupTitle forKey:@"title"];
-    }
-    NSString *toPostStr = [self createJSON:toPost];
-    
-    // fire it off
-    return [self httpTransaction:url op:kUGHTTPPost opData:toPostStr];
-}
-
--(UGClientResponse *)addUserToGroup:(NSString *)userID group:(NSString *)groupID
-{
-    // make the URL
-    NSString *url = [self createURL:@"groups" append2:groupID append3:@"users" append4:userID];
-    
-    // fire it off. This is a data-less POST
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
--(UGClientResponse *)removeUserFromGroup:(NSString *)userID group:(NSString *)groupID
-{
-    // this is identical to addUserToGroup, except we use the DELETE method instead of POST
-    // make the URL
-    NSString *url = [self createURL:@"groups" append2:groupID append3:@"users" append4:userID];
-    
-    // fire it off. This is a data-less POST
-    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];}
-
--(UGClientResponse *)getUsersForGroup:(NSString *)groupID query:(UGQuery *)query
-{
-    // create the URL
-    NSMutableString *url = [self createURL:@"groups" append2:groupID append3:@"users"];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
-/************************** ENTITY MANAGEMENT **************************/
-/************************** ENTITY MANAGEMENT **************************/
-/************************** ENTITY MANAGEMENT **************************/
-// jsonify the entity. If there's an error, it creates a UGClientResponse and 
-// returns it. If there's no error, it returns nil, and the outJson field and
-// the type field will be set correctly.
-// yes, it's odd to have a function return nil on success, but it's internal.
--(UGClientResponse *)validateEntity:(NSDictionary *)newEntity outJson:(NSString **)jsonStr outType:(NSString **)type
-{
-    // validation
-    NSString *error = nil;
-    
-    // the entity must exist
-    if ( !newEntity )
-    {
-        error =@"entity is nil";
-    }
-    
-    // the entity must have a "type" field
-    *type = [newEntity valueForKey:@"type"];
-    if ( !*type )
-    {
-        error = @"entity is missing a type field";
-    }
-    
-    // make sure it can parse to a json
-    SBJsonWriter *writer = [SBJsonWriter new];
-    NSError *jsonError;
-    *jsonStr = [writer stringWithObject:newEntity error:&jsonError];
-    if ( !*jsonStr )
-    {
-        error = [jsonError localizedDescription];
-    }
-    
-    // if error got set to anything, it means we failed
-    if ( error )
-    {
-        UGClientResponse *ret = [UGClientResponse new];
-        [ret setTransactionState:kUGClientResponseFailure];
-        [ret setTransactionID:-1];
-        [ret setResponse:error];
-        [ret setRawResponse:nil]; 
-        return ret;
-    }
-    
-    // if we're here, it's a good json and we're done
-    return nil;
-}
-
--(UGClientResponse *)createEntity:(NSDictionary *)newEntity
-{
-    NSString *jsonStr;
-    NSString *type;
-    UGClientResponse *errorRet = [self validateEntity:newEntity outJson:&jsonStr outType:&type];
-    if ( errorRet ) return errorRet;
-    
-    // we have a valid entity, ready to post. Make the URL
-    NSString *url = [self createURL:type];
-    
-    // post it
-    return [self httpTransaction:url op:kUGHTTPPost opData:jsonStr];
-}
-
--(UGClientResponse *)getEntities: (NSString *)type query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:type];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];    
-}
-
--(UGClientResponse *)updateEntity: (NSString *)entityID entity:(NSDictionary *)updatedEntity
-{
-    NSString *jsonStr;
-    NSString *type;
-    UGClientResponse *errorRet = [self validateEntity:updatedEntity outJson:&jsonStr outType:&type];
-    if ( errorRet ) return errorRet;
-    
-    // we have a valid entity, ready to post. Make the URL
-    NSString *url = [self createURL:type append2:entityID];
-    
-    // post it
-    return [self httpTransaction:url op:kUGHTTPPut opData:jsonStr];
-}
-
--(UGClientResponse *)removeEntity: (NSString *)type entityID:(NSString *)entityID
-{
-    // Make the URL, then fire off the delete
-    NSString *url = [self createURL:type append2:entityID];
-    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
-}
-
-
--(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType connecteeType:(NSString *)connecteeType connecteeID:(NSString *)connecteeID
-{
-    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeType append5:connecteeID];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
--(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID
-{
-    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeID];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
--(UGClientResponse *)disconnectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID
-{
-    NSString *url = [self createURL:connectorType append2:connectorID append3:connectionType append4:connecteeID];
-    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
-}
-
--(UGClientResponse *)getEntityConnections: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType query:(UGQuery *)query
-{
-    NSMutableString *url = [self createURL:connectorType append2:connectorID append3:connectionType];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
-/************************** MESSAGE MANAGEMENT **************************/
-/************************** MESSAGE MANAGEMENT **************************/
-/************************** MESSAGE MANAGEMENT **************************/
--(UGClientResponse *)postMessage: (NSString *)queuePath message:(NSDictionary *)message
-{
-    // because the NSDictionary is from the client, we can't trust it. We need 
-    // to go through full error checking
-    NSString *error;
-    NSString *jsonStr = [self createJSON:message error:&error];
-    
-    if ( !jsonStr )
-    {
-        // report the error
-        UGClientResponse *ret = [UGClientResponse new];
-        [ret setTransactionID:-1];
-        [ret setTransactionState:kUGClientResponseFailure];
-        [ret setResponse:error];
-        [ret setRawResponse:nil];
-        return ret;
-    }
-    
-    // make the path and fire it off
-    NSString *url = [self createURL:@"queues" append2:queuePath];
-    return [self httpTransaction:url op:kUGHTTPPost opData:jsonStr];
-}
-
--(UGClientResponse *)getMessages: (NSString *)queuePath query:(UGQuery *)query;
-{
-    NSMutableString *url = [self createURL:@"queues" append2:queuePath];
-    [self appendQueryToURL:url query:query];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
--(UGClientResponse *)addSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath
-{
-    NSString *url = [self createURL:@"queues" append2:queuePath append3:@"subscribers" append4:subscriberPath];
-    return [self httpTransaction:url op:kUGHTTPPost opData:nil];
-}
-
--(UGClientResponse *)removeSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath
-{
-    NSString *url = [self createURL:@"queues" append2:queuePath append3:@"subscribers" append4:subscriberPath];
-    return [self httpTransaction:url op:kUGHTTPDelete opData:nil];
-}
-
-/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
-/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
-/*************************** REMOTE PUSH NOTIFICATIONS ***************************/
-
-- (UGClientResponse *)setDevicePushToken:(NSData *)newDeviceToken forNotifier:(NSString *)notifier
-{
-    // Pull the push token string out of the device token data
-    NSString *tokenString = [[[newDeviceToken description]
-                              stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"<>"]]
-                             stringByReplacingOccurrencesOfString:@" " withString:@""];
-    
-    // Register device and push token to App Services
-    NSString *deviceId = [UGClient getUniqueDeviceID];
-    
-    // create/update device - use deviceId for App Services entity UUID
-    NSMutableDictionary *entity = [[NSMutableDictionary alloc] init];
-    [entity setObject: @"device"   forKey: @"type"];
-    [entity setObject: deviceId    forKey: @"uuid"];
-    
-    NSString *notifierKey = [notifier stringByAppendingString: @".notifier.id"];
-    [entity setObject: tokenString forKey: notifierKey];
-    
-    return [self updateEntity: deviceId entity: entity];
-}
-
-- (UGClientResponse *)pushAlert:(NSString *)message
-                      withSound:(NSString *)sound
-                             to:(NSString *)path
-                  usingNotifier:(NSString *)notifier
-{
-    NSDictionary *apsDict = [NSDictionary dictionaryWithObjectsAndKeys:
-                             message, @"alert",
-                             sound, @"sound",
-                             nil];
-    
-    NSDictionary *notifierDict = [NSDictionary dictionaryWithObjectsAndKeys:
-                                  apsDict, @"aps",
-                                  nil];
-    
-    NSDictionary *payloadsDict = [NSDictionary dictionaryWithObjectsAndKeys:
-                                  notifierDict, notifier,
-                                  nil];
-    
-    NSString *notificationsPath = [path stringByAppendingString: @"/notifications"];
-    
-    NSMutableDictionary *entity = [[NSMutableDictionary alloc] init];
-    [entity setObject: notificationsPath forKey: @"type"];
-    [entity setObject: payloadsDict      forKey: @"payloads"];
-    
-    return [self createEntity: entity];
-}
-
-
-/*************************** SERVER-SIDE STORAGE ***************************/
-/*************************** SERVER-SIDE STORAGE ***************************/
-/*************************** SERVER-SIDE STORAGE ***************************/
-+(NSString *)getUniqueDeviceID
-{
-    // cached?
-    if (g_deviceUUID) return g_deviceUUID;
-    
-    // in our keychain?
-    g_deviceUUID = [SSKeychain passwordForService:@"Usergrid" account:@"DeviceUUID"];
-    if (g_deviceUUID) return g_deviceUUID;
-
-    // in the (legacy) app defaults?
-    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
-    g_deviceUUID = [defaults valueForKey:@"UGClientDeviceUUID"];
-    
-    // if none found in storage, generate one
-    if (!g_deviceUUID) {
-    
-        if (SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"6.0")) {
-            // use identifierForVendor where possible
-            g_deviceUUID = [[[UIDevice currentDevice] identifierForVendor] UUIDString];
-        }
-        else {
-            // otherwise, create a UUID (legacy method)
-            CFUUIDRef uuidRef = CFUUIDCreate(nil);
-            CFStringRef uuidStringRef = CFUUIDCreateString(nil, uuidRef);
-            CFRelease(uuidRef);
-            g_deviceUUID = [NSString stringWithString:(__bridge NSString *)uuidStringRef];
-        }
-    }
-    
-    // store in keychain for future reference
-    [SSKeychain setPassword:g_deviceUUID forService:@"Usergrid" account:@"DeviceUUID"];
-    
-    return g_deviceUUID;
-}
-
--(UGClientResponse *)setRemoteStorage: (NSDictionary *)data
-{
-    // prep and validate the sent-in dict
-    NSString *error;
-    NSString *jsonStr = [self createJSON:data error:&error];
-    if ( !jsonStr )
-    {
-        // report the error
-        UGClientResponse *ret = [UGClientResponse new];
-        [ret setTransactionID:-1];
-        [ret setTransactionState:kUGClientResponseFailure];
-        [ret setResponse:error];
-        [ret setRawResponse:nil];
-        return ret;
-    }
-    
-    NSString *handsetUUID = [UGClient getUniqueDeviceID];
-    NSString *url = [self createURL:@"devices" append2:handsetUUID];
-    
-    // this is a put. We replace whatever was there before
-    return [self httpTransaction:url op:kUGHTTPPut opData:jsonStr];
-}
-
--(UGClientResponse *)getRemoteStorage
-{
-    NSString *handsetUUID = [UGClient getUniqueDeviceID];
-    NSString *url = [self createURL:@"devices" append2:handsetUUID];
-    return [self httpTransaction:url op:kUGHTTPGet opData:nil];
-}
-
-/***************************** OBLIQUE USAGE ******************************/
--(UGClientResponse *)apiRequest: (NSString *)url operation:(NSString *)op data:(NSString *)opData
-{
-    // work out the op to use
-    int opID = kUGHTTPGet;
-    if ( [op isEqualToString:@"GET"] ) opID = kUGHTTPGet;
-    if ( [op isEqualToString:@"POST"] ) opID = kUGHTTPPost;
-    if ( [op isEqualToString:@"POSTFORM"] ) opID = kUGHTTPPostAuth;
-    if ( [op isEqualToString:@"PUT"] ) opID = kUGHTTPPut;
-    if ( [op isEqualToString:@"DELETE"] ) opID = kUGHTTPDelete;
-    
-    // fire it off. The data, formatting, etc. is all the client's problem. 
-    // That's the way oblique functionality is. 
-    return [self httpTransaction:url op:opID opData:opData];
-}
-
-/**************************** LOGGING ************************************/
--(void)setLogging: (BOOL)loggingState
-{
-    m_bLogging = loggingState;
-}
-
-@end
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGClientDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGClientDelegate.h b/sdks/ios/UGAPI/UGClientDelegate.h
deleted file mode 100644
index 28bc996..0000000
--- a/sdks/ios/UGAPI/UGClientDelegate.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-#import "UGClientResponse.h"
-
-/******************************A NOTE ON THIS DELEGATE********************************
-Objects conform to this protocol to take advantage of the Asynchronus SDK functionality.
-The setDelegate method needs to be called on the current UGClient for this function to
-be called on an implemented delegate.
- 
-If you do not set a delegate, all functions will run synchronously, blocking
-until a response has been received or an error detected.
-*************************************************************************************/
-@protocol UGClientDelegate <NSObject>
-
-//This method is called after every request to the UserGrid API.
-//It passes in the response to the API request, and returns nothing.
--(void)ugClientResponse:(UGClientResponse *)response;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGClientResponse.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGClientResponse.h b/sdks/ios/UGAPI/UGClientResponse.h
deleted file mode 100755
index 01bc5a1..0000000
--- a/sdks/ios/UGAPI/UGClientResponse.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-
-
-// response states
-enum
-{
-    kUGClientResponseSuccess = 0,
-    kUGClientResponseFailure = 1,
-    kUGClientResponsePending = 2
-};
-
-
-@interface UGClientResponse : NSObject
-
-// this will be a unique ID for this transaction. If you have
-// multiple transactions in progress, you can keep track of them
-// with this value. Note: The transaction ID of a synchronous
-// call response is always -1.
-@property int transactionID;
-
-// this will be one of three possible valuse:
-// kUGClientResponseSuccess: The operation is complete and was successful. response will 
-//                          be valid, as will rawResponse
-//
-// kUGClientResponseFailure: There was an error with the operation. No further 
-//                          processing will be done. response will be an NSString with
-//                          a plain-text description of what went wrong. rawResponse
-//                          will be valid if the error occurred after receiving data from
-//                          the service. If it occurred before, rawResponse will be nil.
-//
-// kUGClientResponsePending: The call is being handled asynchronously and not yet complete. 
-//                          response will be nil. rawResponse will also be nil
-@property int transactionState;
-
-// This is the response. The type of this variable is dependant on the call that caused
-// this response. 
-@property id response;
-
-// This is the raw text that was returned by the server. 
-@property NSString *rawResponse;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGClientResponse.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGClientResponse.m b/sdks/ios/UGAPI/UGClientResponse.m
deleted file mode 100755
index dc49fb4..0000000
--- a/sdks/ios/UGAPI/UGClientResponse.m
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGClientResponse.h"
-
-@implementation UGClientResponse
-
-@synthesize transactionID;
-@synthesize transactionState;
-@synthesize response;
-@synthesize rawResponse;
-
--(id)init
-{
-    self = [super init];
-    if ( self )
-    {
-        transactionID = -1;
-        transactionState = -1;
-        response = nil;
-        rawResponse = nil;
-    }
-    return self;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGHTTPManager.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGHTTPManager.h b/sdks/ios/UGAPI/UGHTTPManager.h
deleted file mode 100755
index d6c1822..0000000
--- a/sdks/ios/UGAPI/UGHTTPManager.h
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-
-enum
-{
-    kUGHTTPGet = 0,
-    kUGHTTPPost = 1,
-    kUGHTTPPostAuth = 2,
-    kUGHTTPPut = 3,
-    kUGHTTPDelete = 4
-};
-
-@interface UGHTTPManager : NSObject
-
-// blocks until a response is received, or until there's an error.
-// in the event of a response, it's returned. If there's an error, 
-// the funciton returns nil and you can call getLastError to see what
-// went wrong.
--(NSString *)syncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData;
-
-// sets up the transaction asynchronously. The delegate that's sent in
-// must have the following functions: 
-//
-// -(void)httpManagerError:(UGHTTPManager *)manager error:(NSString *)error
-// -(void)httpManagerResponse:(UGHTTPManager *)manager response:(NSString *)response
-//
-// In all cases, it returns a transaction ID. A return value
-// of -1 means there was an error.
-// You can call getLastError to find out what went wrong. 
--(int)asyncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData delegate:(id)delegate;
-
-// get the current transactionID
--(int)getTransactionID;
-
-// sets the auth key
--(void)setAuth: (NSString *)auth;
-
-// cancel a pending transaction. The delegate will not be called and the results
-// will be ignored. Though the server side will still have happened.
--(void)cancel;
-
-// returns YES if this instance is available. NO if this instance is currently
-// in use as part of an asynchronous transaction.
--(BOOL)isAvailable;
-
-// sets the availability flag of this instance. This is done by UGClient
--(void)setAvailable:(BOOL)available;
-
-// a helpful utility function to make a string comform to URL
-// rules. It will escape all the special characters.
-+(NSString *)escapeSpecials:(NSString *)raw;
-
-// At all times, this will return the plain-text explanation of the last
-// thing that went wrong. It is cleared to "No Error" at the beginnign of 
-// each new transaction.
--(NSString *)getLastError;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGHTTPManager.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGHTTPManager.m b/sdks/ios/UGAPI/UGHTTPManager.m
deleted file mode 100755
index 5d62fe9..0000000
--- a/sdks/ios/UGAPI/UGHTTPManager.m
+++ /dev/null
@@ -1,328 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGHTTPManager.h"
-
-// all transaction IDs are unique across all UGHTTPManagers. 
-// this global increases every time there's an asynchronous 
-// transaction. 
-static int g_nextTransactionID = 1;  
-
-// a mutex to protect against multiple threads getting
-// IDs at the same time, and possibly getting the same ID
-// because of it
-NSRecursiveLock *g_transactionIDLock = nil;
-
-@implementation UGHTTPManager
-{
-    // data management for collecting incoming HTTP data
-    // during asynch transactions
-    NSMutableData *m_receivedData;
-    
-    // a general error string
-    NSString *m_lastError;
-    
-    // the delegate sent in to the asynch method
-    id m_delegate;
-    
-    // the transaction ID of the current (or most recent) transaction
-    int m_transactionID;
-    
-    // availability of this instance. Managed by UGClient
-    BOOL m_bAvailable;
-    
-    // mutex used to ensure the delegate is not changed
-    // in a way that would cause a race condition.
-    NSRecursiveLock *m_delegateLock;        
-    
-    // the auth key to send along to requests
-    NSString *m_auth;
-}
-
--(id)init
-{
-    self = [super init];
-    if ( self )
-    {
-        m_lastError = @"No error";
-        m_receivedData = [NSMutableData data];
-        m_bAvailable = YES;
-        m_delegateLock = [NSRecursiveLock new];
-        m_transactionID = -1;
-        m_auth = nil;
-        
-        // lazy-init the transaction lock
-        if ( !g_transactionIDLock )
-        {
-            g_transactionIDLock = [NSRecursiveLock new];
-        }
-    }
-    return self;
-}
-
--(void)setAuth: (NSString *)auth
-{
-    m_auth = auth;
-}
-
--(NSString *)getLastError
-{
-    return m_lastError;
-}
-
--(int)getNextTransactionID
-{
-    // make sure we can use this lock
-    assert(g_transactionIDLock);
-    
-    [g_transactionIDLock lock];
-    int ret = g_nextTransactionID++;
-    [g_transactionIDLock unlock];
-    
-    return ret;
-}
-
--(int)getTransactionID
-{
-    return m_transactionID;
-}
-
-
-//----------------------- SYNCHRONOUS CALLING ------------------------
--(NSString *)syncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData;
-{
-    // clear the transaction ID
-    m_transactionID = -1;
-    
-    // use the synchronous funcitonality of NSURLConnection
-    // clear the error
-    m_lastError = @"No error";
-    
-    // formulate the request
-    NSURLRequest *req = [self getRequest:url operation:op operationData:opData];
-    
-    NSURLResponse *response;
-    NSError *error;
-    NSData *resultData = [NSURLConnection sendSynchronousRequest:req returningResponse:&response error:&error];
-    
-    if ( resultData )
-    {
-        // we got results
-        NSString *resultString = [[NSString alloc] initWithData:resultData encoding:NSUTF8StringEncoding];        
-        return resultString;
-    }
-    
-    // if we're here, it means we got nil as the result
-    m_lastError = [error localizedDescription];
-    return nil;
-}
-
-//----------------------- ASYNCHRONOUS CALLING ------------------------
--(int)asyncTransaction:(NSString *)url operation:(int)op operationData:(NSString *)opData delegate:(id)delegate;
-{
-    // clear the transaction ID
-    m_transactionID = -1;
-    
-    // clear the error
-    m_lastError = @"No error";
-    
-    if ( !delegate )
-    {
-        // an asynch transaction with no delegate has no meaning
-        m_lastError = @"Delegate was nil";
-        return -1;
-    }
-    
-    // make sure the delegate responds to the various messages that
-    // are required
-    if ( ![delegate respondsToSelector:@selector(httpManagerError:error:)] )
-    {
-        m_lastError = @"Delegate does not have httpManagerError:error: method";
-        return -1;
-    }
-    if ( ![delegate respondsToSelector:@selector(httpManagerResponse:response:)] )
-    {
-        m_lastError = @"Delegate does not have httpManagerResponse:response: method";
-        return -1;
-    }
-    
-    // only once we're assured everything is right do we set the internal value
-    [m_delegateLock lock];
-    m_delegate = delegate;
-    [m_delegateLock unlock];
-    
-    // prep a transaction ID for this transaction
-    m_transactionID = [self getNextTransactionID];
-   
-    // formulate the request
-    NSURLRequest *req = [self getRequest:url operation:op operationData:opData];
-        
-    // fire it off
-    NSURLConnection *conn = [[NSURLConnection alloc] initWithRequest:req delegate:self];
-    
-    // Note failure
-    if ( !conn )
-    {
-        // failed to connect
-        m_lastError = @"Unable to initiate connection.";
-        return -1;       
-    }
-    
-    // success
-    return m_transactionID;
-}
-
--(BOOL)isAvailable
-{
-    return m_bAvailable;
-}
-
--(void)setAvailable:(BOOL)available
-{
-    m_bAvailable = available;
-}
-
--(void)cancel
-{
-    // we wrap this in a lock to ensure that the client can
-    // call it at any time. It will not cause a race condition in 
-    // any callback thread.
-    [m_delegateLock lock];
-    m_delegate = nil;
-    [m_delegateLock unlock];
-    
-    // note that we do not modify the "in use" flag. If we werei n use,
-    // we remain in use until we receive a response or error. This ensures 
-    // no confusion on any subsequent transaction. We don't want the case 
-    // where a transaction is started, then cancelled, then a new transaction begun
-    // before the first transaction's result comes in. That would lead to the second 
-    // transaction being answered with the first's reply. We avoid that possibility by
-    // simply remaining "in use" until we get the reply or error.
-}
-
-// general helper function form aking escaped-strings
-+(NSString *)escapeSpecials:(NSString *)raw;
-{
-    NSString *converted = (__bridge NSString *)CFURLCreateStringByAddingPercentEscapes(kCFAllocatorDefault, (__bridge CFStringRef)raw, nil, CFSTR(";/?:@&=$+{}<>"), kCFStringEncodingUTF8);
-    return converted;
-}
-
-// INTERNAL function for forming the request
--(NSURLRequest *)getRequest:(NSString *)url operation:(int)op operationData:(NSString *)opStr;
-{
-    // make the url
-    NSURL *nsurl = [NSURL URLWithString:url];
-        
-    NSMutableURLRequest *req = [NSMutableURLRequest new];
-    [req setURL:nsurl];
-    
-    switch ( op ) 
-    {
-        case kUGHTTPGet: [req setHTTPMethod:@"GET"]; break;
-        case kUGHTTPPost: [req setHTTPMethod:@"POST"]; break;
-        case kUGHTTPPostAuth: [req setHTTPMethod:@"POST"]; break;
-        case kUGHTTPPut: [req setHTTPMethod:@"PUT"]; break;
-        case kUGHTTPDelete: [req setHTTPMethod:@"DELETE"]; break;
-    }
-
-    // set the auth, if any is available
-    if ( m_auth )
-    {
-        NSMutableString *authStr = [NSMutableString new];
-        [authStr appendFormat:@"Bearer %@", m_auth];
-        [req setValue:authStr forHTTPHeaderField:@"Authorization"];
-    }
-
-    // if they sent an opStr, we make that the content
-    if ( opStr )
-    {
-        // prep the post data
-        NSData *opData = [opStr dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES];
-        
-        // make a string that tells the length of the post data. We'll need that for the HTTP header setup
-        NSString *opLength = [NSString stringWithFormat:@"%d", [opData length]];
-        
-        [req setValue:opLength forHTTPHeaderField:@"Content-Length"];
-        
-        // PostAuth uses form encoding. All other operations use json
-        if ( op == kUGHTTPPostAuth )
-        {
-            [req setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
-        }
-        else
-        {
-            [req setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];
-        }
-        
-        [req setHTTPBody:opData];
-    }
-    
-    // all set up and ready for use
-    return req;
-    
-}
-
-//------------------------------------------------------------------------------------------
-//-------------------------- NSURLCONNECTION DELEGATE METHODS ------------------------------
-//------------------------------------------------------------------------------------------
--(void)connection:(NSURLConnection *)connection didReceiveResponse:(NSURLResponse *)response
-{
-    // got a response. clear out the data
-    [m_receivedData setLength:0];
-}
-
--(void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data
-{
-    // got some data. Append it.
-    [m_receivedData appendData:data];
-}
-
--(void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
-{
-     // connection failed. Note the error
-    m_lastError = [error localizedDescription];
-    
-    // send the error to the delegate. We wrap this in 
-    // send the result to the delegate.
-    // wrap this in mutex locks, then check for validity of m_delegate inside.
-    // this ensures no race conditions and allows arbitrary cancellation of callbacks
-    [m_delegateLock lock];
-    if ( m_delegate )
-    {
-        [m_delegate performSelector:@selector(httpManagerError:error:) withObject:self withObject:m_lastError];
-    }
-    m_delegate = nil;
-    [m_delegateLock unlock];
-}
-
--(void)connectionDidFinishLoading:(NSURLConnection*)connection
-{
-    // all done. Let's turn it in to a string
-    NSString *resultString = [[NSString alloc] initWithData:m_receivedData encoding:NSUTF8StringEncoding];
-    
-    // send it to the delegate. See connection:didFailWithError: for an explanation
-    // of the mutex locks
-    [m_delegateLock lock];
-    if ( m_delegate )
-    {
-        [m_delegate performSelector:@selector(httpManagerResponse:response:) withObject:self withObject:resultString];   
-    }
-    m_delegate = nil;
-    [m_delegateLock unlock];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGMultiStepAction.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGMultiStepAction.h b/sdks/ios/UGAPI/UGMultiStepAction.h
deleted file mode 100755
index fbc1259..0000000
--- a/sdks/ios/UGAPI/UGMultiStepAction.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-
-// an enumeration for multi-step processes. 
-enum
-{
-    kMultiStepNone = 0,
-    kMultiStepCreateActivity = 1, // create an activity
-    kMultiStepPostActivity = 2,   // after creating an activity, post it to the user
-    kMultiStepCreateGroupActivity = 3, // create an activity
-    kMultiStepPostGroupActivity = 4,   // after creating an activity, post it to the user
-    kMultiStepCleanup = 5         // the final step of all multi-step transactions
-};
-
-// UGMultiStepAction is used internally for client actions that
-// require multiple transactions with the service. It is simple data
-// storage, used by UGClient in abstracting out multi-step transactions
-@interface UGMultiStepAction : NSObject
-
-// the transaction ID that this multistep is associated
-// with. When a transaction of this ID is complete, this is the
-// UGMultiStepAction instance ot ask what to do next
-@property int transactionID;
-
-// the next action this transaction should take
-@property int nextAction;
-
-// data necessary for subsequent steps
-@property NSString *userID; 
-@property NSString *groupID; 
-@property NSDictionary *activity; 
-
-// the transactionID that will be sent to the user.
-// This is distinct from normal transaction IDs,
-// which we use internally at each step. 
-@property int outwardTransactionID;
-
-// YES if this action should be reported to the
-// caller .No if not.
-@property BOOL reportToClient;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGMultiStepAction.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGMultiStepAction.m b/sdks/ios/UGAPI/UGMultiStepAction.m
deleted file mode 100755
index 6a1b7c7..0000000
--- a/sdks/ios/UGAPI/UGMultiStepAction.m
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGMultiStepAction.h"
-
-@implementation UGMultiStepAction
-
-@synthesize transactionID;
-@synthesize nextAction;
-@synthesize userID;
-@synthesize groupID;
-@synthesize activity;
-@synthesize outwardTransactionID;
-@synthesize reportToClient;
-
-
--(id)init
-{
-    self = [super init];
-    if ( self )
-    {
-        reportToClient = NO;
-    }
-    return self;
-}
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGQuery.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGQuery.h b/sdks/ios/UGAPI/UGQuery.h
deleted file mode 100755
index b77e0a4..0000000
--- a/sdks/ios/UGAPI/UGQuery.h
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-#import <CoreLocation/CoreLocation.h>
-
-enum
-{
-    kUGQueryOperationEquals = 0,
-    kUGQueryOperationLessThan = 1,
-    kUGQueryOperationLessThanOrEqualTo = 2,
-    kUGQueryOperationGreaterThan = 3,
-    kUGQueryOperationGreaterThanOrEqualTo = 4
-};
-
-/***************************************************************
- QUERY MANAGEMENT:
- 
- All query functions take one of these as an optional parameter
- (the client may send nil if desired). This will specify the
- limitations of the query. 
-***************************************************************/
-
-@interface UGQuery : NSObject
-
-// url terms used in UG searches. Set as you like.
-// These are convenience methods. the same effect can be done
-// by calling addURLTerm
--(void)setConsumer: (NSString *)consumer;
--(void)setLastUUID: (NSString *)lastUUID;
--(void)setTime: (long)time;
--(void)setPrev: (int)prev;
--(void)setNext: (int)next;
--(void)setLimit: (int)limit;
--(void)setPos: (NSString *)pos;
--(void)setUpdate: (BOOL)update;
--(void)setSynchronized: (BOOL)synchronized;
-
-// a general function for adding additional URL terms.
-// Note that all of the set functions above turn around and
-// call this.
--(void)addURLTerm: (NSString *)urlTerm equals:(NSString *)equals;
-
-// ql operation requirements. For each of these, you provide the term, followed 
-// by the operation (a kUGQueryOperationXXXX constant) followed by the value
-// in whatever form you have it (NSString, int, or float are supported)
-// Example: [foo addRequiredOperation: @"age" kUGQueryLessThan valueInt:27] would
-// add the term "age < 27" to the ql.
--(void)addRequiredOperation: (NSString *)term op:(int)op valueStr:(NSString *)valueStr;
--(void)addRequiredOperation: (NSString *)term op:(int)op valueInt:(int) valueInt;
-
-// adds a "contains" requirement to the query. This adds the requirement that a value
-// contain a given string. Example: [foo addRequiredContains:@"hobbies value:@"fishing"]
-// would add the term "hobbies contains 'fishing'" to the ql.
--(void)addRequiredContains: (NSString *)term value:(NSString *)value;
-
-// adds an "in" requirement to the query. This adds a requirement that a field
-// be within a certain range. Example [foo appendRequiredIn:@"age" low:16.0 high:22.0]
-// would add the term "age in 16.0,22.0" to the ql. 
-// Note that the qualifier is inclusive, meaning it is true if low <= term <= high. 
--(void)addRequiredIn:(NSString *)term low:(int)low high:(int)high;
-
-// adds a "within" requirement. This adds a constraint that the term be within a 
-// certain distance of the sent-in x,y coordinates.
--(void)addRequiredWithin:(NSString *)term latitude:(float)latitude longitude:(float)longitude distance:(float)distance;
-
-// assembles a "within" requirement with a term name, CLLocation, and distance
--(void)addRequiredWithinLocation:(NSString *)term location:(CLLocation *)location distance:(float)distance;
-
-//-------------------- Oblique usage ----------------------------
-// adds a requirement to the query. The requirements will
-// *all* be sent when the query is adopted. This is an escalating
-// list as you add them. Requirements are in UG Querty language.
-// So something like "firstname='bob'". This is one of the few places
-// where the data you give will be sent to the server almost untouched. 
-// So if you make a mistake in your query, you are likely to cause the whole
-// transaction to return an error. 
-// NOTE: This is different thant URL terms. These are query terms sent along
-// to the *single* URL term "ql". 
-// Note: This is an oblique-usage function. You will find all the ql operations
-// supported in the various addRequiredXXXX functions above. You would only use
-// this function if you already have ql strings prepared for some reason, or if
-// there are new ql format operations that are not supported by this API.
--(void)addRequirement: (NSString *)requirement;
-
-// returns the URL-ready string that detailes all specified requirements.
-// This is used internally by UGClient, you don't need to call it.
--(NSString *)getURLAppend;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGQuery.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGQuery.m b/sdks/ios/UGAPI/UGQuery.m
deleted file mode 100755
index 740ec5c..0000000
--- a/sdks/ios/UGAPI/UGQuery.m
+++ /dev/null
@@ -1,277 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGQuery.h"
-#import "UGHTTPManager.h"
-
-@implementation UGQuery
-{
-    NSMutableArray *m_requirements;
-    NSMutableString *m_urlTerms;
-}
-
--(id)init
-{
-    self = [super init];
-    if ( self )
-    {
-        m_requirements = [NSMutableArray new];
-        m_urlTerms = [NSMutableString new];
-    }
-    return self;
-}
-
--(void)setConsumer: (NSString *)consumer
-{
-    [self addURLTerm:@"consumer" equals:consumer];    
-}
-
--(void)setLastUUID: (NSString *)lastUUID
-{
-    [self addURLTerm:@"last" equals:lastUUID];    
-}
-
--(void)setTime: (long)time
-{
-    NSMutableString *str = [NSMutableString new];
-    [str appendFormat:@"%ld", time];
-    [self addURLTerm:@"time" equals:str];
-}
-
--(void)setPrev: (int)prev
-{
-    NSMutableString *str = [NSMutableString new];
-    [str appendFormat:@"%d", prev];
-    [self addURLTerm:@"prev" equals:str];
-}
-
--(void)setNext: (int)next
-{
-    NSMutableString *str = [NSMutableString new];
-    [str appendFormat:@"%d", next];
-    [self addURLTerm:@"next" equals:str];
-}
-
--(void)setLimit: (int)limit
-{
-    NSMutableString *str = [NSMutableString new];
-    [str appendFormat:@"%d", limit];
-    [self addURLTerm:@"limit" equals:str];
-}
-
--(void)setPos: (NSString *)pos
-{
-    [self addURLTerm:@"pos" equals:pos];    
-}
-
--(void)setUpdate: (BOOL)update
-{
-    if ( update )
-    {
-        [self addURLTerm:@"update" equals:@"true"];
-    }
-    else
-    {
-        [self addURLTerm:@"update" equals:@"false"];
-    }
-}
-
--(void)setSynchronized: (BOOL)synchronized
-{
-    if ( synchronized )
-    {
-        [self addURLTerm:@"synchronized" equals:@"true"];
-    }
-    else
-    {
-        [self addURLTerm:@"synchronized" equals:@"false"];
-    }
-}
-
--(void)addURLTerm: (NSString *)urlTerm equals:(NSString *)equals
-{
-    // ignore anything with a nil
-    if ( !urlTerm ) return;
-    if ( !equals ) return;
-
-    // escape the strings
-    NSString *escapedUrlTerm = [UGHTTPManager escapeSpecials:urlTerm];
-    NSString *escapedEquals = [UGHTTPManager escapeSpecials:equals];
-
-    // add it in
-    if ( [m_urlTerms length] > 0 )
-    {
-        // we already have some terms. Append an & before continuing
-        [m_urlTerms appendFormat:@"&"];
-    }
-    [m_urlTerms appendFormat:@"%@=%@", escapedUrlTerm, escapedEquals];
-}
-
--(void)addRequiredOperation: (NSString *)term op:(int)op valueStr:(NSString *)valueStr
-{
-    // disregard invalid values
-    if ( !term ) return;
-    if ( !valueStr ) return;
-    
-    NSString *opStr = [self getOpStr: op];
-    if ( !opStr ) return; // nil opStr means they sent in an invalid op code
-    
-    // assemble the requirement string
-    NSMutableString *assembled = [NSMutableString new];
-    [assembled appendFormat:@"%@ %@ '%@'", term, opStr, valueStr];
-    
-    // add it as a req
-    [self addRequirement:assembled];
-}
-
--(void)addRequiredOperation: (NSString *)term op:(int)op valueInt:(int) valueInt
-{
-    // disregard invalid values
-    if ( !term ) return;
-    
-    NSString *opStr = [self getOpStr: op];
-    if ( !opStr ) return; // nil opStr means they sent in an invalid op code
-    
-    // assemble the requirement string
-    NSMutableString *assembled = [NSMutableString new];
-    [assembled appendFormat:@"%@ %@ %d", term, opStr, valueInt];
-    
-    // add it as a req
-    [self addRequirement:assembled];
-}
-
--(void)addRequiredContains: (NSString *)term value:(NSString *)value
-{
-    // disregard invalid values
-    if ( !term ) return;
-    if ( !value ) return;
-    
-    // assemble the requirement string
-    NSMutableString *assembled = [NSMutableString new];
-    [assembled appendFormat:@"%@ contains '%@'", term, value];
-    
-    // add it as a req
-    [self addRequirement:assembled];
-}
-
--(void)addRequiredIn:(NSString *)term low:(int)low high:(int)high
-{
-    // disregard invalid values
-    if ( !term ) return;
-    
-    // assemble the requirement string
-    NSMutableString *assembled = [NSMutableString new];
-    [assembled appendFormat:@"%@ in %d,%d", term, low, high];
-    
-    // add it as a req
-    [self addRequirement:assembled];    
-}
-
--(void)addRequiredWithin:(NSString *)term latitude:(float)latitude longitude:(float)longitude distance:(float)distance;
-{
-    // disregard invalid values
-    if ( !term ) return;
-    
-    // assemble the requirement string
-    NSMutableString *assembled = [NSMutableString new];
-    [assembled appendFormat:@"%@ within %f of %f,%f", term, distance, latitude, longitude];
-    
-    // add it as a req
-    [self addRequirement:assembled];   
-}
-
--(void)addRequiredWithinLocation:(NSString *)term location:(CLLocation *)location distance:(float)distance
-{
-    [self addRequiredWithin:term latitude:location.coordinate.latitude longitude:location.coordinate.longitude distance:distance];
-}
-
--(void)addRequirement: (NSString *)requirement
-{
-    // add the URL-ready requirement to our list
-    [m_requirements addObject:requirement];
-}
-
--(NSString *)getURLAppend
-{    
-    // assemble a url append for all the requirements
-    // prep a mutable string
-    NSMutableString *ret = [NSMutableString new];
-    [ret setString:@"?"];
-  
-    // true if we've put anything in the string yet.
-    BOOL bHasContent = NO;
-    
-    // start with the ql term
-    if ( [m_requirements count] > 0 )
-    {    
-        // if we're here, there are queries
-        // assemble a single string for the ql
-        NSMutableString *ql = [NSMutableString new];
-        for ( int i=0 ; i<[m_requirements count] ; i++ )
-        {
-            if ( i>0 )
-            {
-                // connect terms
-                [ql appendFormat:@" and "];
-            }
-            [ql appendFormat:@"%@", [m_requirements objectAtIndex:i]];
-        }
-        
-        // escape it
-        NSString *escapedQL = [UGHTTPManager escapeSpecials:ql];
-        [ret appendFormat:@"ql=%@", escapedQL];
-        bHasContent = YES;
-    }
-
-    if ( [m_urlTerms length] > 0 )
-    {
-        if ( bHasContent ) 
-        {
-            [ret appendFormat:@"&%@", m_urlTerms];
-        }
-        else 
-        {
-            [ret appendFormat:@"%@", m_urlTerms];
-        }
-        bHasContent = YES;
-    }
-    
-    if ( !bHasContent )
-    {
-        // no content
-        return @"";
-    }
-    
-    // all prepared
-    return ret;
-}
-
-// Internal function
- -(NSString *)getOpStr:(int)op
-{
-    switch (op)
-    {
-        case kUGQueryOperationEquals: return @"=";
-        case kUGQueryOperationGreaterThan: return @">";
-        case kUGQueryOperationGreaterThanOrEqualTo: return @">=";
-        case kUGQueryOperationLessThan: return @"<";
-        case kUGQueryOperationLessThanOrEqualTo: return @"<=";
-    }
-    return nil;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGUser.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGUser.h b/sdks/ios/UGAPI/UGUser.h
deleted file mode 100755
index 58e3b99..0000000
--- a/sdks/ios/UGAPI/UGUser.h
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-
-@interface UGUser : NSObject
-
-@property NSString *username;
-@property NSString *email;
-@property NSString *uuid;
-@property NSString *picture;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGUser.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGUser.m b/sdks/ios/UGAPI/UGUser.m
deleted file mode 100755
index d683b6d..0000000
--- a/sdks/ios/UGAPI/UGUser.m
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGUser.h"
-
-@implementation UGUser
-
-@synthesize username;
-@synthesize email;
-@synthesize uuid;
-@synthesize picture;
-
-@end


[05/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
deleted file mode 100644
index 4006819..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
+++ /dev/null
@@ -1,381 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'roles'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'find' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query Roles.',
-        'summary' => 'Query the roles collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'roles'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'findById' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
-        'notes' => 'Find Role by uuid.',
-        'summary' => 'Find role by uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'roles'
-            ],
-            'uuid' => [
-                'description' => 'Group UUID (entity uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'create' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new Role.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new Role entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'roles'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'destroy' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete a Role entity.',
-        'summary' => 'Delete a Role entity by name or uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'roles'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'update' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update a Role entity.',
-        'summary' => 'Update a Roles entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'r'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
deleted file mode 100644
index 0f28d4d..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
+++ /dev/null
@@ -1,381 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'find' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query Users.',
-        'summary' => 'Query the users collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'findById' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
-        'notes' => 'Find User by uuid.',
-        'summary' => 'Find user by uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'uuid' => [
-                'description' => 'User UUID (entity uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'create' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new User.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new User entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'destroy' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete a User entity.',
-        'summary' => 'Delete a User entity by name or uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'update' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update a User entity.',
-        'summary' => 'Update a User entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/applications.json b/sdks/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
deleted file mode 100644
index f747154..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
+++ /dev/null
@@ -1,1262 +0,0 @@
-{
-    "basePath": "${basePath}",
-    "swaggerVersion": "1.1-SHAPSHOT.121026",
-    "apiVersion": "0.1",
-    "apis": [
-        {
-            "path": "/apps/{app_name_or_uuid}/token",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_auth_password_get",
-                    "summary": "Get app access token",
-                    "notes": "Get the app access token.  See the OAuth2 specification for details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "grant_type",
-                            "dataType": "string",
-                            "description": "Grant type",
-                            "defaultValue": "password",
-                            "allowableValues": {
-                                "values": [
-                                    "password",
-                                    "client_credentials",
-                                    "refresh_token",
-                                    "authorization_code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_secret",
-                            "dataType": "string",
-                            "description": "Client Secret (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_auth_password_post",
-                    "summary": "Get app access token",
-                    "notes": "Get the app access token.  See the OAuth2 specification for details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "grant_type",
-                            "dataType": "string",
-                            "description": "Grant type",
-                            "defaultValue": "password",
-                            "allowableValues": {
-                                "values": [
-                                    "password",
-                                    "client_credentials",
-                                    "refresh_token",
-                                    "authorization_code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "client_secret",
-                            "dataType": "string",
-                            "description": "Client Secret (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/authorize",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_authorize_get",
-                    "summary": "Authorize app client",
-                    "notes": "Authorize the app client.  See the OAuth2 specification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "response_type",
-                            "dataType": "string",
-                            "description": "Response type",
-                            "defaultValue": "token",
-                            "allowableValues": {
-                                "values": [
-                                    "token",
-                                    "code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "redirect_uri",
-                            "dataType": "string",
-                            "description": "Redirect URI",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "scope",
-                            "dataType": "string",
-                            "description": "Access Token Scope",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "state",
-                            "dataType": "string",
-                            "description": "Client State",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_authorize_post",
-                    "summary": "Authorize app client",
-                    "notes": "Authorize the app client.  See the OAuth2 specification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "response_type",
-                            "dataType": "string",
-                            "description": "Response type",
-                            "defaultValue": "token",
-                            "allowableValues": {
-                                "values": [
-                                    "token",
-                                    "code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "redirect_uri",
-                            "dataType": "string",
-                            "description": "Redirect URI",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "scope",
-                            "dataType": "string",
-                            "description": "Access Token Scope",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "state",
-                            "dataType": "string",
-                            "description": "Client State",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/credentials",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_credentials_get",
-                    "summary": "Get app client credentials",
-                    "notes": "Get the app client credentials.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_credentials_post",
-                    "summary": "Generate app client credentials",
-                    "notes": "Generate new app client credentials.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_user_json_post",
-                    "summary": "Create new app user",
-                    "notes": "Create new app user.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "User to post",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_user_form_post",
-                    "summary": "Create new app user",
-                    "notes": "Create new app user using form post parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "name",
-                            "dataType": "string",
-                            "description": "User Full Name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "User Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "User Password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/resetpw",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_users_reset_password_get",
-                    "summary": "Initiate a user password reset",
-                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_users_reset_password_form_post",
-                    "summary": "Complete a user password reset",
-                    "notes": "Complete a user password reset.  Handles form POST response.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "User Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_challenge_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Challenge Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_response_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Response Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_user_get",
-                    "summary": "Returns the app user details",
-                    "notes": "Returns the app user details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "app_user_json_put",
-                    "summary": "Updates the app user details",
-                    "notes": "Updates the app user details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "App user details",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_user_activate_get",
-                    "summary": "Activates the app user",
-                    "notes": "Activates the app user from link provided in email notification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "token",
-                            "dataType": "string",
-                            "description": "Activation Token (supplied via email)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "confirm",
-                            "dataType": "boolean",
-                            "description": "Send confirmation email",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_user_reactivate_get",
-                    "summary": "Reactivates the app user",
-                    "notes": "Request app user reactivation.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_user_feed_get",
-                    "summary": "Get app user activity feed",
-                    "notes": "Get app user activity feed.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "app_user_password_json_put",
-                    "summary": "Set app user password",
-                    "notes": "Set app user password.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Old and new password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_user_reset_password_get",
-                    "summary": "Initiate a user password reset",
-                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_user_reset_password_form_post",
-                    "summary": "Complete a user password reset",
-                    "notes": "Complete a user password reset.  Handles form POST response.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "User username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "recaptcha_challenge_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Challenge Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_response_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Response Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/{collection}",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "app_entity_get",
-                    "summary": "Query an app collection",
-                    "notes": "Query an app collection.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "collection",
-                            "dataType": "string",
-                            "description": "collection name (entity type)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "ql",
-                            "dataType": "string",
-                            "description": "a query in the query language",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "reversed",
-                            "dataType": "boolean",
-                            "description": "return results in reverse order",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "start",
-                            "dataType": "string",
-                            "description": "the first entity UUID to return",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "cursor",
-                            "dataType": "string",
-                            "description": "an encoded representation of the query position for paging",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "limit",
-                            "dataType": "integer",
-                            "description": "an encoded representation of the query position for paging",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "filter",
-                            "dataType": "integer",
-                            "description": "a condition to filter on",
-                            "required": false,
-                            "allowMultiple": true,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "app_entity_json_post",
-                    "summary": "Create new app entity",
-                    "notes": "Create new app entity.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "collection",
-                            "dataType": "string",
-                            "description": "collection name (entity type)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "User to post",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/apps/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}",
-            "description": "Applications",
-            "operations": [
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "app_entity_put",
-                    "summary": "Update an app entity",
-                    "notes": "Update an app entity in a collection.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "collection",
-                            "dataType": "string",
-                            "description": "collection name (entity type)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "entity_name_or_uuid",
-                            "dataType": "string",
-                            "description": "entity name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "User to post",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "DELETE",
-                    "nickname": "app_entity_delete",
-                    "summary": "Delete an app entity",
-                    "notes": "Delete an app entity.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "app name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "collection",
-                            "dataType": "string",
-                            "description": "collection name (entity type)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "entity_name_or_uuid",
-                            "dataType": "string",
-                            "description": "entity name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        }
-    ],
-    "models": {
-        "response": {
-            "properties": {
-                "id": {
-                    "type": "long"
-                },
-                "name": {
-                    "type": "string"
-                }
-            },
-            "id": "response"
-        }
-    }
-}
\ No newline at end of file


[45/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
Moving older SDKs to a difference location and updating main README to link to new SDK locations.


Project: http://git-wip-us.apache.org/repos/asf/usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/usergrid/commit/867060fa
Tree: http://git-wip-us.apache.org/repos/asf/usergrid/tree/867060fa
Diff: http://git-wip-us.apache.org/repos/asf/usergrid/diff/867060fa

Branch: refs/heads/master
Commit: 867060fa7c868f9306112acabc8a32c9bb8c0136
Parents: 9943e4b
Author: Michael Russo <mr...@apigee.com>
Authored: Fri Sep 2 10:39:11 2016 -0700
Committer: Michael Russo <mr...@apigee.com>
Committed: Fri Sep 2 10:39:11 2016 -0700

----------------------------------------------------------------------
 README.md                                       |    2 +-
 sdks/ios/.gitignore                             |    9 -
 sdks/ios/.travis.yml                            |    7 -
 sdks/ios/Default-568h@2x.png                    |  Bin 18594 -> 0 bytes
 sdks/ios/LICENSE                                |  202 -
 sdks/ios/Nukefile                               |   46 -
 sdks/ios/README.md                              |   80 -
 sdks/ios/UGAPI/SBJson/NSObject+SBJson.h         |   79 -
 sdks/ios/UGAPI/SBJson/NSObject+SBJson.m         |   72 -
 sdks/ios/UGAPI/SBJson/SBJson.h                  |   84 -
 sdks/ios/UGAPI/SBJson/SBJsonParser.h            |  101 -
 sdks/ios/UGAPI/SBJson/SBJsonParser.m            |  100 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamParser.h      |  161 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamParser.m      |  255 -
 .../SBJson/SBJsonStreamParserAccumulator.h      |   37 -
 .../SBJson/SBJsonStreamParserAccumulator.m      |   47 -
 .../UGAPI/SBJson/SBJsonStreamParserAdapter.h    |  148 -
 .../UGAPI/SBJson/SBJsonStreamParserAdapter.m    |  164 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.h |   83 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.m |  355 --
 sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.h      |  195 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.m      |  374 --
 .../SBJson/SBJsonStreamWriterAccumulator.h      |   36 -
 .../SBJson/SBJsonStreamWriterAccumulator.m      |   52 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.h |   69 -
 sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.m |  139 -
 sdks/ios/UGAPI/SBJson/SBJsonTokeniser.h         |   67 -
 sdks/ios/UGAPI/SBJson/SBJsonTokeniser.m         |  453 --
 sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.h        |   58 -
 sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.m        |  141 -
 sdks/ios/UGAPI/SBJson/SBJsonWriter.h            |  117 -
 sdks/ios/UGAPI/SBJson/SBJsonWriter.m            |  112 -
 sdks/ios/UGAPI/SSKeychain.h                     |  357 --
 sdks/ios/UGAPI/SSKeychain.m                     |  262 -
 sdks/ios/UGAPI/UGActivity.h                     |   64 -
 sdks/ios/UGAPI/UGActivity.m                     |  263 -
 sdks/ios/UGAPI/UGClient.h                       |  328 --
 sdks/ios/UGAPI/UGClient.m                       | 1252 -----
 sdks/ios/UGAPI/UGClientDelegate.h               |   35 -
 sdks/ios/UGAPI/UGClientResponse.h               |   59 -
 sdks/ios/UGAPI/UGClientResponse.m               |   40 -
 sdks/ios/UGAPI/UGHTTPManager.h                  |   74 -
 sdks/ios/UGAPI/UGHTTPManager.m                  |  328 --
 sdks/ios/UGAPI/UGMultiStepAction.h              |   58 -
 sdks/ios/UGAPI/UGMultiStepAction.m              |   40 -
 sdks/ios/UGAPI/UGQuery.h                        |  104 -
 sdks/ios/UGAPI/UGQuery.m                        |  277 --
 sdks/ios/UGAPI/UGUser.h                         |   27 -
 sdks/ios/UGAPI/UGUser.m                         |   27 -
 sdks/ios/UGAPI/v2/UGConnection.h                |  289 --
 sdks/ios/UGAPI/v2/UGConnection.m                |  938 ----
 sdks/ios/UGAPI/v2/UGHTTPClient.h                |   45 -
 sdks/ios/UGAPI/v2/UGHTTPClient.m                |  161 -
 sdks/ios/UGAPI/v2/UGHTTPHelpers.h               |   40 -
 sdks/ios/UGAPI/v2/UGHTTPHelpers.m               |  162 -
 sdks/ios/UGAPI/v2/UGHTTPResult.h                |   34 -
 sdks/ios/UGAPI/v2/UGHTTPResult.m                |   46 -
 sdks/ios/UGAPIApp.xcodeproj/project.pbxproj     |  653 ---
 .../contents.xcworkspacedata                    |    7 -
 sdks/ios/UGAPIApp/UGAPIApp-Info.plist           |   49 -
 sdks/ios/UGAPIApp/UGAPIApp-Prefix.pch           |   31 -
 sdks/ios/UGAPIApp/UGAppAppDelegate.h            |   25 -
 sdks/ios/UGAPIApp/UGAppAppDelegate.m            |  139 -
 sdks/ios/UGAPIApp/UGAppViewController.h         |   22 -
 sdks/ios/UGAPIApp/UGAppViewController.m         |   47 -
 sdks/ios/UGAPIApp/en.lproj/InfoPlist.strings    |    2 -
 .../en.lproj/MainStoryboard_iPad.storyboard     |   27 -
 .../en.lproj/MainStoryboard_iPhone.storyboard   |   27 -
 sdks/ios/UGAPIApp/main.m                        |   27 -
 sdks/ios/UGAPIAppTests/UGAPIAppTests-Info.plist |   22 -
 sdks/ios/UGAPIAppTests/UGAPIAppTests.h          |   22 -
 sdks/ios/UGAPIAppTests/UGAPIAppTests.m          |   41 -
 .../UGAPIAppTests/en.lproj/InfoPlist.strings    |    2 -
 sdks/ios/changelog.md                           |   11 -
 .../Books/books.xcodeproj/project.pbxproj       |  342 --
 .../samples/Books/books/AddBookViewController.h |   41 -
 .../samples/Books/books/AddBookViewController.m |  169 -
 sdks/ios/samples/Books/books/AppDelegate.h      |   43 -
 sdks/ios/samples/Books/books/AppDelegate.m      |   43 -
 .../samples/Books/books/BooksViewController.h   |   41 -
 .../samples/Books/books/BooksViewController.m   |  154 -
 .../ios/samples/Books/books/Default-568h@2x.png |  Bin 18594 -> 0 bytes
 sdks/ios/samples/Books/books/Default.png        |  Bin 6540 -> 0 bytes
 sdks/ios/samples/Books/books/Default@2x.png     |  Bin 16107 -> 0 bytes
 .../Books/books/UGSignInViewController.h        |   23 -
 .../Books/books/UGSignInViewController.m        |  184 -
 sdks/ios/samples/Books/books/books-Info.plist   |   63 -
 sdks/ios/samples/Books/books/books-Prefix.pch   |   31 -
 .../Books/books/en.lproj/InfoPlist.strings      |   21 -
 sdks/ios/samples/Books/books/main.m             |   32 -
 .../Browser/browser.xcodeproj/project.pbxproj   |  487 --
 .../samples/Browser/browser/Default-568h@2x.png |  Bin 18594 -> 0 bytes
 sdks/ios/samples/Browser/browser/Default.png    |  Bin 6540 -> 0 bytes
 sdks/ios/samples/Browser/browser/Default@2x.png |  Bin 16107 -> 0 bytes
 .../ios/samples/Browser/browser/UGAppDelegate.h |   24 -
 .../ios/samples/Browser/browser/UGAppDelegate.m |   39 -
 .../Browser/browser/UGAppViewController.h       |   27 -
 .../Browser/browser/UGAppViewController.m       |  143 -
 .../browser/UGCollectionViewController.h        |   23 -
 .../browser/UGCollectionViewController.m        |  115 -
 .../Browser/browser/UGEntityViewController.h    |   22 -
 .../Browser/browser/UGEntityViewController.m    |   86 -
 .../Browser/browser/UGSignInViewController.h    |   24 -
 .../Browser/browser/UGSignInViewController.m    |  185 -
 .../Browser/browser/UGTextViewController.h      |   23 -
 .../Browser/browser/UGTextViewController.m      |   43 -
 .../samples/Browser/browser/browser-Info.plist  |   63 -
 .../samples/Browser/browser/browser-Prefix.pch  |   14 -
 .../Browser/browser/en.lproj/InfoPlist.strings  |    2 -
 sdks/ios/samples/Browser/browser/main.m         |   30 -
 sdks/ios/samples/parties/Icon.ai                | 4620 ------------------
 .../parties/parties.xcodeproj/project.pbxproj   |  481 --
 sdks/ios/samples/parties/parties/AppDelegate.h  |   26 -
 sdks/ios/samples/parties/parties/AppDelegate.m  |   73 -
 .../samples/parties/parties/Default-568h@2x.png |  Bin 18594 -> 0 bytes
 sdks/ios/samples/parties/parties/Default.png    |  Bin 6540 -> 0 bytes
 sdks/ios/samples/parties/parties/Default@2x.png |  Bin 16107 -> 0 bytes
 sdks/ios/samples/parties/parties/Icon.png       |  Bin 7725 -> 0 bytes
 .../parties/parties/PartiesViewController.h     |   24 -
 .../parties/parties/PartiesViewController.m     |  241 -
 .../parties/parties/PartyViewController.h       |   24 -
 .../parties/parties/PartyViewController.m       |  166 -
 .../parties/parties/en.lproj/InfoPlist.strings  |    2 -
 sdks/ios/samples/parties/parties/main.m         |   35 -
 .../samples/parties/parties/parties-Info.plist  |   63 -
 .../samples/parties/parties/parties-Prefix.pch  |   15 -
 sdks/ios/test/test_client.nu                    |   50 -
 sdks/ios/test/test_connection.nu                |  119 -
 sdks/other/README.md                            |    5 +
 sdks/other/ios/.gitignore                       |    9 +
 sdks/other/ios/.travis.yml                      |    7 +
 sdks/other/ios/Default-568h@2x.png              |  Bin 0 -> 18594 bytes
 sdks/other/ios/LICENSE                          |  202 +
 sdks/other/ios/Nukefile                         |   46 +
 sdks/other/ios/README.md                        |   80 +
 sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.h   |   79 +
 sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.m   |   72 +
 sdks/other/ios/UGAPI/SBJson/SBJson.h            |   84 +
 sdks/other/ios/UGAPI/SBJson/SBJsonParser.h      |  101 +
 sdks/other/ios/UGAPI/SBJson/SBJsonParser.m      |  100 +
 .../other/ios/UGAPI/SBJson/SBJsonStreamParser.h |  161 +
 .../other/ios/UGAPI/SBJson/SBJsonStreamParser.m |  255 +
 .../SBJson/SBJsonStreamParserAccumulator.h      |   37 +
 .../SBJson/SBJsonStreamParserAccumulator.m      |   47 +
 .../UGAPI/SBJson/SBJsonStreamParserAdapter.h    |  148 +
 .../UGAPI/SBJson/SBJsonStreamParserAdapter.m    |  164 +
 .../ios/UGAPI/SBJson/SBJsonStreamParserState.h  |   83 +
 .../ios/UGAPI/SBJson/SBJsonStreamParserState.m  |  355 ++
 .../other/ios/UGAPI/SBJson/SBJsonStreamWriter.h |  195 +
 .../other/ios/UGAPI/SBJson/SBJsonStreamWriter.m |  374 ++
 .../SBJson/SBJsonStreamWriterAccumulator.h      |   36 +
 .../SBJson/SBJsonStreamWriterAccumulator.m      |   52 +
 .../ios/UGAPI/SBJson/SBJsonStreamWriterState.h  |   69 +
 .../ios/UGAPI/SBJson/SBJsonStreamWriterState.m  |  139 +
 sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.h   |   67 +
 sdks/other/ios/UGAPI/SBJson/SBJsonTokeniser.m   |  453 ++
 sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.h  |   58 +
 sdks/other/ios/UGAPI/SBJson/SBJsonUTF8Stream.m  |  141 +
 sdks/other/ios/UGAPI/SBJson/SBJsonWriter.h      |  117 +
 sdks/other/ios/UGAPI/SBJson/SBJsonWriter.m      |  112 +
 sdks/other/ios/UGAPI/SSKeychain.h               |  357 ++
 sdks/other/ios/UGAPI/SSKeychain.m               |  262 +
 sdks/other/ios/UGAPI/UGActivity.h               |   64 +
 sdks/other/ios/UGAPI/UGActivity.m               |  263 +
 sdks/other/ios/UGAPI/UGClient.h                 |  328 ++
 sdks/other/ios/UGAPI/UGClient.m                 | 1252 +++++
 sdks/other/ios/UGAPI/UGClientDelegate.h         |   35 +
 sdks/other/ios/UGAPI/UGClientResponse.h         |   59 +
 sdks/other/ios/UGAPI/UGClientResponse.m         |   40 +
 sdks/other/ios/UGAPI/UGHTTPManager.h            |   74 +
 sdks/other/ios/UGAPI/UGHTTPManager.m            |  328 ++
 sdks/other/ios/UGAPI/UGMultiStepAction.h        |   58 +
 sdks/other/ios/UGAPI/UGMultiStepAction.m        |   40 +
 sdks/other/ios/UGAPI/UGQuery.h                  |  104 +
 sdks/other/ios/UGAPI/UGQuery.m                  |  277 ++
 sdks/other/ios/UGAPI/UGUser.h                   |   27 +
 sdks/other/ios/UGAPI/UGUser.m                   |   27 +
 sdks/other/ios/UGAPI/v2/UGConnection.h          |  289 ++
 sdks/other/ios/UGAPI/v2/UGConnection.m          |  938 ++++
 sdks/other/ios/UGAPI/v2/UGHTTPClient.h          |   45 +
 sdks/other/ios/UGAPI/v2/UGHTTPClient.m          |  161 +
 sdks/other/ios/UGAPI/v2/UGHTTPHelpers.h         |   40 +
 sdks/other/ios/UGAPI/v2/UGHTTPHelpers.m         |  162 +
 sdks/other/ios/UGAPI/v2/UGHTTPResult.h          |   34 +
 sdks/other/ios/UGAPI/v2/UGHTTPResult.m          |   46 +
 .../ios/UGAPIApp.xcodeproj/project.pbxproj      |  653 +++
 .../contents.xcworkspacedata                    |    7 +
 sdks/other/ios/UGAPIApp/UGAPIApp-Info.plist     |   49 +
 sdks/other/ios/UGAPIApp/UGAPIApp-Prefix.pch     |   31 +
 sdks/other/ios/UGAPIApp/UGAppAppDelegate.h      |   25 +
 sdks/other/ios/UGAPIApp/UGAppAppDelegate.m      |  139 +
 sdks/other/ios/UGAPIApp/UGAppViewController.h   |   22 +
 sdks/other/ios/UGAPIApp/UGAppViewController.m   |   47 +
 .../ios/UGAPIApp/en.lproj/InfoPlist.strings     |    2 +
 .../en.lproj/MainStoryboard_iPad.storyboard     |   27 +
 .../en.lproj/MainStoryboard_iPhone.storyboard   |   27 +
 sdks/other/ios/UGAPIApp/main.m                  |   27 +
 .../ios/UGAPIAppTests/UGAPIAppTests-Info.plist  |   22 +
 sdks/other/ios/UGAPIAppTests/UGAPIAppTests.h    |   22 +
 sdks/other/ios/UGAPIAppTests/UGAPIAppTests.m    |   41 +
 .../UGAPIAppTests/en.lproj/InfoPlist.strings    |    2 +
 sdks/other/ios/changelog.md                     |   11 +
 .../Books/books.xcodeproj/project.pbxproj       |  342 ++
 .../samples/Books/books/AddBookViewController.h |   41 +
 .../samples/Books/books/AddBookViewController.m |  169 +
 .../other/ios/samples/Books/books/AppDelegate.h |   43 +
 .../other/ios/samples/Books/books/AppDelegate.m |   43 +
 .../samples/Books/books/BooksViewController.h   |   41 +
 .../samples/Books/books/BooksViewController.m   |  154 +
 .../ios/samples/Books/books/Default-568h@2x.png |  Bin 0 -> 18594 bytes
 sdks/other/ios/samples/Books/books/Default.png  |  Bin 0 -> 6540 bytes
 .../ios/samples/Books/books/Default@2x.png      |  Bin 0 -> 16107 bytes
 .../Books/books/UGSignInViewController.h        |   23 +
 .../Books/books/UGSignInViewController.m        |  184 +
 .../ios/samples/Books/books/books-Info.plist    |   63 +
 .../ios/samples/Books/books/books-Prefix.pch    |   31 +
 .../Books/books/en.lproj/InfoPlist.strings      |   21 +
 sdks/other/ios/samples/Books/books/main.m       |   32 +
 .../Browser/browser.xcodeproj/project.pbxproj   |  487 ++
 .../samples/Browser/browser/Default-568h@2x.png |  Bin 0 -> 18594 bytes
 .../ios/samples/Browser/browser/Default.png     |  Bin 0 -> 6540 bytes
 .../ios/samples/Browser/browser/Default@2x.png  |  Bin 0 -> 16107 bytes
 .../ios/samples/Browser/browser/UGAppDelegate.h |   24 +
 .../ios/samples/Browser/browser/UGAppDelegate.m |   39 +
 .../Browser/browser/UGAppViewController.h       |   27 +
 .../Browser/browser/UGAppViewController.m       |  143 +
 .../browser/UGCollectionViewController.h        |   23 +
 .../browser/UGCollectionViewController.m        |  115 +
 .../Browser/browser/UGEntityViewController.h    |   22 +
 .../Browser/browser/UGEntityViewController.m    |   86 +
 .../Browser/browser/UGSignInViewController.h    |   24 +
 .../Browser/browser/UGSignInViewController.m    |  185 +
 .../Browser/browser/UGTextViewController.h      |   23 +
 .../Browser/browser/UGTextViewController.m      |   43 +
 .../samples/Browser/browser/browser-Info.plist  |   63 +
 .../samples/Browser/browser/browser-Prefix.pch  |   14 +
 .../Browser/browser/en.lproj/InfoPlist.strings  |    2 +
 sdks/other/ios/samples/Browser/browser/main.m   |   30 +
 sdks/other/ios/samples/parties/Icon.ai          | 4620 ++++++++++++++++++
 .../parties/parties.xcodeproj/project.pbxproj   |  481 ++
 .../ios/samples/parties/parties/AppDelegate.h   |   26 +
 .../ios/samples/parties/parties/AppDelegate.m   |   73 +
 .../samples/parties/parties/Default-568h@2x.png |  Bin 0 -> 18594 bytes
 .../ios/samples/parties/parties/Default.png     |  Bin 0 -> 6540 bytes
 .../ios/samples/parties/parties/Default@2x.png  |  Bin 0 -> 16107 bytes
 sdks/other/ios/samples/parties/parties/Icon.png |  Bin 0 -> 7725 bytes
 .../parties/parties/PartiesViewController.h     |   24 +
 .../parties/parties/PartiesViewController.m     |  241 +
 .../parties/parties/PartyViewController.h       |   24 +
 .../parties/parties/PartyViewController.m       |  166 +
 .../parties/parties/en.lproj/InfoPlist.strings  |    2 +
 sdks/other/ios/samples/parties/parties/main.m   |   35 +
 .../samples/parties/parties/parties-Info.plist  |   63 +
 .../samples/parties/parties/parties-Prefix.pch  |   15 +
 sdks/other/ios/test/test_client.nu              |   50 +
 sdks/other/ios/test/test_connection.nu          |  119 +
 sdks/other/perl/Build.PL                        |   46 +
 sdks/other/perl/LICENSE                         |  202 +
 sdks/other/perl/MANIFEST                        |   23 +
 sdks/other/perl/Makefile.PL                     |   41 +
 sdks/other/perl/README.md                       |  341 ++
 sdks/other/perl/examples/books.pl               |   48 +
 sdks/other/perl/lib/Usergrid/Client.pm          |  492 ++
 sdks/other/perl/lib/Usergrid/Collection.pm      |  212 +
 sdks/other/perl/lib/Usergrid/Entity.pm          |   92 +
 sdks/other/perl/lib/Usergrid/Request.pm         |  249 +
 sdks/other/perl/t/01_init.t                     |   27 +
 sdks/other/perl/t/02_login.t                    |   64 +
 sdks/other/perl/t/03_update.t                   |  102 +
 sdks/other/perl/t/04_collection.t               |  104 +
 sdks/other/perl/t/05_query.t                    |  108 +
 sdks/other/perl/t/06_batch_update.t             |  107 +
 sdks/other/perl/t/07_batch_delete.t             |   87 +
 sdks/other/perl/t/08_connections.t              |   94 +
 sdks/other/perl/t/09_paging.t                   |  140 +
 sdks/other/perl/t/10_auto_paging.t              |   94 +
 sdks/other/php/LICENSE                          |  202 +
 sdks/other/php/README.md                        |  388 ++
 sdks/other/php/changelog.md                     |    0
 sdks/other/php/examples/autoloader.inc.php      |   36 +
 sdks/other/php/examples/quick_start/index.php   |   45 +
 sdks/other/php/examples/tests/Tester.php        |   80 +
 sdks/other/php/examples/tests/client_auth.php   |  101 +
 sdks/other/php/examples/tests/collection.php    |  154 +
 sdks/other/php/examples/tests/entity.php        |  114 +
 sdks/other/php/examples/tests/exceptions.php    |   45 +
 sdks/other/php/examples/tests/generic.php       |  122 +
 sdks/other/php/examples/tests/push.php          |   71 +
 sdks/other/php/examples/tests/pushtest_dev.p12  |  Bin 0 -> 3203 bytes
 sdks/other/php/examples/tests/test.php          |   56 +
 sdks/other/php/examples/tests/user.php          |  137 +
 .../php/lib/vendor/Apache/Usergrid/Client.php   |  813 +++
 .../lib/vendor/Apache/Usergrid/Collection.php   |  313 ++
 .../php/lib/vendor/Apache/Usergrid/Entity.php   |  320 ++
 .../lib/vendor/Apache/Usergrid/Exceptions.php   |   41 +
 .../lib/vendor/Apache/Usergrid/Notification.php |  103 +
 .../php/lib/vendor/Apache/Usergrid/Request.php  |  174 +
 .../php/lib/vendor/Apache/Usergrid/Response.php |   90 +
 sdks/other/php/tests/autoloader.inc.php         |   36 +
 sdks/other/php5/apache-usergrid/.gitignore      |   12 +
 .../Examples/attrubites/attributes.php          |  122 +
 .../Examples/collections/books.php              |  130 +
 .../Examples/collections/data.php               |   38 +
 .../Examples/collections/users.php              |  120 +
 .../php5/apache-usergrid/Examples/examples.md   |   17 +
 .../php5/apache-usergrid/Examples/examples.php  |  245 +
 .../Examples/management/management.php          |   91 +
 .../apache-usergrid/Examples/messages/data.php  |   17 +
 .../Examples/messages/messages.php              |   62 +
 .../Examples/notifications/data.php             |   17 +
 .../Examples/notifications/notifications.php    |   86 +
 .../Examples/notifications/notifiers.php        |   79 +
 sdks/other/php5/apache-usergrid/LICENSE         |  202 +
 sdks/other/php5/apache-usergrid/README.md       |  219 +
 sdks/other/php5/apache-usergrid/TODO.md         |    2 +
 sdks/other/php5/apache-usergrid/composer.json   |   40 +
 sdks/other/php5/apache-usergrid/composer.lock   | 1225 +++++
 sdks/other/php5/apache-usergrid/phpunit.xml     |   29 +
 .../src/Api/Exception/BadRequestException.php   |   34 +
 .../src/Api/Exception/InvalidIdException.php    |   33 +
 .../src/Api/Exception/NotFoundException.php     |   33 +
 .../src/Api/Exception/ServerErrorException.php  |   33 +
 .../src/Api/Exception/UnauthorizedException.php |   34 +
 .../src/Api/Exception/UsergridException.php     |  152 +
 .../apache-usergrid/src/Api/Filters/Boolean.php |   44 +
 .../apache-usergrid/src/Api/Filters/Date.php    |   44 +
 .../apache-usergrid/src/Api/Filters/Number.php  |   48 +
 .../apache-usergrid/src/Api/GuzzleClient.php    |   64 +
 .../src/Api/Models/Application.php              |   35 +
 .../src/Api/Models/BaseCollection.php           |  116 +
 .../src/Api/Models/Collection.php               |   37 +
 .../apache-usergrid/src/Api/Models/Device.php   |   50 +
 .../apache-usergrid/src/Api/Models/Entity.php   |   36 +
 .../apache-usergrid/src/Api/Models/Event.php    |   35 +
 .../apache-usergrid/src/Api/Models/Group.php    |   54 +
 .../src/Api/Models/GuzzleCommandTrait.php       |   59 +
 .../apache-usergrid/src/Api/Models/Notifier.php |   36 +
 .../src/Api/Models/Organization.php             |   38 +
 .../apache-usergrid/src/Api/Models/Receipt.php  |   36 +
 .../apache-usergrid/src/Api/Models/Role.php     |   54 +
 .../apache-usergrid/src/Api/Models/User.php     |   77 +
 .../apache-usergrid/src/Api/QueryAggregator.php |   61 +
 .../src/Api/ResourceIterator.php                |   69 +
 .../php5/apache-usergrid/src/Api/Usergrid.php   |  452 ++
 .../Oauth2/GrantType/AuthorizationCode.php      |   77 +
 .../Oauth2/GrantType/ClientCredentials.php      |   73 +
 .../Oauth2/GrantType/GrantTypeInterface.php     |   41 +
 .../GrantType/HWIOAuthBundleRefreshToken.php    |   62 +
 .../Oauth2/GrantType/PasswordCredentials.php    |   75 +
 .../Plugin/Oauth2/GrantType/RefreshToken.php    |   74 +
 .../src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php   |  212 +
 .../Laravel/ApacheUsergridServiceProvider.php   |  159 +
 .../src/Laravel/Facades/Usergrid.php            |   42 +
 .../src/Manifests/1.0.0/Application.php         |  979 ++++
 .../src/Manifests/1.0.0/Errors.php              |   53 +
 .../src/Manifests/1.0.0/Management.php          | 1076 ++++
 .../src/Manifests/1.0.0/Manifest.php            |   25 +
 .../src/Manifests/1.0.0/Notification.php        |  154 +
 .../src/Manifests/1.0.1/Activities.php          |   24 +
 .../src/Manifests/1.0.1/Application.php         | 1108 +++++
 .../src/Manifests/1.0.1/Assets.php              |   24 +
 .../src/Manifests/1.0.1/Custom.php              |  381 ++
 .../src/Manifests/1.0.1/Devices.php             |  465 ++
 .../src/Manifests/1.0.1/Errors.php              |   50 +
 .../src/Manifests/1.0.1/Events.php              |   24 +
 .../src/Manifests/1.0.1/Groups.php              |  486 ++
 .../src/Manifests/1.0.1/Management.php          | 1076 ++++
 .../src/Manifests/1.0.1/Manifest.php            |   24 +
 .../src/Manifests/1.0.1/Messages.php            |   19 +
 .../src/Manifests/1.0.1/Notifications.php       |  241 +
 .../src/Manifests/1.0.1/Notifiers.php           |  166 +
 .../src/Manifests/1.0.1/Receipts.php            |   24 +
 .../src/Manifests/1.0.1/Roles.php               |  381 ++
 .../src/Manifests/1.0.1/Users.php               |  381 ++
 .../Manifests/swagger-json/applications.json    | 1262 +++++
 .../src/Manifests/swagger-json/management.json  | 1905 ++++++++
 .../src/Manifests/swagger-json/resources.json   |   15 +
 .../src/Native/ConfigRepository.php             |  102 +
 .../src/Native/Facades/Usergrid.php             |  118 +
 .../src/Native/UsergridBootstrapper.php         |  150 +
 .../php5/apache-usergrid/src/config/config.php  |   53 +
 .../tests/Api/ApplicationTest.php               |   72 +
 .../apache-usergrid/tests/Api/AttributeTest.php |   59 +
 .../Api/Exception/BadRequestExceptionTest.php   |   59 +
 .../Api/Exception/InvalidIdExceptionTest.php    |   58 +
 .../Api/Exception/NotFoundExceptionTest.php     |   57 +
 .../Api/Exception/ServerErrorExceptionTest.php  |   58 +
 .../Api/Exception/UnauthorizedExceptionTest.php |   58 +
 .../tests/Api/Filters/BooleanTest.php           |   45 +
 .../tests/Api/Filters/DateTest.php              |   41 +
 .../tests/Api/ManagementTest.php                |   59 +
 .../tests/Api/QueryAggregatorTest.php           |   40 +
 .../apache-usergrid/tests/Api/UsergridTest.php  |  153 +
 .../tests/Laravel/Facades/UsergridTest.php      |   53 +
 .../php5/apache-usergrid/tests/bootstrap.php    |   61 +
 sdks/other/ruby-on-rails/Gemfile                |   19 +
 sdks/other/ruby-on-rails/LICENSE.txt            |   14 +
 sdks/other/ruby-on-rails/README.md              |  212 +
 sdks/other/ruby-on-rails/Rakefile               |   22 +
 sdks/other/ruby-on-rails/lib/extensions/hash.rb |   23 +
 .../ruby-on-rails/lib/extensions/resource.rb    |   66 +
 .../ruby-on-rails/lib/usergrid_ironhorse.rb     |   39 +
 .../lib/usergrid_ironhorse/base.rb              |  370 ++
 .../lib/usergrid_ironhorse/query.rb             |  929 ++++
 .../lib/usergrid_ironhorse/user_context.rb      |   96 +
 .../lib/usergrid_ironhorse/version.rb           |   21 +
 sdks/other/ruby-on-rails/spec/spec_helper.rb    |   93 +
 .../other/ruby-on-rails/spec/spec_settings.yaml |   20 +
 .../spec/support/active_model_lint.rb           |   33 +
 .../spec/usergrid_ironhorse/base_spec.rb        |  452 ++
 .../ruby-on-rails/usergrid_ironhorse.gemspec    |   44 +
 sdks/other/ruby/.gitignore                      |   18 +
 sdks/other/ruby/.rspec                          |    1 +
 sdks/other/ruby/.rvmrc                          |    2 +
 sdks/other/ruby/Gemfile                         |   19 +
 sdks/other/ruby/LICENSE                         |   14 +
 sdks/other/ruby/README.md                       |  268 +
 sdks/other/ruby/Rakefile                        |   22 +
 sdks/other/ruby/bin/autospec                    |   16 +
 sdks/other/ruby/bin/htmldiff                    |   16 +
 sdks/other/ruby/bin/ldiff                       |   16 +
 sdks/other/ruby/bin/restclient                  |   16 +
 sdks/other/ruby/bin/rspec                       |   16 +
 .../other/ruby/lib/usergrid/core/application.rb |   84 +
 sdks/other/ruby/lib/usergrid/core/collection.rb |  121 +
 sdks/other/ruby/lib/usergrid/core/entity.rb     |   80 +
 sdks/other/ruby/lib/usergrid/core/management.rb |   57 +
 .../ruby/lib/usergrid/core/organization.rb      |   74 +
 sdks/other/ruby/lib/usergrid/core/resource.rb   |  157 +
 sdks/other/ruby/lib/usergrid/extensions/hash.rb |   45 +
 .../ruby/lib/usergrid/extensions/response.rb    |   96 +
 sdks/other/ruby/lib/usergrid/version.rb         |   18 +
 sdks/other/ruby/lib/usergrid_iron.rb            |   43 +
 sdks/other/ruby/spec/spec_helper.rb             |   89 +
 sdks/other/ruby/spec/spec_settings.yaml         |   27 +
 .../ruby/spec/usergrid/core/application_spec.rb |  342 ++
 .../ruby/spec/usergrid/core/collection_spec.rb  |  125 +
 .../ruby/spec/usergrid/core/entity_spec.rb      |   91 +
 .../ruby/spec/usergrid/core/management_spec.rb  |   51 +
 .../spec/usergrid/core/organization_spec.rb     |  113 +
 .../ruby/spec/usergrid/core/resource_spec.rb    |   63 +
 .../ruby/spec/usergrid/extensions/hash_spec.rb  |   40 +
 sdks/other/ruby/usergrid_iron.gemspec           |   41 +
 sdks/perl/Build.PL                              |   46 -
 sdks/perl/LICENSE                               |  202 -
 sdks/perl/MANIFEST                              |   23 -
 sdks/perl/Makefile.PL                           |   41 -
 sdks/perl/README.md                             |  341 --
 sdks/perl/examples/books.pl                     |   48 -
 sdks/perl/lib/Usergrid/Client.pm                |  492 --
 sdks/perl/lib/Usergrid/Collection.pm            |  212 -
 sdks/perl/lib/Usergrid/Entity.pm                |   92 -
 sdks/perl/lib/Usergrid/Request.pm               |  249 -
 sdks/perl/t/01_init.t                           |   27 -
 sdks/perl/t/02_login.t                          |   64 -
 sdks/perl/t/03_update.t                         |  102 -
 sdks/perl/t/04_collection.t                     |  104 -
 sdks/perl/t/05_query.t                          |  108 -
 sdks/perl/t/06_batch_update.t                   |  107 -
 sdks/perl/t/07_batch_delete.t                   |   87 -
 sdks/perl/t/08_connections.t                    |   94 -
 sdks/perl/t/09_paging.t                         |  140 -
 sdks/perl/t/10_auto_paging.t                    |   94 -
 sdks/php/LICENSE                                |  202 -
 sdks/php/README.md                              |  388 --
 sdks/php/changelog.md                           |    0
 sdks/php/examples/autoloader.inc.php            |   36 -
 sdks/php/examples/quick_start/index.php         |   45 -
 sdks/php/examples/tests/Tester.php              |   80 -
 sdks/php/examples/tests/client_auth.php         |  101 -
 sdks/php/examples/tests/collection.php          |  154 -
 sdks/php/examples/tests/entity.php              |  114 -
 sdks/php/examples/tests/exceptions.php          |   45 -
 sdks/php/examples/tests/generic.php             |  122 -
 sdks/php/examples/tests/push.php                |   71 -
 sdks/php/examples/tests/pushtest_dev.p12        |  Bin 3203 -> 0 bytes
 sdks/php/examples/tests/test.php                |   56 -
 sdks/php/examples/tests/user.php                |  137 -
 sdks/php/lib/vendor/Apache/Usergrid/Client.php  |  813 ---
 .../lib/vendor/Apache/Usergrid/Collection.php   |  313 --
 sdks/php/lib/vendor/Apache/Usergrid/Entity.php  |  320 --
 .../lib/vendor/Apache/Usergrid/Exceptions.php   |   41 -
 .../lib/vendor/Apache/Usergrid/Notification.php |  103 -
 sdks/php/lib/vendor/Apache/Usergrid/Request.php |  174 -
 .../php/lib/vendor/Apache/Usergrid/Response.php |   90 -
 sdks/php/tests/autoloader.inc.php               |   36 -
 sdks/php5/apache-usergrid/.gitignore            |   12 -
 .../Examples/attrubites/attributes.php          |  122 -
 .../Examples/collections/books.php              |  130 -
 .../Examples/collections/data.php               |   38 -
 .../Examples/collections/users.php              |  120 -
 sdks/php5/apache-usergrid/Examples/examples.md  |   17 -
 sdks/php5/apache-usergrid/Examples/examples.php |  245 -
 .../Examples/management/management.php          |   91 -
 .../apache-usergrid/Examples/messages/data.php  |   17 -
 .../Examples/messages/messages.php              |   62 -
 .../Examples/notifications/data.php             |   17 -
 .../Examples/notifications/notifications.php    |   86 -
 .../Examples/notifications/notifiers.php        |   79 -
 sdks/php5/apache-usergrid/LICENSE               |  202 -
 sdks/php5/apache-usergrid/README.md             |  219 -
 sdks/php5/apache-usergrid/TODO.md               |    2 -
 sdks/php5/apache-usergrid/composer.json         |   40 -
 sdks/php5/apache-usergrid/composer.lock         | 1225 -----
 sdks/php5/apache-usergrid/phpunit.xml           |   29 -
 .../src/Api/Exception/BadRequestException.php   |   34 -
 .../src/Api/Exception/InvalidIdException.php    |   33 -
 .../src/Api/Exception/NotFoundException.php     |   33 -
 .../src/Api/Exception/ServerErrorException.php  |   33 -
 .../src/Api/Exception/UnauthorizedException.php |   34 -
 .../src/Api/Exception/UsergridException.php     |  152 -
 .../apache-usergrid/src/Api/Filters/Boolean.php |   44 -
 .../apache-usergrid/src/Api/Filters/Date.php    |   44 -
 .../apache-usergrid/src/Api/Filters/Number.php  |   48 -
 .../apache-usergrid/src/Api/GuzzleClient.php    |   64 -
 .../src/Api/Models/Application.php              |   35 -
 .../src/Api/Models/BaseCollection.php           |  116 -
 .../src/Api/Models/Collection.php               |   37 -
 .../apache-usergrid/src/Api/Models/Device.php   |   50 -
 .../apache-usergrid/src/Api/Models/Entity.php   |   36 -
 .../apache-usergrid/src/Api/Models/Event.php    |   35 -
 .../apache-usergrid/src/Api/Models/Group.php    |   54 -
 .../src/Api/Models/GuzzleCommandTrait.php       |   59 -
 .../apache-usergrid/src/Api/Models/Notifier.php |   36 -
 .../src/Api/Models/Organization.php             |   38 -
 .../apache-usergrid/src/Api/Models/Receipt.php  |   36 -
 .../apache-usergrid/src/Api/Models/Role.php     |   54 -
 .../apache-usergrid/src/Api/Models/User.php     |   77 -
 .../apache-usergrid/src/Api/QueryAggregator.php |   61 -
 .../src/Api/ResourceIterator.php                |   69 -
 sdks/php5/apache-usergrid/src/Api/Usergrid.php  |  452 --
 .../Oauth2/GrantType/AuthorizationCode.php      |   77 -
 .../Oauth2/GrantType/ClientCredentials.php      |   73 -
 .../Oauth2/GrantType/GrantTypeInterface.php     |   41 -
 .../GrantType/HWIOAuthBundleRefreshToken.php    |   62 -
 .../Oauth2/GrantType/PasswordCredentials.php    |   75 -
 .../Plugin/Oauth2/GrantType/RefreshToken.php    |   74 -
 .../src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php   |  212 -
 .../Laravel/ApacheUsergridServiceProvider.php   |  159 -
 .../src/Laravel/Facades/Usergrid.php            |   42 -
 .../src/Manifests/1.0.0/Application.php         |  979 ----
 .../src/Manifests/1.0.0/Errors.php              |   53 -
 .../src/Manifests/1.0.0/Management.php          | 1076 ----
 .../src/Manifests/1.0.0/Manifest.php            |   25 -
 .../src/Manifests/1.0.0/Notification.php        |  154 -
 .../src/Manifests/1.0.1/Activities.php          |   24 -
 .../src/Manifests/1.0.1/Application.php         | 1108 -----
 .../src/Manifests/1.0.1/Assets.php              |   24 -
 .../src/Manifests/1.0.1/Custom.php              |  381 --
 .../src/Manifests/1.0.1/Devices.php             |  465 --
 .../src/Manifests/1.0.1/Errors.php              |   50 -
 .../src/Manifests/1.0.1/Events.php              |   24 -
 .../src/Manifests/1.0.1/Groups.php              |  486 --
 .../src/Manifests/1.0.1/Management.php          | 1076 ----
 .../src/Manifests/1.0.1/Manifest.php            |   24 -
 .../src/Manifests/1.0.1/Messages.php            |   19 -
 .../src/Manifests/1.0.1/Notifications.php       |  241 -
 .../src/Manifests/1.0.1/Notifiers.php           |  166 -
 .../src/Manifests/1.0.1/Receipts.php            |   24 -
 .../src/Manifests/1.0.1/Roles.php               |  381 --
 .../src/Manifests/1.0.1/Users.php               |  381 --
 .../Manifests/swagger-json/applications.json    | 1262 -----
 .../src/Manifests/swagger-json/management.json  | 1905 --------
 .../src/Manifests/swagger-json/resources.json   |   15 -
 .../src/Native/ConfigRepository.php             |  102 -
 .../src/Native/Facades/Usergrid.php             |  118 -
 .../src/Native/UsergridBootstrapper.php         |  150 -
 sdks/php5/apache-usergrid/src/config/config.php |   53 -
 .../tests/Api/ApplicationTest.php               |   72 -
 .../apache-usergrid/tests/Api/AttributeTest.php |   59 -
 .../Api/Exception/BadRequestExceptionTest.php   |   59 -
 .../Api/Exception/InvalidIdExceptionTest.php    |   58 -
 .../Api/Exception/NotFoundExceptionTest.php     |   57 -
 .../Api/Exception/ServerErrorExceptionTest.php  |   58 -
 .../Api/Exception/UnauthorizedExceptionTest.php |   58 -
 .../tests/Api/Filters/BooleanTest.php           |   45 -
 .../tests/Api/Filters/DateTest.php              |   41 -
 .../tests/Api/ManagementTest.php                |   59 -
 .../tests/Api/QueryAggregatorTest.php           |   40 -
 .../apache-usergrid/tests/Api/UsergridTest.php  |  153 -
 .../tests/Laravel/Facades/UsergridTest.php      |   53 -
 sdks/php5/apache-usergrid/tests/bootstrap.php   |   61 -
 sdks/ruby-on-rails/Gemfile                      |   19 -
 sdks/ruby-on-rails/LICENSE.txt                  |   14 -
 sdks/ruby-on-rails/README.md                    |  212 -
 sdks/ruby-on-rails/Rakefile                     |   22 -
 sdks/ruby-on-rails/lib/extensions/hash.rb       |   23 -
 sdks/ruby-on-rails/lib/extensions/resource.rb   |   66 -
 sdks/ruby-on-rails/lib/usergrid_ironhorse.rb    |   39 -
 .../lib/usergrid_ironhorse/base.rb              |  370 --
 .../lib/usergrid_ironhorse/query.rb             |  929 ----
 .../lib/usergrid_ironhorse/user_context.rb      |   96 -
 .../lib/usergrid_ironhorse/version.rb           |   21 -
 sdks/ruby-on-rails/spec/spec_helper.rb          |   93 -
 sdks/ruby-on-rails/spec/spec_settings.yaml      |   20 -
 .../spec/support/active_model_lint.rb           |   33 -
 .../spec/usergrid_ironhorse/base_spec.rb        |  452 --
 sdks/ruby-on-rails/usergrid_ironhorse.gemspec   |   44 -
 sdks/ruby/.gitignore                            |   18 -
 sdks/ruby/.rspec                                |    1 -
 sdks/ruby/.rvmrc                                |    2 -
 sdks/ruby/Gemfile                               |   19 -
 sdks/ruby/LICENSE                               |   14 -
 sdks/ruby/README.md                             |  268 -
 sdks/ruby/Rakefile                              |   22 -
 sdks/ruby/bin/autospec                          |   16 -
 sdks/ruby/bin/htmldiff                          |   16 -
 sdks/ruby/bin/ldiff                             |   16 -
 sdks/ruby/bin/restclient                        |   16 -
 sdks/ruby/bin/rspec                             |   16 -
 sdks/ruby/lib/usergrid/core/application.rb      |   84 -
 sdks/ruby/lib/usergrid/core/collection.rb       |  121 -
 sdks/ruby/lib/usergrid/core/entity.rb           |   80 -
 sdks/ruby/lib/usergrid/core/management.rb       |   57 -
 sdks/ruby/lib/usergrid/core/organization.rb     |   74 -
 sdks/ruby/lib/usergrid/core/resource.rb         |  157 -
 sdks/ruby/lib/usergrid/extensions/hash.rb       |   45 -
 sdks/ruby/lib/usergrid/extensions/response.rb   |   96 -
 sdks/ruby/lib/usergrid/version.rb               |   18 -
 sdks/ruby/lib/usergrid_iron.rb                  |   43 -
 sdks/ruby/spec/spec_helper.rb                   |   89 -
 sdks/ruby/spec/spec_settings.yaml               |   27 -
 .../ruby/spec/usergrid/core/application_spec.rb |  342 --
 sdks/ruby/spec/usergrid/core/collection_spec.rb |  125 -
 sdks/ruby/spec/usergrid/core/entity_spec.rb     |   91 -
 sdks/ruby/spec/usergrid/core/management_spec.rb |   51 -
 .../spec/usergrid/core/organization_spec.rb     |  113 -
 sdks/ruby/spec/usergrid/core/resource_spec.rb   |   63 -
 sdks/ruby/spec/usergrid/extensions/hash_spec.rb |   40 -
 sdks/ruby/usergrid_iron.gemspec                 |   41 -
 630 files changed, 46508 insertions(+), 46503 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/README.md
----------------------------------------------------------------------
diff --git a/README.md b/README.md
index ca63047..99d5a65 100644
--- a/README.md
+++ b/README.md
@@ -18,7 +18,7 @@ Apache Usergrid provides all code necessary to build and power modern mobile app
 
 * The admin portal is a pure HTML5+JavaScript app allowing you to register developers and let them manage their apps in a multi-tenant cluster. Located under [`/portal`](portal)
 
-* SDKs for [iOS](sdks/ios), [Android](sdks/android), [HTML5/JavaScript](sdks/html5-javascript), [node.js](sdks/nodejs), [Ruby on Rails](ruby-on-rails), [pure Ruby](sdks/ruby), [PHP](sdks/php), (server-side) [Java](sdks/java), [.Net / Windows](sdks/dotnet), and [Perl](sdks/perl), located in their respective subdirectories under [`/sdks`](sdks).
+* SDKs for [Swift](https://github.com/apache/usergrid-swift), [Android](https://github.com/apache/usergrid-android), [HTML5/JavaScript](https://github.com/apache/usergrid-javascript), [node.js](https://github.com/apache/usergrid-nodejs), [Java](https://github.com/apache/usergrid-java), [.Net / Windows](https://github.com/apache/usergrid-dotnet), and [Python](https://github.com/apache/usergrid-python).
 
 * a command-line client \u201cugc\u201d allowing you to complete most maintenance tasks, as well as queries in a manner similar to the mysql or the mongo shell, located under [`/ugc`](ugc). You can install it on your machine with a simple `sudo gem install ugc`
 

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/ios/.gitignore b/sdks/ios/.gitignore
deleted file mode 100644
index 283c6e9..0000000
--- a/sdks/ios/.gitignore
+++ /dev/null
@@ -1,9 +0,0 @@
-.DS_Store
-*.swp
-*~.nib
-
-build/
-
-.xcodeproj/!*.xcodeproj/project.pbxproj
-UGAPIApp.xcodeproj/xcuserdata/*
-UGAPIApp.xcodeproj/project.xcworkspace/xcuserdata/*

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/.travis.yml
----------------------------------------------------------------------
diff --git a/sdks/ios/.travis.yml b/sdks/ios/.travis.yml
deleted file mode 100644
index 3a6a437..0000000
--- a/sdks/ios/.travis.yml
+++ /dev/null
@@ -1,7 +0,0 @@
-language: objective-c
-before_script:
- - mkdir tmp
- - cd tmp; git clone git://github.com/timburks/nu.git
- - cd nu; make; ./mininush tools/nuke install
- - cd ../..
-script: nuke test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/Default-568h@2x.png b/sdks/ios/Default-568h@2x.png
deleted file mode 100644
index 0891b7a..0000000
Binary files a/sdks/ios/Default-568h@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/ios/LICENSE b/sdks/ios/LICENSE
deleted file mode 100644
index e06d208..0000000
--- a/sdks/ios/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets "{}"
-      replaced with your own identifying information. (Don't include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same "printed page" as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright {yyyy} {name of copyright owner}
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/Nukefile
----------------------------------------------------------------------
diff --git a/sdks/ios/Nukefile b/sdks/ios/Nukefile
deleted file mode 100644
index 7879116..0000000
--- a/sdks/ios/Nukefile
+++ /dev/null
@@ -1,46 +0,0 @@
-;;
-;; Licensed to the Apache Software Foundation (ASF) under one or more
-;; contributor license agreements.  See the NOTICE file distributed with
-;; this work for additional information regarding copyright ownership.
-;; The ASF licenses this file to You under the Apache License, Version 2.0
-;; (the "License"); you may not use this file except in compliance with
-;; the License.  You may obtain a copy of the License at
-;;
-;;     http://www.apache.org/licenses/LICENSE-2.0
-;;
-;; Unless required by applicable law or agreed to in writing, software
-;; distributed under the License is distributed on an "AS IS" BASIS,
-;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-;; See the License for the specific language governing permissions and
-;; limitations under the License.
-;;
-
-;;
-;; If you've installed Nu (http://github.com/timburks/nu),
-;; then you can build the Usergrid SDK as a Mac framework
-;; by typing "nuke" in this directory. Type "nuke install"
-;; to install it in /Library/Frameworks.
-;; 
-(set @m_files (filelist "^UGAPI/.*.m$"))
-(@m_files addObjectsFromSet:(filelist "^UGAPI/SBJSON/.*.m$"))
-(@m_files addObjectsFromSet:(filelist "^UGAPI/v2/.*.m$"))
-
-(set @arch '("x86_64"))
-
-;; framework description
-(set @framework "Usergrid")
-(set @framework_identifier "com.apigee.usergrid")
-
-(set @cc "clang")
-(set @cflags "-fobjc-arc -I UGAPI -I UGAPI/SBJSON -I UGAPI/v2")
-(set @ldflags  "-framework Foundation ")
-
-(compilation-tasks)
-(framework-tasks)
-
-(task "clobber" => "clean" is
-      (SH "rm -rf #{@framework_dir}"))
-
-(task "default" => "framework")
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/README.md
----------------------------------------------------------------------
diff --git a/sdks/ios/README.md b/sdks/ios/README.md
deleted file mode 100644
index 7dd9fa3..0000000
--- a/sdks/ios/README.md
+++ /dev/null
@@ -1,80 +0,0 @@
-# iOS SDK
-
-##Version
-
-Current Version: **0.9.2**
-
-Change log:
-
-<https://github.com/apache/usergrid/blob/master/sdks/ios/changelog.md>
-
-##Overview
-This open source SDK simplifies writing iOS applications that connect to App Services (Usergrid). The repo is located here:
-
-<https://github.com/apache/usergrid/tree/master/sdks/ios>
-
-You can download the SDK as part of the Usergrid stack here:
-
-* Download as a tar.gz file: <http://usergrid.apache.org/releases/>
-
-To find out more about how to use the iOS SDK within Usergrid, see:
-
-<http://usergrid.apache.org/docs/sdks/ios-new.html>
-
-##Installing
-Once you have downloaded the SDK, add the UGAPI folder to your project by dragging and dropping it into your project. 
-
-**Note:** Make sure you check the "Copy items into destination group's folder", and also make sure the appropriate boxes are checked next to "Add to targets".
-
-##Getting started
-If you haven't done so, make sure you know your organization name and your application name. Your organization name will be the same as the username you signed up with.  
-
-Within your organization, you can have multiple application namespaces.  By default, an application named "Sandbox" has been created for you to use for testing, but you can also log into the [Admin Portal](http://apigee.com/usergrid) and create an application with any name you want.
-
-Once you have your application name, you will want to create a UGClient object like so: 
-
-	//configure the org and app
-	NSString * orgName = @"ApigeeOrg";
-	NSString * appName = @"MessageeApp";
-
-	//make new client
-	usergridClient = [[UGClient alloc]initWithOrganizationId: orgName withApplicationID: appName];
-
-Now use the usergridClient object to invoke other methods that access the API.  For example, to log a user in:
-
-	[usergridClient logInUser:username password:password];
-	UGUser *user = [usergridClient getLoggedInUser];
-
-Or, to create a user:
-
-	UGClientResponse *response = [usergridClient addUser:@"myusername" email:@"email@email.com" name:@"my name" password:@"mypassword"];
-    if (response.transactionState == 0) {
-    	//user created!
-    } 
-
-##Sample Code
-If you are ready to look at a fully functional app that uses this SDK, check out the example Apigee Messagee application. It is a twitter-type app that exercises many parts of the API including: Login / Authentication, GET and POST operations, activities (tweets), and social features such as following relationships. 
-
-The Messagee Xcode project is located here:
-
-<https://github.com/apigee/usergrid-sample-ios-messagee>
-
-##Running Tests
-
-The iOS SDK unit tests are written with Nu. You'll need to install the language itself to run the tests, and use the Nukefile to create a Usergrid.framework. For installation directions go [here](https://github.com/timburks/nu)
-
-To compile the Usergrid SDK as an Objective-C framework simple type `nuke` to build the framework and then `nuke install` to install it in the /Library/Frameworks path.
-
-To run the unit tests written for the SDK use the command `nuke test` this will run all tests.
-
-## Contributing
-We welcome your enhancements!
-
-Like [Usergrid](https://github.com/apache/usergrid/), the Usergrid iOS SDK is open source and licensed under the Apache License, Version 2.0.
-
-1. Fork it
-2. Create an issue in [JIRA](https://issues.apache.org/jira/browse/USERGRID/)
-3. Create your feature branch (`git checkout -b USERGRID-${JIRA_NUMBER}`)
-4. Commit your changes (`git commit -am '${JIRA_NUMBER} ${JIRA_TITLE}'`)
-5. Push your changes to the upstream branch (`git push origin my-new-feature`)
-6. Create new Pull Request (make sure you describe what you did and why your mod is needed)

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/NSObject+SBJson.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/NSObject+SBJson.h b/sdks/ios/UGAPI/SBJson/NSObject+SBJson.h
deleted file mode 100755
index c9eeaa5..0000000
--- a/sdks/ios/UGAPI/SBJson/NSObject+SBJson.h
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- Copyright (C) 2009 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-#pragma mark JSON Writing
-
-/// Adds JSON generation to NSObject
-@interface NSObject (NSObject_SBJsonWriting)
-
-/**
- @brief Encodes the receiver into a JSON string
- 
- Although defined as a category on NSObject it is only defined for NSArray and NSDictionary.
- 
- @return the receiver encoded in JSON, or nil on error.
- 
- @see @ref objc2json
- */
-- (NSString *)JSONRepresentation;
-
-@end
-
-
-#pragma mark JSON Parsing
-
-/// Adds JSON parsing methods to NSString
-@interface NSString (NSString_SBJsonParsing)
-
-/**
- @brief Decodes the receiver's JSON text
- 
- @return the NSDictionary or NSArray represented by the receiver, or nil on error.
- 
- @see @ref json2objc
- */
-- (id)JSONValue;
-
-@end
-
-/// Adds JSON parsing methods to NSData
-@interface NSData (NSData_SBJsonParsing)
-
-/**
- @brief Decodes the receiver's JSON data
- 
- @return the NSDictionary or NSArray represented by the receiver, or nil on error.
- 
- @see @ref json2objc
- */
-- (id)JSONValue;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/NSObject+SBJson.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/NSObject+SBJson.m b/sdks/ios/UGAPI/SBJson/NSObject+SBJson.m
deleted file mode 100755
index 62b0987..0000000
--- a/sdks/ios/UGAPI/SBJson/NSObject+SBJson.m
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- Copyright (C) 2009 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "NSObject+SBJson.h"
-#import "SBJsonWriter.h"
-#import "SBJsonParser.h"
-
-@implementation NSObject (NSObject_SBJsonWriting)
-
-- (NSString *)JSONRepresentation {
-    SBJsonWriter *writer = [[SBJsonWriter alloc] init];    
-    NSString *json = [writer stringWithObject:self];
-    if (!json)
-        NSLog(@"-JSONRepresentation failed. Error is: %@", writer.error);
-    return json;
-}
-
-@end
-
-
-
-@implementation NSString (NSString_SBJsonParsing)
-
-- (id)JSONValue {
-    SBJsonParser *parser = [[SBJsonParser alloc] init];
-    id repr = [parser objectWithString:self];
-    if (!repr)
-        NSLog(@"-JSONValue failed. Error is: %@", parser.error);
-    return repr;
-}
-
-@end
-
-
-
-@implementation NSData (NSData_SBJsonParsing)
-
-- (id)JSONValue {
-    SBJsonParser *parser = [[SBJsonParser alloc] init];
-    id repr = [parser objectWithData:self];
-    if (!repr)
-        NSLog(@"-JSONValue failed. Error is: %@", parser.error);
-    return repr;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJson.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJson.h b/sdks/ios/UGAPI/SBJson/SBJson.h
deleted file mode 100755
index b25da4a..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJson.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- Copyright (C) 2009-2011 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-/**
- @page json2objc JSON to Objective-C
- 
- JSON is mapped to Objective-C types in the following way:
- 
- @li null    -> NSNull
- @li string  -> NSString
- @li array   -> NSMutableArray
- @li object  -> NSMutableDictionary
- @li true    -> NSNumber's -numberWithBool:YES
- @li false   -> NSNumber's -numberWithBool:NO
- @li integer up to 19 digits -> NSNumber's -numberWithLongLong:
- @li all other numbers       -> NSDecimalNumber
- 
- Since Objective-C doesn't have a dedicated class for boolean values,
- these turns into NSNumber instances. However, since these are
- initialised with the -initWithBool: method they round-trip back to JSON
- properly. In other words, they won't silently suddenly become 0 or 1;
- they'll be represented as 'true' and 'false' again.
- 
- As an optimisation integers up to 19 digits in length (the max length
- for signed long long integers) turn into NSNumber instances, while
- complex ones turn into NSDecimalNumber instances. We can thus avoid any
- loss of precision as JSON allows ridiculously large numbers.
-
- @page objc2json Objective-C to JSON
- 
- Objective-C types are mapped to JSON types in the following way:
- 
- @li NSNull        -> null
- @li NSString      -> string
- @li NSArray       -> array
- @li NSDictionary  -> object
- @li NSNumber's -initWithBool:YES -> true
- @li NSNumber's -initWithBool:NO  -> false
- @li NSNumber      -> number
- 
- @note In JSON the keys of an object must be strings. NSDictionary
- keys need not be, but attempting to convert an NSDictionary with
- non-string keys into JSON will throw an exception.
- 
- NSNumber instances created with the -numberWithBool: method are
- converted into the JSON boolean "true" and "false" values, and vice
- versa. Any other NSNumber instances are converted to a JSON number the
- way you would expect.
-
- */
-
-#import "SBJsonParser.h"
-#import "SBJsonWriter.h"
-#import "SBJsonStreamParser.h"
-#import "SBJsonStreamParserAdapter.h"
-#import "SBJsonStreamWriter.h"
-#import "NSObject+SBJson.h"
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonParser.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonParser.h b/sdks/ios/UGAPI/SBJson/SBJsonParser.h
deleted file mode 100755
index 751122f..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonParser.h
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- Copyright (C) 2009 Stig Brautaset. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
-
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
-
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-/**
- @brief Parse JSON Strings and NSData objects
-
- This uses SBJsonStreamParser internally.
-
- @see @ref objc2json
-
- */
-
-@interface SBJsonParser : NSObject
-
-/**
- @brief The maximum recursing depth.
-
- Defaults to 32. If the input is nested deeper than this the input will be deemed to be
- malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
- turn off this security feature by setting the maxDepth value to 0.
- */
-@property NSUInteger maxDepth;
-
-/**
- @brief Description of parse error
-
- This method returns the trace of the last method that failed.
- You need to check the return value of the call you're making to figure out
- if the call actually failed, before you know call this method.
-
- @return A string describing the error encountered, or nil if no error occured.
-
- */
-@property(copy) NSString *error;
-
-/**
- @brief Return the object represented by the given NSData object.
-
- The data *must* be UTF8 encoded.
- 
- @param data An NSData containing UTF8 encoded data to parse.
- @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
-
- */
-- (id)objectWithData:(NSData*)data;
-
-/**
- @brief Return the object represented by the given string
-
- This method converts its input to an NSData object containing UTF8 and calls -objectWithData: with it.
-
- @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
- */
-- (id)objectWithString:(NSString *)repr;
-
-/**
- @brief Return the object represented by the given string
-
- This method calls objectWithString: internally. If an error occurs, and if @p error
- is not nil, it creates an NSError object and returns this through its second argument.
-
- @param jsonText the json string to parse
- @param error pointer to an NSError object to populate on error
-
- @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
- */
-
-- (id)objectWithString:(NSString*)jsonText
-                 error:(NSError**)error;
-
-@end
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonParser.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonParser.m b/sdks/ios/UGAPI/SBJson/SBJsonParser.m
deleted file mode 100755
index d1b4b1e..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonParser.m
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- Copyright (C) 2009,2010 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonParser.h"
-#import "SBJsonStreamParser.h"
-#import "SBJsonStreamParserAdapter.h"
-#import "SBJsonStreamParserAccumulator.h"
-
-@implementation SBJsonParser
-
-@synthesize maxDepth;
-@synthesize error;
-
-- (id)init {
-    self = [super init];
-    if (self)
-        self.maxDepth = 32u;
-    return self;
-}
-
-
-#pragma mark Methods
-
-- (id)objectWithData:(NSData *)data {
-
-    if (!data) {
-        self.error = @"Input was 'nil'";
-        return nil;
-    }
-
-	SBJsonStreamParserAccumulator *accumulator = [[SBJsonStreamParserAccumulator alloc] init];
-    
-    SBJsonStreamParserAdapter *adapter = [[SBJsonStreamParserAdapter alloc] init];
-    adapter.delegate = accumulator;
-	
-	SBJsonStreamParser *parser = [[SBJsonStreamParser alloc] init];
-	parser.maxDepth = self.maxDepth;
-	parser.delegate = adapter;
-	
-	switch ([parser parse:data]) {
-		case SBJsonStreamParserComplete:
-            return accumulator.value;
-			break;
-			
-		case SBJsonStreamParserWaitingForData:
-		    self.error = @"Unexpected end of input";
-			break;
-
-		case SBJsonStreamParserError:
-		    self.error = parser.error;
-			break;
-	}
-	
-	return nil;
-}
-
-- (id)objectWithString:(NSString *)repr {
-	return [self objectWithData:[repr dataUsingEncoding:NSUTF8StringEncoding]];
-}
-
-- (id)objectWithString:(NSString*)repr error:(NSError**)error_ {
-	id tmp = [self objectWithString:repr];
-    if (tmp)
-        return tmp;
-    
-    if (error_) {
-		NSDictionary *ui = [NSDictionary dictionaryWithObjectsAndKeys:error, NSLocalizedDescriptionKey, nil];
-        *error_ = [NSError errorWithDomain:@"org.brautaset.SBJsonParser.ErrorDomain" code:0 userInfo:ui];
-	}
-	
-    return nil;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.h
deleted file mode 100755
index 2530eca..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.h
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-@class SBJsonTokeniser;
-@class SBJsonStreamParser;
-@class SBJsonStreamParserState;
-
-typedef enum {
-	SBJsonStreamParserComplete,
-	SBJsonStreamParserWaitingForData,
-	SBJsonStreamParserError,
-} SBJsonStreamParserStatus;
-
-
-/**
- @brief Delegate for interacting directly with the stream parser
- 
- You will most likely find it much more convenient to implement the
- SBJsonStreamParserAdapterDelegate protocol instead.
- */
-@protocol SBJsonStreamParserDelegate
-
-/// Called when object start is found
-- (void)parserFoundObjectStart:(SBJsonStreamParser*)parser;
-
-/// Called when object key is found
-- (void)parser:(SBJsonStreamParser*)parser foundObjectKey:(NSString*)key;
-
-/// Called when object end is found
-- (void)parserFoundObjectEnd:(SBJsonStreamParser*)parser;
-
-/// Called when array start is found
-- (void)parserFoundArrayStart:(SBJsonStreamParser*)parser;
-
-/// Called when array end is found
-- (void)parserFoundArrayEnd:(SBJsonStreamParser*)parser;
-
-/// Called when a boolean value is found
-- (void)parser:(SBJsonStreamParser*)parser foundBoolean:(BOOL)x;
-
-/// Called when a null value is found
-- (void)parserFoundNull:(SBJsonStreamParser*)parser;
-
-/// Called when a number is found
-- (void)parser:(SBJsonStreamParser*)parser foundNumber:(NSNumber*)num;
-
-/// Called when a string is found
-- (void)parser:(SBJsonStreamParser*)parser foundString:(NSString*)string;
-
-@end
-
-
-/**
- @brief Parse a stream of JSON data.
- 
- Using this class directly you can reduce the apparent latency for each
- download/parse cycle of documents over a slow connection. You can start
- parsing *and return chunks of the parsed document* before the entire
- document is downloaded.
- 
- Using this class is also useful to parse huge documents on disk
- bit by bit so you don't have to keep them all in memory. 
- 
- @see SBJsonStreamParserAdapter for more information.
- 
- @see @ref objc2json
- 
- */
-@interface SBJsonStreamParser : NSObject {
-@private
-	SBJsonTokeniser *tokeniser;
-}
-
-@property (nonatomic, unsafe_unretained) SBJsonStreamParserState *state; // Private
-@property (nonatomic, readonly, strong) NSMutableArray *stateStack; // Private
-
-/**
- @brief Expect multiple documents separated by whitespace
-
- Normally the @p -parse: method returns SBJsonStreamParserComplete when it's found a complete JSON document.
- Attempting to parse any more data at that point is considered an error. ("Garbage after JSON".)
- 
- If you set this property to true the parser will never return SBJsonStreamParserComplete. Rather,
- once an object is completed it will expect another object to immediately follow, separated
- only by (optional) whitespace.
-
- @see The TweetStream app in the Examples
- */
-@property BOOL supportMultipleDocuments;
-
-/**
- @brief Delegate to receive messages
-
- The object set here receives a series of messages as the parser breaks down the JSON stream
- into valid tokens.
-
- @note
- Usually this should be an instance of SBJsonStreamParserAdapter, but you can
- substitute your own implementation of the SBJsonStreamParserDelegate protocol if you need to. 
- */
-@property (unsafe_unretained) id<SBJsonStreamParserDelegate> delegate;
-
-/**
- @brief The max parse depth
- 
- If the input is nested deeper than this the parser will halt parsing and return an error.
-
- Defaults to 32. 
- */
-@property NSUInteger maxDepth;
-
-/// Holds the error after SBJsonStreamParserError was returned
-@property (copy) NSString *error;
-
-/**
- @brief Parse some JSON
- 
- The JSON is assumed to be UTF8 encoded. This can be a full JSON document, or a part of one.
-
- @param data An NSData object containing the next chunk of JSON
-
- @return 
- @li SBJsonStreamParserComplete if a full document was found
- @li SBJsonStreamParserWaitingForData if a partial document was found and more data is required to complete it
- @li SBJsonStreamParserError if an error occured. (See the error property for details in this case.)
- 
- */
-- (SBJsonStreamParserStatus)parse:(NSData*)data;
-
-@end


[02/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/usergrid_ironhorse/query.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/usergrid_ironhorse/query.rb b/sdks/ruby-on-rails/lib/usergrid_ironhorse/query.rb
deleted file mode 100644
index 6562b8f..0000000
--- a/sdks/ruby-on-rails/lib/usergrid_ironhorse/query.rb
+++ /dev/null
@@ -1,929 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# http://guides.rubyonrails.org/active_record_querying.html
-
-module Usergrid
-  module Ironhorse
-
-    class Query
-
-      RecordNotFound = ActiveRecord::RecordNotFound
-
-      def initialize(model_class)
-        @model_class = model_class
-        @options = {}
-      end
-
-      ## Initializes new record from relation while maintaining the current
-      ## scope.
-      ##
-      ## Expects arguments in the same format as +Base.new+.
-      ##
-      ##   users = User.where(name: 'DHH')
-      ##   user = users.new # => #<User id: nil, name: "DHH", created_at: nil, updated_at: nil>
-      ##
-      ## You can also pass a block to new with the new record as argument:
-      ##
-      ##   user = users.new { |user| user.name = 'Oscar' }
-      ##   user.name # => Oscar
-      #def new(*args, &block)
-      #  scoping { @model_class.new(*args, &block) }
-      #end
-
-      # Find by uuid or name - This can either be a specific uuid or name (1), a list of uuids
-      # or names (1, 5, 6), or an array of uuids or names ([5, 6, 10]).
-      # If no record can be found for all of the listed ids, then RecordNotFound will be raised.
-      #
-      #   Person.find(1)       # returns the object for ID = 1
-      #   Person.find("1")     # returns the object for ID = 1
-      #   Person.find(1, 2, 6) # returns an array for objects with IDs in (1, 2, 6)
-      #   Person.find([7, 17]) # returns an array for objects with IDs in (7, 17)
-      #   Person.find([1])     # returns an array for the object with ID = 1
-      #   Person.where("administrator = 1").order("created_on DESC").find(1)
-      #
-      def find(*ids)
-        raise RecordNotFound unless ids
-        ids = ids.first if ids.first.is_a? Array
-        @records = ids.collect { |id| find_one! id } # todo: can this be optimized in one call?
-        #entities = @model_class.resource[ids.join '&'].get.entities
-        #raise RecordNotFound unless (entities.size == ids.size)
-        #@records = entities.collect {|entity| @model_class.model_name.constantize.new(entity.data) }
-        @records.size == 1 ? @records.first : @records
-      end
-
-      # Finds the first record matching the specified conditions. There
-      # is no implied ordering so if order matters, you should specify it
-      # yourself.
-      #
-      # If no record is found, returns <tt>nil</tt>.
-      #
-      #   Post.find_by name: 'Spartacus', rating: 4
-      #   Post.find_by "published_at < ?", 2.weeks.ago
-      def find_by(*conditions)
-        where(*conditions).take
-      end
-
-      # Like <tt>find_by</tt>, except that if no record is found, raises
-      # an <tt>ActiveRecord::RecordNotFound</tt> error.
-      def find_by!(*conditions)
-        where(*conditions).take!
-      end
-
-      # Gives a record (or N records if a parameter is supplied) without any implied
-      # order.
-      #
-      #   Person.take # returns an object fetched by SELECT * FROM people
-      #   Person.take(5) # returns 5 objects fetched by SELECT * FROM people LIMIT 5
-      #   Person.where(["name LIKE '%?'", name]).take
-      def take(limit=1)
-        limit(limit).to_a
-      end
-
-      # Same as +take+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
-      # is found. Note that <tt>take!</tt> accepts no arguments.
-      def take!
-        take or raise RecordNotFound
-      end
-
-      # Find the first record (or first N records if a parameter is supplied).
-      # If no order is defined it will order by primary key.
-      #
-      #   Person.first # returns the first object fetched by SELECT * FROM people
-      #   Person.where(["user_name = ?", user_name]).first
-      #   Person.where(["user_name = :u", { :u => user_name }]).first
-      #   Person.order("created_on DESC").offset(5).first
-      #   Person.first(3) # returns the first three objects fetched by SELECT * FROM people LIMIT 3
-      def first(limit=1)
-        limit(limit).load.first
-      end
-
-      # Same as +first+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
-      # is found. Note that <tt>first!</tt> accepts no arguments.
-      def first!
-        first or raise RecordNotFound
-      end
-
-      # Find the last record (or last N records if a parameter is supplied).
-      # If no order is defined it will order by primary key.
-      #
-      #   Person.last # returns the last object fetched by SELECT * FROM people
-      #   Person.where(["user_name = ?", user_name]).last
-      #   Person.order("created_on DESC").offset(5).last
-      #   Person.last(3) # returns the last three objects fetched by SELECT * FROM people.
-      #
-      # Take note that in that last case, the results are sorted in ascending order:
-      #
-      #   [#<Person id:2>, #<Person id:3>, #<Person id:4>]
-      #
-      # and not:
-      #
-      #   [#<Person id:4>, #<Person id:3>, #<Person id:2>]
-      def last(limit=1)
-        limit(limit).reverse_order.load.first
-      end
-
-      # Same as +last+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
-      # is found. Note that <tt>last!</tt> accepts no arguments.
-      def last!
-        last or raise RecordNotFound
-      end
-
-      def each
-        to_a.each { |*block_args| yield(*block_args) }
-        while @response.data['cursor'] && !limit_value
-          next_page
-          to_a.each { |*block_args| yield(*block_args) }
-        end
-      end
-
-      def next_page
-        @options[:cursor] = @response.data['cursor']
-        @records = nil
-        load
-        self
-      end
-
-      # Returns +true+ if a record exists in the table that matches the +id+ or
-      # conditions given, or +false+ otherwise. The argument can take six forms:
-      #
-      # * String - Finds the record with a primary key corresponding to this
-      #   string (such as <tt>'5'</tt>).
-      # * Array - Finds the record that matches these +find+-style conditions
-      #   (such as <tt>['color = ?', 'red']</tt>).
-      # * Hash - Finds the record that matches these +find+-style conditions
-      #   (such as <tt>{color: 'red'}</tt>).
-      # * +false+ - Returns always +false+.
-      # * No args - Returns +false+ if the table is empty, +true+ otherwise.
-      #
-      # For more information about specifying conditions as a Hash or Array,
-      # see the Conditions section in the introduction to ActiveRecord::Base.
-      def exists?(conditions=nil)
-        # todo: does not yet handle all conditions described above
-        case conditions
-          when Array, Hash
-            pluck :uuid
-            !where(conditions).take.empty?
-          else
-            !!find_one(conditions)
-        end
-      end
-      alias_method :any?, :exists?
-      alias_method :many?, :exists?
-
-      def limit(limit=1)
-        @options[:limit] = limit
-        self
-      end
-
-      def offset(num)
-        @options[:offset] = num
-        self
-      end
-
-      # Removes from the query the condition(s) specified in +skips+.
-      #
-      # Example:
-      #
-      #   Post.order('id asc').except(:order)                  # discards the order condition
-      #   Post.where('id > 10').order('id asc').except(:where) # discards the where condition but keeps the order
-      #
-      def except(*skips)
-        skips.each {|option| @options.delete option}
-      end
-
-      # Removes any condition from the query other than the one(s) specified in +onlies+.
-      #
-      # Example:
-      #
-      #   Post.order('id asc').only(:where)         # discards the order condition
-      #   Post.order('id asc').only(:where, :order) # uses the specified order
-      #
-      def only(*onlies)
-        @options.keys do |k|
-          unless onlines.include? k
-            @options.delete k
-          end
-        end
-      end
-
-      # Allows to specify an order attribute:
-      #
-      #   User.order('name')
-      #   => SELECT "users".* FROM "users" ORDER BY name
-      #
-      #   User.order('name DESC')
-      #   => SELECT "users".* FROM "users" ORDER BY name DESC
-      #
-      #   User.order('name DESC, email')
-      #   => SELECT "users".* FROM "users" ORDER BY name DESC, email
-      def order(*args)
-        @options[:order] << args
-      end
-
-      # Replaces any existing order defined on the relation with the specified order.
-      #
-      #   User.order('email DESC').reorder('id ASC') # generated SQL has 'ORDER BY id ASC'
-      #
-      # Subsequent calls to order on the same relation will be appended. For example:
-      #
-      #   User.order('email DESC').reorder('id ASC').order('name ASC')
-      #
-      # generates a query with 'ORDER BY name ASC, id ASC'.
-      def reorder(*args)
-        @options[:order] = args
-      end
-
-      def all
-        @options[:conditions] = nil
-        self
-      end
-
-      # Works in two unique ways.
-      #
-      # First: takes a block so it can be used just like Array#select.
-      #
-      #   Model.all.select { |m| m.field == value }
-      #
-      # This will build an array of objects from the database for the scope,
-      # converting them into an array and iterating through them using Array#select.
-      #
-      # Second: Modifies the SELECT statement for the query so that only certain
-      # fields are retrieved:
-      #
-      #   Model.select(:field)
-      #   # => [#<Model field:value>]
-      #
-      # Although in the above example it looks as though this method returns an
-      # array, it actually returns a relation object and can have other query
-      # methods appended to it, such as the other methods in ActiveRecord::QueryMethods.
-      #
-      # The argument to the method can also be an array of fields.
-      #
-      #   Model.select(:field, :other_field, :and_one_more)
-      #   # => [#<Model field: "value", other_field: "value", and_one_more: "value">]
-      #
-      def select(*fields)
-        if block_given?
-          to_a.select { |*block_args| yield(*block_args) }
-        else
-          raise ArgumentError, 'Call this with at least one field' if fields.empty?
-          clone.select!(*fields)
-        end
-      end
-
-      # Like #select, but modifies relation in place.
-      def select!(*fields)
-        @options[:select] ||= fields.join ','
-        self
-      end
-      alias_method :pluck, :select!
-
-      def reverse_order
-        @options[:reversed] = true
-        self
-      end
-
-      def readonly
-        @options[:readonly] = true
-        self
-      end
-
-      def to_a
-        load
-        @records
-      end
-
-      def as_json(options = nil) #:nodoc:
-        to_a.as_json(options)
-      end
-
-      # Returns size of the results (not size of the stored collection)
-      def size
-        loaded? ? @records.length : count
-      end
-
-      # true if there are no records
-      def empty?
-        return @records.empty? if loaded?
-
-        c = count
-        c.respond_to?(:zero?) ? c.zero? : c.empty?
-      end
-
-      # true if there are any records
-      def any?
-        if block_given?
-          to_a.any? { |*block_args| yield(*block_args) }
-        else
-          !empty?
-        end
-      end
-
-      # true if there is more than one record
-      def many?
-        if block_given?
-          to_a.many? { |*block_args| yield(*block_args) }
-        else
-          limit_value ? to_a.many? : size > 1
-        end
-      end
-
-      # find_all_by_
-      # find_by_
-      # find_first_by_
-      # find_last_by_
-      def method_missing(method_name, *args)
-
-        method = method_name.to_s
-
-        if method.end_with? '!'
-          method.chop!
-          error_on_empty = true
-        end
-
-        if method.start_with? 'find_all_by_'
-          attribs = method.gsub /^find_all_by_/, ''
-        elsif method.start_with? 'find_by_'
-          attribs = method.gsub /^find_by_/, ''
-          limit(1)
-        elsif method.start_with? 'find_first_by_'
-          limit(1)
-          find_first = true
-          attribs = method.gsub /^find_first_by_/, ''
-        elsif method.start_with? 'find_last_by_'
-          limit(1)
-          find_last = true
-          attribs = method.gsub /^find_last_by_/, ''
-        else
-          super
-        end
-
-        attribs = attribs.split '_and_'
-        conditions = {}
-        attribs.each { |attr| conditions[attr] = args.shift }
-
-        where(conditions, *args)
-        load
-        raise RecordNotFound if error_on_empty && @records.empty?
-        return @records.first if limit_value == 1
-        @records
-      end
-
-      # Tries to create a new record with the same scoped attributes
-      # defined in the relation. Returns the initialized object if validation fails.
-      #
-      # Expects arguments in the same format as +Base.create+.
-      #
-      # ==== Examples
-      #   users = User.where(name: 'Oscar')
-      #   users.create # #<User id: 3, name: "oscar", ...>
-      #
-      #   users.create(name: 'fxn')
-      #   users.create # #<User id: 4, name: "fxn", ...>
-      #
-      #   users.create { |user| user.name = 'tenderlove' }
-      #   # #<User id: 5, name: "tenderlove", ...>
-      #
-      #   users.create(name: nil) # validation on name
-      #   # #<User id: nil, name: nil, ...>
-      def create(*args, &block)
-        @model_class.create(*args, &block)
-      end
-
-      # Similar to #create, but calls +create!+ on the base class. Raises
-      # an exception if a validation error occurs.
-      #
-      # Expects arguments in the same format as <tt>Base.create!</tt>.
-      def create!(*args, &block)
-        @model_class.create!(*args, &block)
-      end
-
-      # Tries to load the first record; if it fails, then <tt>create</tt> is called with the same arguments as this method.
-      #
-      # Expects arguments in the same format as +Base.create+.
-      #
-      # ==== Examples
-      #   # Find the first user named Pen�lope or create a new one.
-      #   User.where(:first_name => 'Pen�lope').first_or_create
-      #   # => <User id: 1, first_name: 'Pen�lope', last_name: nil>
-      #
-      #   # Find the first user named Pen�lope or create a new one.
-      #   # We already have one so the existing record will be returned.
-      #   User.where(:first_name => 'Pen�lope').first_or_create
-      #   # => <User id: 1, first_name: 'Pen�lope', last_name: nil>
-      #
-      #   # Find the first user named Scarlett or create a new one with a particular last name.
-      #   User.where(:first_name => 'Scarlett').first_or_create(:last_name => 'Johansson')
-      #   # => <User id: 2, first_name: 'Scarlett', last_name: 'Johansson'>
-      #
-      #   # Find the first user named Scarlett or create a new one with a different last name.
-      #   # We already have one so the existing record will be returned.
-      #   User.where(:first_name => 'Scarlett').first_or_create do |user|
-      #     user.last_name = "O'Hara"
-      #   end
-      #   # => <User id: 2, first_name: 'Scarlett', last_name: 'Johansson'>
-      def first_or_create(attributes={}, &block)
-        result = first
-        unless result
-          attributes = @options[:hash].merge(attributes) if @options[:hash]
-          result = create(attributes, &block)
-        end
-        result
-      end
-
-      # Like <tt>first_or_create</tt> but calls <tt>create!</tt> so an exception is raised if the created record is invalid.
-      #
-      # Expects arguments in the same format as <tt>Base.create!</tt>.
-      def first_or_create!(attributes={}, &block)
-        result = first
-        unless result
-          attributes = @options[:hash].merge(attributes) if @options[:hash]
-          result = create!(attributes, &block)
-        end
-        result
-      end
-
-      # Like <tt>first_or_create</tt> but calls <tt>new</tt> instead of <tt>create</tt>.
-      #
-      # Expects arguments in the same format as <tt>Base.new</tt>.
-      def first_or_initialize(attributes={}, &block)
-        result = first
-        unless result
-          attributes = @options[:hash].merge(attributes) if @options[:hash]
-          result = @model_class.new(attributes, &block)
-        end
-        result
-      end
-
-      # Destroys the records matching +conditions+ by instantiating each
-      # record and calling its +destroy+ method. Each object's callbacks are
-      # executed (including <tt>:dependent</tt> association options and
-      # +before_destroy+/+after_destroy+ Observer methods). Returns the
-      # collection of objects that were destroyed; each will be frozen, to
-      # reflect that no changes should be made (since they can't be
-      # persisted).
-      #
-      # Note: Instantiation, callback execution, and deletion of each
-      # record can be time consuming when you're removing many records at
-      # once. It generates at least one SQL +DELETE+ query per record (or
-      # possibly more, to enforce your callbacks). If you want to delete many
-      # rows quickly, without concern for their associations or callbacks, use
-      # +delete_all+ instead.
-      #
-      # ==== Parameters
-      #
-      # * +conditions+ - A string, array, or hash that specifies which records
-      #   to destroy. If omitted, all records are destroyed. See the
-      #   Conditions section in the introduction to ActiveRecord::Base for
-      #   more information.
-      #
-      # ==== Examples
-      #
-      #   Person.destroy_all("last_login < '2004-04-04'")
-      #   Person.destroy_all(status: "inactive")
-      #   Person.where(:age => 0..18).destroy_all
-      def destroy_all(conditions=nil)
-        if conditions
-          where(conditions).destroy_all
-        else
-          to_a.each {|object| object.destroy}
-          @records
-        end
-      end
-
-      # Destroy an object (or multiple objects) that has the given id. The object is instantiated first,
-      # therefore all callbacks and filters are fired off before the object is deleted. This method is
-      # less efficient than ActiveRecord#delete but allows cleanup methods and other actions to be run.
-      #
-      # This essentially finds the object (or multiple objects) with the given id, creates a new object
-      # from the attributes, and then calls destroy on it.
-      #
-      # ==== Parameters
-      #
-      # * +id+ - Can be either an Integer or an Array of Integers.
-      #
-      # ==== Examples
-      #
-      #   # Destroy a single object
-      #   Foo.destroy(1)
-      #
-      #   # Destroy multiple objects
-      #   foos = [1,2,3]
-      #   Foo.destroy(foos)
-      def destroy(id)
-        if id.is_a?(Array)
-          id.map {|one_id| destroy(one_id)}
-        else
-          find(id).destroy
-        end
-      end
-
-      # Deletes the records matching +conditions+ without instantiating the records
-      # first, and hence not calling the +destroy+ method nor invoking callbacks. This
-      # is a single SQL DELETE statement that goes straight to the database, much more
-      # efficient than +destroy_all+. Be careful with relations though, in particular
-      # <tt>:dependent</tt> rules defined on associations are not honored. Returns the
-      # number of rows affected.
-      #
-      #   Post.delete_all("person_id = 5 AND (category = 'Something' OR category = 'Else')")
-      #   Post.delete_all(["person_id = ? AND (category = ? OR category = ?)", 5, 'Something', 'Else'])
-      #   Post.where(:person_id => 5).where(:category => ['Something', 'Else']).delete_all
-      #
-      # Both calls delete the affected posts all at once with a single DELETE statement.
-      # If you need to destroy dependent associations or call your <tt>before_*</tt> or
-      # +after_destroy+ callbacks, use the +destroy_all+ method instead.
-      #
-      # If a limit scope is supplied, +delete_all+ raises an ActiveRecord error:
-      #
-      #   Post.limit(100).delete_all
-      #   # => ActiveRecord::ActiveRecordError: delete_all doesn't support limit scope
-      def delete_all(conditions=nil)
-        raise ActiveRecordError.new("delete_all doesn't support limit scope") if self.limit_value
-
-        if conditions
-          where(conditions).delete_all
-        else
-          pluck :uuid
-          response = load
-          response.each {|entity| entity.delete} # todo: can this be optimized into one call?
-          response.size
-        end
-      end
-
-      # Deletes the row with a primary key matching the +id+ argument, using a
-      # SQL +DELETE+ statement, and returns the number of rows deleted. Active
-      # Record objects are not instantiated, so the object's callbacks are not
-      # executed, including any <tt>:dependent</tt> association options or
-      # Observer methods.
-      #
-      # You can delete multiple rows at once by passing an Array of <tt>id</tt>s.
-      #
-      # Note: Although it is often much faster than the alternative,
-      # <tt>#destroy</tt>, skipping callbacks might bypass business logic in
-      # your application that ensures referential integrity or performs other
-      # essential jobs.
-      #
-      # ==== Examples
-      #
-      #   # Delete a single row
-      #   Foo.delete(1)
-      #
-      #   # Delete multiple rows
-      #   Foo.delete([2,3,4])
-      def delete(id_or_array)
-        if id_or_array.is_a? Array
-          id_or_array.each {|id| @model_class.resource[id].delete} # todo: can this be optimized into one call?
-        else
-          @model_class.resource[id_or_array].delete
-        end
-      end
-
-      # Updates all records with details given if they match a set of conditions supplied, limits and order can
-      # also be supplied. This method sends a single update straight to the database. It does not instantiate
-      # the involved models and it does not trigger Active Record callbacks or validations.
-      #
-      # ==== Parameters
-      #
-      # * +updates+ - hash of attribute updates
-      #
-      # ==== Examples
-      #
-      #   # Update all customers with the given attributes
-      #   Customer.update_all wants_email: true
-      #
-      #   # Update all books with 'Rails' in their title
-      #   Book.where('title LIKE ?', '%Rails%').update_all(author: 'David')
-      #
-      #   # Update all books that match conditions, but limit it to 5 ordered by date
-      #   Book.where('title LIKE ?', '%Rails%').order(:created).limit(5).update_all(:author => 'David')
-      def update_all(updates)
-        raise ArgumentError, "Empty list of attributes to change" if updates.blank?
-        raise ArgumentError, "updates must be a Hash" unless updates.is_a? Hash
-        run_update(updates)
-      end
-
-      # Looping through a collection of records from the database
-      # (using the +all+ method, for example) is very inefficient
-      # since it will try to instantiate all the objects at once.
-      #
-      # In that case, batch processing methods allow you to work
-      # with the records in batches, thereby greatly reducing memory consumption.
-      #
-      # The #find_each method uses #find_in_batches with a batch size of 1000 (or as
-      # specified by the +:batch_size+ option).
-      #
-      #   Person.all.find_each do |person|
-      #     person.do_awesome_stuff
-      #   end
-      #
-      #   Person.where("age > 21").find_each do |person|
-      #     person.party_all_night!
-      #   end
-      #
-      #  You can also pass the +:start+ option to specify
-      #  an offset to control the starting point.
-      def find_each(options = {})
-        find_in_batches(options) do |records|
-          records.each { |record| yield record }
-        end
-      end
-
-      # Yields each batch of records that was found by the find +options+ as
-      # an array. The size of each batch is set by the +:batch_size+
-      # option; the default is 1000.
-      #
-      # You can control the starting point for the batch processing by
-      # supplying the +:start+ option. This is especially useful if you
-      # want multiple workers dealing with the same processing queue. You can
-      # make worker 1 handle all the records between id 0 and 10,000 and
-      # worker 2 handle from 10,000 and beyond (by setting the +:start+
-      # option on that worker).
-      #
-      # It's not possible to set the order. That is automatically set to
-      # ascending on the primary key ("id ASC") to make the batch ordering
-      # work. This also mean that this method only works with integer-based
-      # primary keys. You can't set the limit either, that's used to control
-      # the batch sizes.
-      #
-      #   Person.where("age > 21").find_in_batches do |group|
-      #     sleep(50) # Make sure it doesn't get too crowded in there!
-      #     group.each { |person| person.party_all_night! }
-      #   end
-      #
-      #   # Let's process the next 2000 records
-      #   Person.all.find_in_batches(start: 2000, batch_size: 2000) do |group|
-      #     group.each { |person| person.party_all_night! }
-      #   end
-      def find_in_batches(options={})
-        options.assert_valid_keys(:start, :batch_size)
-
-        raise "Not yet implemented" # todo
-
-        start = options.delete(:start) || 0
-        batch_size = options.delete(:batch_size) || 1000
-
-        while records.any?
-          records_size = records.size
-          primary_key_offset = records.last.id
-
-          yield records
-
-          break if records_size < batch_size
-
-          if primary_key_offset
-            records = relation.where(table[primary_key].gt(primary_key_offset)).to_a
-          else
-            raise "Primary key not included in the custom select clause"
-          end
-        end
-      end
-
-      # Updates an object (or multiple objects) and saves it to the database, if validations pass.
-      # The resulting object is returned whether the object was saved successfully to the database or not.
-      #
-      # ==== Parameters
-      #
-      # * +id+ - This should be the id or an array of ids to be updated.
-      # * +attributes+ - This should be a hash of attributes or an array of hashes.
-      #
-      # ==== Examples
-      #
-      #   # Updates one record
-      #   Person.update(15, user_name: 'Samuel', group: 'expert')
-      #
-      #   # Updates multiple records
-      #   people = { 1 => { "first_name" => "David" }, 2 => { "first_name" => "Jeremy" } }
-      #   Person.update(people.keys, people.values)
-      def update(id, attributes)
-        if id.is_a?(Array)
-          id.map.with_index { |one_id, idx| update(one_id, attributes[idx]) }
-        else
-          object = find(id)
-          object.update_attributes(attributes)
-          object
-        end
-      end
-
-      ## todo: scoping
-      ## Scope all queries to the current scope.
-      ##
-      ##   Comment.where(:post_id => 1).scoping do
-      ##     Comment.first # SELECT * FROM comments WHERE post_id = 1
-      ##   end
-      ##
-      ## Please check unscoped if you want to remove all previous scopes (including
-      ## the default_scope) during the execution of a block.
-      #def scoping
-      #  previous, @model_class.current_scope = @model_class.current_scope, self
-      #  yield
-      #ensure
-      #  klass.current_scope = previous
-      #end
-
-
-      # #where accepts conditions in one of several formats.
-      #
-      # === string
-      #
-      # A single string, without additional arguments, is used in the where clause of the query.
-      #
-      #    Client.where("orders_count = '2'")
-      #    # SELECT * where orders_count = '2';
-      #
-      # Note that building your own string from user input may expose your application
-      # to injection attacks if not done properly. As an alternative, it is recommended
-      # to use one of the following methods.
-      #
-      # === array
-      #
-      # If an array is passed, then the first element of the array is treated as a template, and
-      # the remaining elements are inserted into the template to generate the condition.
-      # Active Record takes care of building the query to avoid injection attacks, and will
-      # convert from the ruby type to the database type where needed. Elements are inserted
-      # into the string in the order in which they appear.
-      #
-      #   User.where(["name = ? and email = ?", "Joe", "joe@example.com"])
-      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
-      #
-      # Alternatively, you can use named placeholders in the template, and pass a hash as the
-      # second element of the array. The names in the template are replaced with the corresponding
-      # values from the hash.
-      #
-      #   User.where(["name = :name and email = :email", { name: "Joe", email: "joe@example.com" }])
-      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
-      #
-      # This can make for more readable code in complex queries.
-      #
-      # Lastly, you can use sprintf-style % escapes in the template. This works slightly differently
-      # than the previous methods; you are responsible for ensuring that the values in the template
-      # are properly quoted. The values are passed to the connector for quoting, but the caller
-      # is responsible for ensuring they are enclosed in quotes in the resulting SQL. After quoting,
-      # the values are inserted using the same escapes as the Ruby core method <tt>Kernel::sprintf</tt>.
-      #
-      #   User.where(["name = '%s' and email = '%s'", "Joe", "joe@example.com"])
-      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
-      #
-      # If #where is called with multiple arguments, these are treated as if they were passed as
-      # the elements of a single array.
-      #
-      #   User.where("name = :name and email = :email", { name: "Joe", email: "joe@example.com" })
-      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
-      #
-      # When using strings to specify conditions, you can use any operator available from
-      # the database. While this provides the most flexibility, you can also unintentionally introduce
-      # dependencies on the underlying database. If your code is intended for general consumption,
-      # test with multiple database backends.
-      #
-      # === hash
-      #
-      # #where will also accept a hash condition, in which the keys are fields and the values
-      # are values to be searched for.
-      #
-      # Fields can be symbols or strings. Values can be single values, arrays, or ranges.
-      #
-      #    User.where({ name: "Joe", email: "joe@example.com" })
-      #    # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com'
-      #
-      #    User.where({ name: ["Alice", "Bob"]})
-      #    # SELECT * WHERE name IN ('Alice', 'Bob')
-      #
-      #    User.where({ created_at: (Time.now.midnight - 1.day)..Time.now.midnight })
-      #    # SELECT * WHERE (created_at BETWEEN '2012-06-09 07:00:00.000000' AND '2012-06-10 07:00:00.000000')
-      #
-      # In the case of a belongs_to relationship, an association key can be used
-      # to specify the model if an ActiveRecord object is used as the value.
-      #
-      #    author = Author.find(1)
-      #
-      #    # The following queries will be equivalent:
-      #    Post.where(:author => author)
-      #    Post.where(:author_id => author)
-      #
-      # === empty condition
-      #
-      # If the condition returns true for blank?, then where is a no-op and returns the current relation.
-      #
-      def where(opts, *rest)
-        return self if opts.blank?
-        case opts
-          when Hash
-            @options[:hash] = opts # keep around for first_or_create stuff...
-            opts.each do |k,v|
-              # todo: can we support IN and BETWEEN syntax as documented above?
-              v = "'#{v}'" if v.is_a? String
-              query_conditions << "#{k} = #{v}"
-            end
-          when String
-            query_conditions << opts
-          when Array
-            query = opts.shift.gsub '?', "'%s'"
-            query = query % opts
-            query_conditions << query
-        end
-        self
-      end
-
-
-      protected
-
-
-      def limit_value
-        @options[:limit]
-      end
-
-      def query_conditions
-        @options[:conditions] ||= []
-      end
-
-      def loaded?
-        !!@records
-      end
-
-      def reversed?
-        !!@options[:reversed]
-      end
-
-      def find_one(id_or_name=nil)
-        begin
-          entity = @model_class.resource[id_or_name].query(nil, limit: 1).entity
-          @model_class.model_name.constantize.new(entity.data) if entity
-        rescue RestClient::ResourceNotFound
-          nil
-        end
-      end
-
-      def find_one!(id_or_name=nil)
-        find_one(id_or_name) or raise RecordNotFound
-      end
-
-      # Server-side options:
-      # Xql	       string   Query in the query language
-      # type	     string   Entity type to return
-      # Xreversed   string   Return results in reverse order
-      # connection string   Connection type (e.g., "likes")
-      # start      string   First entity's UUID to return
-      # cursor     string   Encoded representation of the query position for paging
-      # Xlimit      integer  Number of results to return
-      # permission string   Permission type
-      # Xfilter     string   Condition on which to filter
-      def query_options
-        # todo: support more options?
-        options = {}
-        options.merge!({:limit => limit_value.to_json}) if limit_value
-        options.merge!({:skip => @options[:skip].to_json}) if @options[:skip]
-        options.merge!({:reversed => reversed?.to_json}) if reversed?
-        options.merge!({:order => @options[:order]}) if @options[:order]
-        options.merge!({:cursor => @options[:cursor]}) if @options[:cursor]
-        options
-      end
-
-      def create_query
-        select = @options[:select] || '*'
-        where = ('where ' + query_conditions.join(' and ')) unless query_conditions.blank?
-        "select #{select} #{where}"
-      end
-
-      def run_query
-        @model_class.resource.query(create_query, query_options)
-      end
-
-      def run_update(attributes)
-        @model_class.resource.update_query(attributes, create_query, query_options)
-      end
-
-      def load
-        return if loaded?
-        begin
-          @response = run_query
-          if (!@options[:select] or @options[:select] == '*')
-            @records = @response.entities.collect {|r| @model_class.model_name.constantize.new(r.data)}
-          else # handle list
-            selects = @options[:select].split ','
-            @records = @response.entities.collect do |r|
-              data = {}
-              (0..selects.size).each do |i|
-                data[selects[i]] = r[i]
-              end
-              @model_class.model_name.constantize.new(data)
-            end
-          end
-        rescue RestClient::ResourceNotFound
-          @records = []
-        end
-      end
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb b/sdks/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
deleted file mode 100644
index b7a0804..0000000
--- a/sdks/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
+++ /dev/null
@@ -1,96 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-module Usergrid
-  module Ironhorse
-    module UserContext
-
-      # returns user if logged in, nil otherwise
-      # if session is passed, stores user_id and auth_token in the session
-      # and sets User as current_user
-      def authenticate(username, password, session=nil)
-        application = Usergrid::Application.new Usergrid::Ironhorse::Base.settings[:application_url]
-        begin
-          application.login username, password
-          user = new application.current_user.data
-          if session
-            session[:usergrid_user_id] = user.id
-            session[:usergrid_auth_token] = user.current_auth_token
-            set_thread_context(session)
-            Thread.current[:usergrid_current_user] = user
-          end
-          user
-        rescue
-          Rails.logger.info $!
-          raise $!
-        end
-      end
-
-      # clears auth from session and thread
-      def clear_authentication(session)
-        session[:usergrid_user_id] = nil
-        session[:usergrid_auth_token] = nil
-        clear_thread_context(session)
-      end
-
-      # allows admin actions to be done in a block
-      def as_admin(&block)
-        save_auth_token = Thread.current[:usergrid_auth_token]
-        begin
-          unless Base.settings[:auth_token]
-            resource = RestClient::Resource.new Base.settings[:application_url]
-            response = resource['token'].post grant_type: 'client_credentials', client_id: Base.settings[:client_id], client_secret: Base.settings[:client_secret]
-            Base.settings[:auth_token] = MultiJson.load(response)['access_token']
-          end
-          Thread.current[:usergrid_auth_token] = Base.settings[:auth_token]
-          yield block
-        ensure
-          Thread.current[:usergrid_auth_token] = save_auth_token
-        end
-      end
-
-      # sets auth for current thread
-      def set_thread_context(session)
-        Thread.current[:usergrid_user_id] = session[:usergrid_user_id]
-        Thread.current[:usergrid_auth_token] = session[:usergrid_auth_token]
-        Thread.current[:usergrid_current_user] = nil
-      end
-      alias_method :set_context, :set_thread_context
-
-      # clears auth from current thread
-      def clear_thread_context
-        Thread.current[:usergrid_user_id] = nil
-        Thread.current[:usergrid_auth_token] = nil
-        Thread.current[:usergrid_current_user] = nil
-      end
-      alias_method :clear_context, :clear_thread_context
-
-      # returns the auth token for the current thread
-      def current_auth_token
-        Thread.current[:usergrid_auth_token]
-      end
-
-      # does a find and return
-      def current_user
-        unless Thread.current[:usergrid_current_user]
-          Thread.current[:usergrid_current_user] = find(Thread.current[:usergrid_user_id]) if Thread.current[:usergrid_user_id]
-        end
-        Thread.current[:usergrid_current_user]
-      end
-
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/usergrid_ironhorse/version.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/usergrid_ironhorse/version.rb b/sdks/ruby-on-rails/lib/usergrid_ironhorse/version.rb
deleted file mode 100644
index 990b730..0000000
--- a/sdks/ruby-on-rails/lib/usergrid_ironhorse/version.rb
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-module Usergrid
-  module Ironhorse
-    VERSION = '0.1.2'
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/spec/spec_helper.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/spec/spec_helper.rb b/sdks/ruby-on-rails/spec/spec_helper.rb
deleted file mode 100644
index 2cee2c2..0000000
--- a/sdks/ruby-on-rails/spec/spec_helper.rb
+++ /dev/null
@@ -1,93 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'simplecov'
-require 'test/unit'
-require 'rspec'
-require 'yaml'
-require 'securerandom'
-require_relative '../lib/usergrid_ironhorse'
-
-ENV["RAILS_ENV"] ||= 'test'
-Dir[Pathname.new(File.dirname(__FILE__)).join("support/**/*.rb")].each { |f| require f }
-
-RSpec.configure do |config|
-  config.mock_with :rspec
-  config.expect_with :stdlib
-  config.expect_with :rspec
-end
-
-LOG = Logger.new(STDOUT)
-RestClient.log=LOG
-
-SimpleCov.at_exit do
-  SimpleCov.result.format!
-  #index = File.join(SimpleCov.coverage_path, 'index.html')
-  #`open #{index}` if File.exists?(index)
-end
-SimpleCov.start
-
-
-SPEC_SETTINGS = YAML::load_file(File.join File.dirname(__FILE__), 'spec_settings.yaml')
-Usergrid::Ironhorse::Base.configure! nil, nil
-
-def login_management
-  management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
-  management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
-  management
-end
-
-# ensure we are correctly setup (management login & organization)
-management = login_management
-
-begin
-  management.create_organization(SPEC_SETTINGS[:organization][:name],
-                                 SPEC_SETTINGS[:organization][:username],
-                                 SPEC_SETTINGS[:organization][:username],
-                                 "#{SPEC_SETTINGS[:organization][:username]}@email.com",
-                                 SPEC_SETTINGS[:organization][:password])
-  LOG.info "created organization with user #{SPEC_SETTINGS[:organization][:username]}@email.com"
-rescue
-  if MultiJson.load($!.response)['error'] == "duplicate_unique_property_exists"
-    LOG.debug "test organization exists"
-  else
-    raise $!
-  end
-end
-
-def create_random_application
-  management = login_management
-  organization = management.organization SPEC_SETTINGS[:organization][:name]
-  app_name = "_test_app_#{SecureRandom.hex}"
-  organization.create_application app_name
-  management.application SPEC_SETTINGS[:organization][:name], app_name
-end
-
-def delete_application(application)
-  management = login_management
-  application.auth_token = management.auth_token
-  application.delete rescue nil  # not implemented on server yet
-end
-
-def create_random_user(application, login=false)
-  random = SecureRandom.hex
-  user_hash = {username: "username_#{random}",
-               password: random,
-               email:    "#{random}@email.com",
-               name:     "#{random} name" }
-  entity = application['users'].post(user_hash).entity
-  application.login user_hash[:username], user_hash[:password] if login
-  entity
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/spec/spec_settings.yaml
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/spec/spec_settings.yaml b/sdks/ruby-on-rails/spec/spec_settings.yaml
deleted file mode 100644
index 815ba43..0000000
--- a/sdks/ruby-on-rails/spec/spec_settings.yaml
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-:api_url: http://localhost:8080
-:organization:
-  :name: test-organization
-  :username: test
-  :password: test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/spec/support/active_model_lint.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/spec/support/active_model_lint.rb b/sdks/ruby-on-rails/spec/support/active_model_lint.rb
deleted file mode 100644
index 267be05..0000000
--- a/sdks/ruby-on-rails/spec/support/active_model_lint.rb
+++ /dev/null
@@ -1,33 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-# spec/support/active_model_lint.rb
-# adapted from rspec-rails: http://github.com/rspec/rspec-rails/blob/master/spec/rspec/rails/mocks/mock_model_spec.rb
-
-shared_examples_for "ActiveModel" do
-  include ActiveModel::Lint::Tests
-
-  # to_s is to support ruby-1.9
-  ActiveModel::Lint::Tests.public_instance_methods.map{|m| m.to_s}.grep(/^test/).each do |m|
-    example m.sub('_',' ') do
-      send m
-    end
-  end
-
-  def model
-    subject
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb b/sdks/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
deleted file mode 100644
index 4aa1da6..0000000
--- a/sdks/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
+++ /dev/null
@@ -1,452 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-describe Usergrid::Ironhorse::Base do
-
-  it_should_behave_like 'ActiveModel'
-
-  class User < Usergrid::Ironhorse::Base
-    extend Usergrid::Ironhorse::UserContext
-  end
-
-  before :all do
-    @application = create_random_application
-    Foo.configure!(@application.url, @application.auth_token)
-    @user = create_random_user @application, true
-    @foo = (@application.create_entity 'foos', name: 'foo42', answer: 42).entity
-  end
-
-  after :all do
-    @foo.delete
-    @user.delete
-    #delete_application @application # not supported on server yet
-  end
-
-  class Foo < Usergrid::Ironhorse::Base; end
-  Foo.validates :name, :presence => true
-
-  class Bar < Usergrid::Ironhorse::Base; end
-
-  describe 'subclasses should be able to' do
-
-    it "do tasks as admin when requested" do
-      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
-      organization.logout
-
-      # should fail under current user's context
-      expect {
-        organization.create_application "_test_app_#{SecureRandom.hex}"
-      }.to raise_error RestClient::Unauthorized
-
-      # should succeed under admin context
-      User.as_admin do
-        organization.create_application "_test_app_#{SecureRandom.hex}"
-      end
-    end
-
-    it "do tasks as admin if require_login is false" do
-      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
-      organization.logout
-
-      # should fail under current user's context
-      expect {
-        organization.create_application "_test_app_#{SecureRandom.hex}"
-      }.to raise_error RestClient::Unauthorized
-
-      # should succeed once require_login is false
-      User.settings[:require_login] = false
-      organization.create_application "_test_app_#{SecureRandom.hex}"
-      User.settings[:require_login] = true
-    end
-
-    it 'be created and destroyed' do
-      foo = Foo.create name: 'foo man'
-      foo.persisted?.should be_true
-      foo.name.should eq 'foo man'
-      foo = Foo.find_by_name 'foo man'
-      foo.should_not be_nil
-      foo.destroy.should be_true
-      foo.persisted?.should be_false
-      foo = Foo.find_by_name 'foo man'
-      foo.should be_nil
-    end
-
-    it 'be changed and saved' do
-      foo = Foo.find_by_name @foo.name
-      foo.answer.should eq @foo.answer
-      foo.number = 43
-      foo.changed?.should be_true
-      foo.number.should == 43
-      foo.save!
-      foo = Foo.find_by_name @foo.name
-      foo.number.should == 43
-    end
-
-    it 'be reloaded' do
-      foo = Foo.find @foo.uuid
-      foo.answer = 44
-      foo.changed?.should be_true
-      foo.answer.should == 44
-      foo.reload
-      foo.answer.should == 42
-    end
-
-    it 'be found using find_by_name' do
-      foo = Foo.find_by_name @foo.name
-      foo.uuid.should_not be_nil
-      foo.name.should eq @foo.name
-      foo.should be_a Foo
-      foo.persisted?.should be_true
-    end
-
-    it 'be found using find_by_name!' do
-      foo = Foo.find_by_name! @foo.name
-      foo.uuid.should_not be_nil
-      foo.name.should eq @foo.name
-      foo.should be_a Foo
-      foo.persisted?.should be_true
-    end
-
-    it 'throw a RecordNotFound when find_by_name! misses' do
-      expect { Foo.find_by_name! 'name3' }.to raise_error(ActiveRecord::RecordNotFound)
-    end
-
-    it 'add a validation' do
-      foo = Foo.new
-      foo.valid?.should be_false
-      foo.name = 'joe'
-      foo.valid?.should be_true
-    end
-
-    it 'fail to save an invalid record and save the errors' do
-      foo = Foo.new
-      foo.save.should be_false
-      foo.persisted?.should be_false
-      foo.errors.count.should == 1
-      foo.errors.get(:name).first.should eq "can't be blank"
-    end
-
-    it 'fail to create an invalid record and save the errors' do
-      foo = Foo.create
-      foo.persisted?.should be_false
-      foo.errors.count.should == 1
-      foo.errors.get(:name).first.should eq "can't be blank"
-    end
-
-    it 'fail to save! an invalid record' do
-      expect { Foo.new.save! }.to raise_error(ActiveRecord::RecordNotSaved)
-    end
-
-    it 'fail to create! an invalid record' do
-      expect { Foo.create! }.to raise_error(ActiveRecord::RecordNotSaved)
-    end
-
-    it 'retrieve first' do
-      foo2 = Foo.create! name: 'foo2'
-      foo = Foo.first
-      foo.uuid.should eq @foo.uuid
-      foo2.destroy
-    end
-
-    it 'retrieve last' do
-      foo2 = Foo.create! name: 'foo2'
-      foo = Foo.last
-      foo.uuid.should eq foo2.uuid
-      foo2.destroy
-    end
-
-    it 'take multiple' do
-      foo2 = Foo.create! name: 'foo2'
-      foos = Foo.take(2)
-      foos.size.should == 2
-      foos.first.uuid.should_not be_nil
-      foo2.destroy
-    end
-
-    it 'find multiple by id' do
-      foo2 = Foo.create name: 'foo2'
-      foos = Foo.find @foo.uuid, foo2.uuid
-      foos.size.should == 2
-      foos.first.uuid.should eq @foo.uuid
-      foos.last.uuid.should eq foo2.uuid
-      foo2.destroy
-    end
-
-    it 'find multiple by name' do
-      foo2 = Foo.create! name: 'foo2'
-      foos = Foo.find @foo.name, foo2.name
-      foos.size.should == 2
-      foos.first.uuid.should eq @foo.uuid
-      foos.last.uuid.should eq foo2.uuid
-      foo2.destroy
-    end
-
-    it 'check exists?(string)' do
-      Foo.exists?(@foo.name).should be_true
-    end
-
-    it 'check not exists?(string)' do
-      Foo.exists?('asdfasdf').should be_false
-    end
-
-    it 'check exists?(Array)' do
-      Foo.exists?(['name = ?', @foo.name]).should be_true
-    end
-
-    it 'check not exists?(Array)' do
-      Foo.exists?(['name = ?', 'asdfasdf']).should be_false
-    end
-
-    it 'check exists?(Hash)' do
-      Foo.exists?(name: @foo.name).should be_true
-    end
-
-    it 'check not exists?(Hash)' do
-      Foo.exists?(name: 'asfasdf').should be_false
-    end
-
-    it 'check exists?(nil)' do
-      Foo.exists?.should be_true
-    end
-
-    it 'check not exists?(nil)' do
-      Bar.exists?.should be_false
-    end
-
-    it 'perform first_or_create where found' do
-      foo = Foo.where(name: @foo.name).first_or_create
-      foo.uuid.should eq @foo.uuid
-    end
-
-    it 'perform first_or_create where not found' do
-      foo = Foo.where(name: 'foo2').first_or_create(number: 42)
-      foo.name.should eq 'foo2'
-      foo.number.should == 42
-      foo.destroy
-    end
-
-    it 'perform first_or_create! where found' do
-      foo = Foo.where(name: @foo.name).first_or_create!
-      foo.uuid.should eq @foo.uuid
-    end
-
-    it 'perform first_or_create! where not found' do
-      expect { Foo.where(nuumber: 'foo2').first_or_create! }.to raise_error(ActiveRecord::RecordNotSaved)
-    end
-
-    it 'perform first_or_initialize where found' do
-      foo = Foo.where(name: @foo.name).first_or_initialize(xxx: 42)
-      foo.uuid.should eq @foo.uuid
-      foo.xxx.should be_nil
-    end
-
-    it 'perform first_or_initialize where not found' do
-      foo = Foo.where(name: 'foo2').first_or_initialize(number: 42)
-      foo.name.should eq 'foo2'
-      foo.number.should == 42
-      foo.persisted?.should be_false
-    end
-
-    it "should destroy by id" do
-      foo = Foo.create! name: 'foo'
-      Foo.destroy(foo.id)
-      foo = Foo.find_by_name 'foo'
-      foo.should be_nil
-    end
-
-    it "should destroy by ids" do
-      foo = Foo.create! name: 'foo'
-      foo2 = Foo.create! name: 'foo2'
-      Foo.destroy([foo.id, foo2.id])
-      Foo.find_by_name('foo').should be_nil
-      Foo.find_by_name('foo2').should be_nil
-    end
-
-    it "should destroy_all" do
-      foo = Foo.create! name: 'foo', number: 42
-      foo2 = Foo.create! name: 'foo2', number: 42
-      Foo.destroy_all(number: 42)
-      Foo.find_by_name('foo').should be_nil
-      Foo.find_by_name('foo2').should be_nil
-    end
-
-    it "should delete by id" do
-      foo = Foo.create! name: 'foo'
-      Foo.delete(foo.id)
-      foo = Foo.find_by_name 'foo'
-      foo.should be_nil
-    end
-
-    it "should delete by ids" do
-      foo = Foo.create! name: 'foo'
-      foo2 = Foo.create! name: 'foo2'
-      Foo.delete([foo.id, foo2.id])
-      Foo.find_by_name('foo').should be_nil
-      Foo.find_by_name('foo2').should be_nil
-    end
-
-    it "should delete_all" do
-      foo = Foo.create! name: 'foo', number: 42
-      foo2 = Foo.create! name: 'foo2', number: 42
-      Foo.delete_all(number: 42)
-      Foo.find_by_name('foo').should be_nil
-      Foo.find_by_name('foo2').should be_nil
-    end
-
-    it "should update one" do
-      foo = Foo.create! name: 'foo', number: 42
-      Foo.update foo.uuid, { number: 43 }
-      foo.reload.number.should == 43
-      foo.destroy
-    end
-
-    it "should update multiple" do
-      foo = Foo.create! name: 'foo', number: 42
-      foo2 = Foo.create! name: 'foo2', number: 42
-      updates = { foo.uuid => {number: 43}, foo2.uuid => {number: 44}}
-      Foo.update(updates.keys, updates.values)
-      foo.reload.number.should == 43
-      foo2.reload.number.should == 44
-      foo.destroy
-      foo2.destroy
-    end
-
-    it "should update_all" do
-      foo = Foo.create! name: 'foo', number: 43
-      Foo.where(number: 43).update_all({number: 44})
-      Foo.find_by_number(44).should_not be_nil
-      foo.destroy
-    end
-
-    it "should fail on unaccessible mass assignment" do
-      Foo.attr_accessible :name
-      foo = Foo.create! name: 'foo', number: 43
-      foo.number.should_not eq 43
-      foo.update_attributes number: 44, foo: 'bar'
-      foo.number.should_not eq 44
-      foo.destroy
-      Foo._accessible_attributes = nil
-    end
-
-    it "should fail on protected mass assignment" do
-      Foo.attr_protected :number
-      foo = Foo.create! name: 'foo', number: 43
-      foo.number.should_not eq 43
-      foo.update_attributes number: 44, foo: 'bar'
-      foo.number.should_not eq 44
-      foo.destroy
-      Foo._protected_attributes = nil
-    end
-
-    it "should be able to page through results" do
-      bars = (1..15).collect do |i|
-        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
-      end
-      query = Bar.all
-      page = query.to_a # first page
-      page.count.should eq 10
-      page = query.next_page # second page
-      count = 10
-      page.each do |bar|
-        bars[count].name.should eq bar.name
-        count += 1
-      end
-      count.should eq bars.count
-      bars.each {|bar| bar.delete}
-    end
-
-    it "should iterate past page boundaries" do
-      bars = (1..15).collect do |i|
-        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
-      end
-      count = 0
-      Bar.all.each do |bar|
-        bars[count].name.should eq bar.name
-        count += 1
-      end
-      count.should eq bars.count
-      bars.each {|bar| bar.delete}
-    end
-
-    it "should honor limit" do
-      bars = (1..15).collect do |i|
-        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
-      end
-      count = 0
-      Bar.limit(13).each do |bar|
-        bars[count].name.should eq bar.name
-        count += 1
-      end
-      count.should eq 13
-      bars.each {|bar| bar.delete}
-    end
-
-    it "perform as admin only when requested if require_login is true" do
-
-      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
-
-      creds = nil
-      User.as_admin do
-        creds = organization.credentials
-      end
-
-      Usergrid::Ironhorse::Base.settings[:client_id] = creds.data.credentials.client_id
-      Usergrid::Ironhorse::Base.settings[:client_secret] = creds.data.credentials.client_secret
-      Usergrid::Ironhorse::Base.settings[:auth_token] = nil
-      User.clear_thread_context
-      organization.logout
-      User.settings[:require_login] = true
-
-      # should fail (login is required)
-      expect {
-        organization.create_application "_test_app_#{SecureRandom.hex}"
-      }.to raise_error RestClient::Unauthorized
-
-      # should succeed under admin context
-      User.as_admin do
-        organization.create_application "_test_app_#{SecureRandom.hex}"
-      end
-
-      Usergrid::Ironhorse::Base.settings[:client_id] = nil
-      Usergrid::Ironhorse::Base.settings[:client_secret] = nil
-    end
-
-    it "perform as admin if require_login is false" do
-
-      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
-      organization.logout
-
-      creds = nil
-      User.as_admin do
-        creds = organization.credentials
-      end
-
-      Usergrid::Ironhorse::Base.settings[:client_id] = creds.data.credentials.client_id
-      Usergrid::Ironhorse::Base.settings[:client_secret] = creds.data.credentials.client_secret
-      Usergrid::Ironhorse::Base.settings[:auth_token] = nil
-      User.clear_thread_context
-      organization.logout
-
-      User.settings[:require_login] = false
-
-      # should succeed
-      organization.create_application "_test_app_#{SecureRandom.hex}"
-
-      Usergrid::Ironhorse::Base.settings[:client_id] = nil
-      Usergrid::Ironhorse::Base.settings[:client_secret] = nil
-    end
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/usergrid_ironhorse.gemspec
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/usergrid_ironhorse.gemspec b/sdks/ruby-on-rails/usergrid_ironhorse.gemspec
deleted file mode 100644
index 430c5c1..0000000
--- a/sdks/ruby-on-rails/usergrid_ironhorse.gemspec
+++ /dev/null
@@ -1,44 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# -*- encoding: utf-8 -*-
-lib = File.expand_path('../lib', __FILE__)
-$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
-require 'usergrid_ironhorse/version'
-
-Gem::Specification.new do |gem|
-  gem.name          = "usergrid_ironhorse"
-  gem.version       = Usergrid::Ironhorse::VERSION
-  gem.authors       = ["Scott Ganyo"]
-  gem.email         = ["scott@ganyo.com"]
-  gem.description   = %q{Rails ActiveModel gem to access Usergrid / Apigee App Services}
-  gem.summary       = %q{Usergrid_ironhorse enables simple ActiveModel access to Apigee's App Services
-                        (aka Usergrid) REST API for Rails developers.}
-  gem.homepage      = "https://github.com/scottganyo/usergrid_ironhorse"
-
-  gem.files         = `git ls-files`.split($/)
-  gem.executables   = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
-  gem.test_files    = gem.files.grep(%r{^(test|spec|features)/})
-  gem.require_paths = ["lib"]
-
-  gem.add_dependency 'usergrid_iron', '0.9.1'
-  gem.add_dependency 'activemodel', '~> 3.2'
-  gem.add_dependency 'activerecord', '~> 3.2'
-  gem.add_dependency 'i18n'
-
-  gem.add_development_dependency 'rake'
-  gem.add_development_dependency 'rspec'
-  gem.add_development_dependency 'simplecov'
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/ruby/.gitignore b/sdks/ruby/.gitignore
deleted file mode 100644
index 30b994d..0000000
--- a/sdks/ruby/.gitignore
+++ /dev/null
@@ -1,18 +0,0 @@
-*.gem
-*.rbc
-.bundle
-.config
-.yardoc
-Gemfile.lock
-InstalledFiles
-_yardoc
-coverage
-doc/
-lib/bundler/man
-pkg
-rdoc
-spec/reports
-test/tmp
-test/version_tmp
-tmp
-.idea
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/.rspec
----------------------------------------------------------------------
diff --git a/sdks/ruby/.rspec b/sdks/ruby/.rspec
deleted file mode 100644
index c99d2e7..0000000
--- a/sdks/ruby/.rspec
+++ /dev/null
@@ -1 +0,0 @@
---require spec_helper

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/.rvmrc
----------------------------------------------------------------------
diff --git a/sdks/ruby/.rvmrc b/sdks/ruby/.rvmrc
deleted file mode 100644
index 55148ad..0000000
--- a/sdks/ruby/.rvmrc
+++ /dev/null
@@ -1,2 +0,0 @@
-rvm_gemset_create_on_use_flag=1
-rvm gemset use 'usergrid_iron'

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/Gemfile
----------------------------------------------------------------------
diff --git a/sdks/ruby/Gemfile b/sdks/ruby/Gemfile
deleted file mode 100644
index 9a6d84d..0000000
--- a/sdks/ruby/Gemfile
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-source 'https://rubygems.org'
-
-# Specify your gem's dependencies in usergrid_iron.gemspec
-gemspec

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/ruby/LICENSE b/sdks/ruby/LICENSE
deleted file mode 100644
index ae1e83e..0000000
--- a/sdks/ruby/LICENSE
+++ /dev/null
@@ -1,14 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/README.md
----------------------------------------------------------------------
diff --git a/sdks/ruby/README.md b/sdks/ruby/README.md
deleted file mode 100644
index 2f6c594..0000000
--- a/sdks/ruby/README.md
+++ /dev/null
@@ -1,268 +0,0 @@
-# Ruby SDK
-
-Usergrid_iron enables simple, low-level Ruby access to Apigee's App Services (aka Usergrid)
-REST API with minimal dependencies.
-
-## Installation
-
-### Project
-Add the gem to your project's Gemfile:
-
-    gem 'usergrid_iron'
-
-Then rebuild your bundle:
-
-    $ bundle
-
-### Stand-alone script
-Just manually install the gem:
-
-    $ gem install usergrid_iron
-
-
-## Usage
-
-### Prerequisite
-You'll want to be at least a little bit familiar with Usergrid / Apigee's App Services before you jump in here - but it easy and it's great! Start here:
-
-  App Services docs: <http://apigee.com/docs/usergrid/>
-  Open source stack: <https://github.com/apigee/usergrid-stack>
-
-Awesome. Let's go!
-
-### Getting started with the Usergrid_iron SDK is simple!
-
-#### Let's start with the basics.
-For this example, we'll assume you've already set up an organization, application, and user -
-just fill in your own values in the code below.
-
-```ruby
-require 'usergrid_iron'
-
-# fill in your values here!
-usergrid_api = 'http://localhost:8080'
-organization = ''
-application = ''
-username = ''
-password = ''
-
-# create the base application resource
-# (this is a RestClient.resource)
-application = Usergrid::Application.new "#{usergrid_api}/#{organization}/#{application}"
-
-# login (note: not required for sandbox)
-application.login username, password
-
-# create and store a new dog on the server
-# (the "response" is an enhanced RestClient.response)
-response = application.create_dog breed: 'Black Mouth Cur', name: 'Old Yeller'
-
-# the response has returned the entity data
-# response.entity wraps it in an easy-to-use object
-dog = response.entity
-
-# it's persistent now, so it has a unique id
-uuid = dog.uuid
-
-# we can retrieve the dog by UUID using Hash syntax and calling get()
-# (all dogs are stored in the "dogs" collection)
-response = application["dogs"][uuid].get
-same_dog = response.entity
-
-# we could also retrieve the dog by name
-# we could also use path ('/') syntax instead of nested Hash
-# and we can even skip get() - entity() will do it for us
-same_dog = application["dogs/#{dog.name}"].entity
-
-# is it our dog? well, he knows his name!
-# (and we can retrieve its values by dot or Hash)
-puts "My dog's name is: #{same_dog.name} and his breed is #{same_dog['breed']}"
-```
-
-Well that was really easy. More comments than code! :)
-
-#### Let's try something slightly more complex.
-Let's say you've registered for an organization, but you don't have an application yet
-(or want to create a new one to work on). No worries, just fill in your organization and
-superuser credentials below, and follow along!
-(Better yet: If you used the Usergrid launcher and let it initialize your database,
-you shouldn't need to do anything!)
-
-```ruby
-  require 'usergrid_iron'
-
-  usergrid_api = 'http://localhost:8080'
-  org_name = 'test-organization'
-  username = 'test'
-  password = 'test'
-  app_name = 'dog_sitter'
-
-  ## first, let's get that setup out of the way... ##
-
-  # get a management context & login the superuser
-  management = Usergrid::Management.new usergrid_api
-  management.login username, password
-
-  # get the organization context & create a new application
-  organization = management.organization org_name
-  new_application = organization.create_application app_name
-
-  # create an user for our application
-  new_application.create_user username: 'username', password: 'password'
-
-  # login to our new application as our new user
-  application = organization.application app_name
-  application.login 'username', 'password'
-
-
-  ## now we can play with the puppies! ##
-
-  # we can start with our dog again
-  application.create_dog breed: 'Black Mouth Cur', name: 'Old Yeller'
-
-  # but this time let's create several more dogs all at once
-  application.create_dogs [
-      { breed: 'Catalan sheepdog', name: 'Einstein' },
-      { breed: 'Cocker Spaniel', name: 'Lady' },
-      { breed: 'Mixed', name: 'Benji' }]
-
-  # retrieve all the dogs (well, the first 'page' anyway) and tell them hi!
-  # note: we're calling collection() instead of entity() because we have several
-  dogs = application['dogs'].collection
-
-  # you can iterate a collection just like an array
-  dogs.each do |dog|
-    puts "Hello, #{dog.name}!"
-  end
-
-  # Let's get Benji ("Benji, come!"), but this time we'll retrieve by query
-  response = dogs.query "select * where name = 'Benji'"
-
-  # we could call "response.collection.first"
-  # but there's a shortcut: entity() will also return the first
-  benji = response.entity
-
-  # modify Benji's attributes & save to the server
-  benji.location = 'home'                     # use attribute access
-  benji['breed'] = 'American Cocker Spaniel'  # or access attributes like a Hash
-  benji.save
-
-  # now query for the dogs that are home (should just be Benji)
-  dogs = application['dogs'].query("select * where location = 'home'").collection
-  if dogs.size == 1 && dogs.first.location == 'home'
-    puts "Benji's home!"
-  end
-
-```
-
-Whew. That's enough for now. But looking for a specific feature? Check out the [rspecs](http://github.com/scottganyo/usergrid_iron/tree/master/spec/usergrid/core),
-there are examples of nearly everything!
-
-
-## Contributing
-
-We welcome your enhancements!
-
-1. Fork it
-2. Create your feature branch (`git checkout -b my-new-feature`)
-3. Write some broken rspecs.
-4. Fix the rspecs with your new code.
-3. Commit your changes (`git commit -am 'Added some feature'`)
-4. Push your changes to the upstream branch (`git push origin my-new-feature`)
-5. Create new Pull Request
-
-We've got 100% rspec coverage and we're looking to keep it that way!
-In order to run the tests, check out the Usergrid open source project
-(https://github.com/apigee/usergrid-stack), build, and launch it locally.
-
-(Note: If you change your local Usergrid setting from the default, be sure to update
-usergrid_iron/spec/spec_settings.yaml to match.)
-
-
-## Release notes
-
-### 0.9.2
-* New features
-  1. delete_query (batch delete by query)
-
-### 0.9.1
-* New features
-  1. may now login using credentials: application.login_credentials() or organization.login_credentials()
-
-### 0.9.0
-* Backend changes
-  1. login function now uses POST instead of GET
-
-### 0.0.9
-* Backend changes
-  1. made Resource::response accessor public to support ugc
-
-### 0.0.8
-* Bug fixes
-  1. better handling of paging
-
-### 0.0.7
-* Bug fixes
-  1. multiple_entities? should check data['list']
-
-### 0.0.6
-* New features
-  1. iterators can now optionally cross page boundaries, eg. `collection.follow_cursor.each`
-  2. added facebook_login(fb_access_token) method to application
-
-### 0.0.5
-* New features
-  1. added create_* method for application
-* Backend changes
-  1. eliminated serialization of reserved attributes
-* Incompatible changes
-  1. deprecated `Application::create_user username, password, ...`, use `create_user username: 'user', password: 'password'`
-
-### 0.0.4
-* New features
-  1. empty? check for collection
-  2. update queries (batch update)
-* Backend changes
-  1. Additional data sanity checks
-  2. Additional flexibility in concat_urls
-  3. Cleanup
-
-### 0.0.3
-* New features
-  1. Support for lists returned when making parameterized queries:
-	 <pre>select username, email where\u2026</pre>
-	 or replacement queries:
-	 <pre>select { user:username, email:email } where\u2026
-* Incompatible changes
-  1. Application.create_user parameter change from:
-     <pre>create_user(username, name, email, password, invite=false)</pre>
-     to:
-     <pre>create_user(username, password, email=nil, name=nil, invite=false)</pre>
-* Backend changes
-  1. Replaced json_pure dependency with multi_json
-
-
-## Notes
-
-The following features are not currently implemented on the server:
-
-* delete organization
-* delete application
-* delete user
-
-
-## License
-Licensed to the Apache Software Foundation (ASF) under one or more
-contributor license agreements.  See the NOTICE file distributed with
-this work for additional information regarding copyright ownership.
-the ASF licenses this file to You under the Apache License, Version 2.0
-(the "License"); you may not use this file except in compliance with
-the License.  You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/Rakefile
----------------------------------------------------------------------
diff --git a/sdks/ruby/Rakefile b/sdks/ruby/Rakefile
deleted file mode 100644
index bc86b58..0000000
--- a/sdks/ruby/Rakefile
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-#!/usr/bin/env rake
-require "bundler/gem_tasks"
-
-require 'rspec/core/rake_task'
-RSpec::Core::RakeTask.new(:spec)
-
-RSpec::Core::RakeTask.new("spec:coverage")

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/bin/autospec
----------------------------------------------------------------------
diff --git a/sdks/ruby/bin/autospec b/sdks/ruby/bin/autospec
deleted file mode 100755
index 64dcb9c..0000000
--- a/sdks/ruby/bin/autospec
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/env ruby
-#
-# This file was generated by Bundler.
-#
-# The application 'autospec' is installed as part of a gem, and
-# this file is here to facilitate running it.
-#
-
-require 'pathname'
-ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
-  Pathname.new(__FILE__).realpath)
-
-require 'rubygems'
-require 'bundler/setup'
-
-load Gem.bin_path('rspec-core', 'autospec')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/bin/htmldiff
----------------------------------------------------------------------
diff --git a/sdks/ruby/bin/htmldiff b/sdks/ruby/bin/htmldiff
deleted file mode 100755
index c70e238..0000000
--- a/sdks/ruby/bin/htmldiff
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/env ruby
-#
-# This file was generated by Bundler.
-#
-# The application 'htmldiff' is installed as part of a gem, and
-# this file is here to facilitate running it.
-#
-
-require 'pathname'
-ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
-  Pathname.new(__FILE__).realpath)
-
-require 'rubygems'
-require 'bundler/setup'
-
-load Gem.bin_path('diff-lcs', 'htmldiff')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/bin/ldiff
----------------------------------------------------------------------
diff --git a/sdks/ruby/bin/ldiff b/sdks/ruby/bin/ldiff
deleted file mode 100755
index 8e3524a..0000000
--- a/sdks/ruby/bin/ldiff
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/env ruby
-#
-# This file was generated by Bundler.
-#
-# The application 'ldiff' is installed as part of a gem, and
-# this file is here to facilitate running it.
-#
-
-require 'pathname'
-ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
-  Pathname.new(__FILE__).realpath)
-
-require 'rubygems'
-require 'bundler/setup'
-
-load Gem.bin_path('diff-lcs', 'ldiff')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/bin/restclient
----------------------------------------------------------------------
diff --git a/sdks/ruby/bin/restclient b/sdks/ruby/bin/restclient
deleted file mode 100755
index 4d7bdcf..0000000
--- a/sdks/ruby/bin/restclient
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/env ruby
-#
-# This file was generated by Bundler.
-#
-# The application 'restclient' is installed as part of a gem, and
-# this file is here to facilitate running it.
-#
-
-require 'pathname'
-ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
-  Pathname.new(__FILE__).realpath)
-
-require 'rubygems'
-require 'bundler/setup'
-
-load Gem.bin_path('rest-client', 'restclient')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/bin/rspec
----------------------------------------------------------------------
diff --git a/sdks/ruby/bin/rspec b/sdks/ruby/bin/rspec
deleted file mode 100755
index 0c86b5c..0000000
--- a/sdks/ruby/bin/rspec
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/usr/bin/env ruby
-#
-# This file was generated by Bundler.
-#
-# The application 'rspec' is installed as part of a gem, and
-# this file is here to facilitate running it.
-#
-
-require 'pathname'
-ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
-  Pathname.new(__FILE__).realpath)
-
-require 'rubygems'
-require 'bundler/setup'
-
-load Gem.bin_path('rspec-core', 'rspec')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby/lib/usergrid/core/application.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby/lib/usergrid/core/application.rb b/sdks/ruby/lib/usergrid/core/application.rb
deleted file mode 100644
index 9cc85c4..0000000
--- a/sdks/ruby/lib/usergrid/core/application.rb
+++ /dev/null
@@ -1,84 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-module Usergrid
-  class Application < Resource
-
-    def initialize(url, options={})
-      org_name = url.split('/')[-2]
-      api_url = url[0..url.index(org_name)-2]
-      super url, api_url, options
-    end
-
-    # note: collection_name s/b plural, but the server will change it if not
-    def create_entity(collection_name, entity_data)
-      self[collection_name].post entity_data
-    end
-    alias_method :create_entities, :create_entity
-
-    # allow create_something(hash_or_array) method
-    def method_missing(method, *args, &block)
-      method_s = method.to_s
-      if method_s.start_with? 'create_'
-        entity = method_s.split('_')[1]
-        return _create_user *args if entity == 'user' && args[0].is_a?(String) # backwards compatibility
-        create_entity entity, *args
-      elsif method_s.end_with? 's' # shortcut for retrieving collections
-        self[method].query(*args)
-      else
-        super method, args, block
-      end
-    end
-
-    def counter_names
-      self['counters'].get.data.data
-    end
-
-    # other_params: 'start_time' (ms), 'end_time' (ms), 'resolution' (minutes)
-    def counter(name, other_params={})
-      options = other_params.merge({counter: name})
-      self['counters'].get({params: options})
-    end
-
-    # login with Facebook token. matching user will be created in usergrid as needed.
-    # usergrid auth token automatically set in auth header for future requests
-    def facebook_login(access_token)
-      params = { fb_access_token: access_token }
-      response = self['auth/facebook'].get({ params: params })
-      self.auth_token = response.data['access_token']
-      user_uuid = response.data['user']['uuid']
-      @current_user = self["/users/#{user_uuid}"].get.entity
-      response
-    end
-
-    def login_credentials(client_id, client_secret)
-      response = self['token'].post grant_type: 'client_credentials', client_id: client_id, client_secret: client_secret
-      self.auth_token = response.data['access_token']
-    end
-
-    private
-
-    def _create_user(username, password, email=nil, name=nil, invite=false)
-      LOG.warn "create_user(username, password, ...) is deprecated"
-      user_hash = { username: username,
-                    password: password,
-                    email: email,
-                    name: name,
-                    invite: invite }
-      create_entity 'users', user_hash
-    end
-
-  end
-end


[03/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Native/Facades/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Native/Facades/Usergrid.php b/sdks/php5/apache-usergrid/src/Native/Facades/Usergrid.php
deleted file mode 100644
index fbfcffe..0000000
--- a/sdks/php5/apache-usergrid/src/Native/Facades/Usergrid.php
+++ /dev/null
@@ -1,118 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Native\Facades;
-
-
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/**
- * Class Usergrid
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Usergrid
-{
-    /**
-     * The Native Bootstrap instance.
-     *
-     * @var \Apache\Usergrid\Native\UsergridBootstrapper
-     */
-    protected static $instance;
-    /**
-     * The Usergrid API instance.
-     *
-     * @var \Apache\Usergrid\Api\Usergrid
-     */
-    protected $usergrid;
-
-    /**
-     * Constructor.
-     *
-     * @param  \Apache\Usergrid\Native\UsergridBootstrapper $bootstraper
-     * @return \Apache\Usergrid\Native\Facades\Usergrid
-     */
-    public function __construct(UsergridBootstrapper $bootstraper = null)
-    {
-        if (!$bootstraper) {
-            $bootstraper = new UsergridBootstrapper;
-        }
-
-        $this->usergrid = $bootstraper->createUsergrid();
-    }
-
-    /**
-     * Handle dynamic, static calls to the object.
-     *
-     * @param  string $method
-     * @param  array $args
-     * @return mixed
-     */
-    public static function __callStatic($method, $args)
-    {
-        $instance = static::instance()->getUsergrid();
-
-        switch (count($args)) {
-            case 0:
-                return $instance->{$method}();
-
-            case 1:
-                return $instance->{$method}($args[0]);
-
-            case 2:
-                return $instance->{$method}($args[0], $args[1]);
-
-            case 3:
-                return $instance->{$method}($args[0], $args[1], $args[2]);
-
-            case 4:
-                return $instance->{$method}($args[0], $args[1], $args[2], $args[3]);
-
-            default:
-                return call_user_func_array([$instance, $method], $args);
-        }
-    }
-
-    /**
-     * Creates a new Native Bootstraper instance.
-     *
-     * @param  \Apache\Usergrid\Native\UsergridBootstrapper $bootstrapper
-     * @return static
-     */
-    public static function instance(UsergridBootstrapper $bootstrapper = null)
-    {
-        if (static::$instance === null) {
-            static::$instance = new static($bootstrapper);
-        }
-
-        return static::$instance;
-    }
-
-    /**
-     * Returns the Usergrid API instance.
-     *
-     * @return \Apache\Usergrid\Api\Usergrid
-     */
-    public function getUsergrid()
-    {
-        return $this->usergrid;
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Native/UsergridBootstrapper.php b/sdks/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
deleted file mode 100644
index 0f71b78..0000000
--- a/sdks/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
+++ /dev/null
@@ -1,150 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Native;
-
-
-use Apache\Usergrid\Api\Usergrid;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\ClientCredentials;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\PasswordCredentials;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\RefreshToken;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
-use Guzzle\Http\Client;
-
-/**
- * Class UsergridBootstrapper
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UsergridBootstrapper
-{
-    /**
-     * The Usergrid configuration.
-     *
-     * @var array
-     */
-    protected $config;
-
-    /**
-     * The Oauth2 Plugin.
-     *
-     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin
-     */
-    protected $oauth2Plugin = null;
-
-    /**
-     * Constructor.
-     *
-     * @param  mixed $config
-     * @return \Apache\Usergrid\Native\UsergridBootstrapper
-     */
-    public function __construct($config = null)
-    {
-        $this->config = $config ?: new ConfigRepository($config);
-    }
-
-    /**
-     * Creates the Usergrid instance.
-     *
-     * @return \Apache\Usergrid\Api\Usergrid
-     */
-    public function createUsergrid()
-    {
-        $baseUrl = array_get($this->config, 'usergrid.url');
-
-        $orgName = array_get($this->config, 'usergrid.orgName');
-
-        $appName = array_get($this->config, 'usergrid.appName');
-
-        $manifestPath = array_get($this->config, 'usergrid.manifestPath');
-
-        $version = array_get($this->config, 'usergrid.version');
-
-        $enable_oauth2_plugin = array_get($this->config, 'usergrid.enable_oauth2_plugin');
-
-        //check if user wants to manage there own Oauth 2 auth flow
-        if ($enable_oauth2_plugin) {
-
-            $this->createOauth2Plugin();
-
-            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl, $this->oauth2Plugin);
-        } else {
-            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl);
-        }
-
-    }
-
-    private function createOauth2Plugin()
-    {
-        $base_url = array_get($this->config, 'usergrid.url');
-
-        $client_id = array_get($this->config, 'usergrid.clientId');
-
-        $client_secret = array_get($this->config, 'usergrid.clientSecret');
-
-        $grant_type = array_get($this->config, 'usergrid.grant_type');
-
-        $auth_type = array_get($this->config, 'usergrid.auth_type');
-
-        $username = array_get($this->config, 'usergrid.username');
-
-        $password = array_get($this->config, 'usergrid.password');
-
-
-        $org_name = array_get($this->config, 'usergrid.orgName');
-
-        $app_name = array_get($this->config, 'usergrid.appName');
-
-        if ($auth_type == 'organization') {
-
-            $url = $base_url . '/management/token';
-
-        } elseif ($auth_type == 'application') {
-            $url = $base_url . '/' . $org_name . '/' . $app_name . '/token';
-        }
-
-        $oauth2Client = new Client($url);
-
-
-        if ($grant_type == 'client_credentials') {
-            $config = [
-                'client_id' => $client_id,
-                'client_secret' => $client_secret,
-
-            ];
-            $grantType = new ClientCredentials($oauth2Client, $config);
-            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
-            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
-
-        } elseif ($grant_type == 'password') {
-            $config = [
-                'username' => $username,
-                'password' => $password,
-                'client_id' => $client_id,
-                'client_secret' => $client_secret
-            ];
-            $grantType = new PasswordCredentials($oauth2Client, $config);
-            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
-            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
-        }
-    }
-
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/config/config.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/config/config.php b/sdks/php5/apache-usergrid/src/config/config.php
deleted file mode 100644
index 75a886f..0000000
--- a/sdks/php5/apache-usergrid/src/config/config.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'usergrid' => [
-
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.0',
-        'orgName' => null,
-        'appName' => null,
-        'manifestPath' => null,
-        //its better not to set the real values here if using laravel set them in a .env file or
-        // if your not using Laravel set them as environment variable and include them here using $_ENV global.
-        // so that way you can be sure not to commit privates ID to a public repo
-        'clientId' => null,
-        'clientSecret' => null,
-        'username' => null,
-        'password' => null,
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/ApplicationTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/ApplicationTest.php b/sdks/php5/apache-usergrid/tests/Api/ApplicationTest.php
deleted file mode 100644
index d25a205..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/ApplicationTest.php
+++ /dev/null
@@ -1,72 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api;
-
-
-use Apache\Usergrid\Api\Exception\UsergridException;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class ApplicationTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ApplicationTest extends PHPUnit_Framework_TestCase
-{
-
-    /**
-     * Usergrid client
-     *
-     * @var Usergrid $usergrid
-     */
-    protected $usergrid;
-
-    protected $config;
-
-    /**
-     *
-     */
-    public function setUp()
-    {
-        $this->usergrid = $GLOBALS['usergrid'];
-    }
-
-    /**
-     * @test
-     * @group internet
-     */
-    public function it_can_get_entity()
-    {
-
-        $error = null;
-
-        try {
-            $this->usergrid->application()->EntityGet(['collection' => 'users']);
-        } catch (UsergridException  $e) {
-            $error = $e;
-        }
-
-        $this->assertNull($error, 'Exception should be null');
-    }
-
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/AttributeTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/AttributeTest.php b/sdks/php5/apache-usergrid/tests/Api/AttributeTest.php
deleted file mode 100644
index cc1f29e..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/AttributeTest.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api;
-
-
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class AttributeTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class AttributeTest extends PHPUnit_Framework_TestCase
-{
-    /** @var  Usergrid Api Client */
-    protected $usergrid;
-
-
-    /**
-     * Setup resources and dependencies
-     *
-     * @return void
-     */
-    public function setup()
-    {
-        $this->usergrid = $GLOBALS['usergrid'];
-    }
-
-    /**
-     * @test
-     * @group internet
-     */
-    public function it_should_have_attribute()
-    {
-        $this->assertTrue(method_exists('Apache\Usergrid\Api\Models\User', 'deviceAttribute'),
-            'Class does not have method Attribute Method'
-        );
-    }
-}
- 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php b/sdks/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
deleted file mode 100644
index b716e3d..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Exception;
-
-use Apache\Usergrid\Api\Exception\BadRequestException;
-use Guzzle\Http\Message\Response;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class BadRequestExceptionTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class BadRequestExceptionTest extends PHPUnit_Framework_TestCase
-{
-
-    /** @test */
-    public function it_can_create_the_exception()
-    {
-        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
-        $command
-            ->expects($this->once())
-            ->method('getRequest')
-            ->will($this->returnValue(
-                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
-            ));
-
-        $response = new Response(400);
-        $response->setBody('');
-
-        /** @noinspection PhpParamsInspection */
-        $exception = BadRequestException::fromCommand($command, $response);
-
-        $this->assertInstanceOf(
-            'Apache\Usergrid\Api\Exception\BadRequestException',
-            $exception
-        );
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php b/sdks/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
deleted file mode 100644
index b74aa64..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Exception;
-
-use Apache\Usergrid\Api\Exception\InvalidIdException;
-use Guzzle\Http\Message\Response;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class InvalidIdExceptionTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class InvalidIdExceptionTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_create_the_exception()
-    {
-        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
-        $command
-            ->expects($this->once())
-            ->method('getRequest')
-            ->will($this->returnValue(
-                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
-            ));
-
-        $response = new Response(400);
-        $response->setBody('');
-
-        /** @noinspection PhpParamsInspection */
-        $exception = InvalidIdException::fromCommand($command, $response);
-
-        $this->assertInstanceOf(
-            'Apache\Usergrid\Api\Exception\InvalidIdException',
-            $exception
-        );
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php b/sdks/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
deleted file mode 100644
index c264751..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
+++ /dev/null
@@ -1,57 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Exception;
-
-use Apache\Usergrid\Api\Exception\NotFoundException;
-use Guzzle\Http\Message\Response;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class UnauthorizedExceptionTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class NotFoundExceptionTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_create_the_exception()
-    {
-        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
-        $command
-            ->expects($this->once())
-            ->method('getRequest')
-            ->will($this->returnValue(
-                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
-            ));
-
-        $response = new Response(404);
-        $response->setBody('');
-
-        /** @noinspection PhpParamsInspection */
-        $exception = NotFoundException::fromCommand($command, $response);
-
-        $this->assertInstanceOf(
-            'Apache\Usergrid\Api\Exception\NotFoundException',
-            $exception
-        );
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php b/sdks/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
deleted file mode 100644
index 514288f..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Exception;
-
-use Apache\Usergrid\Api\Exception\ServerErrorException;
-use Guzzle\Http\Message\Response;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class ServerErrorException
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ServerErrorExceptionTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_create_the_exception()
-    {
-        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
-        $command
-            ->expects($this->once())
-            ->method('getRequest')
-            ->will($this->returnValue(
-                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
-            ));
-
-        $response = new Response(400);
-        $response->setBody('');
-
-        /** @noinspection PhpParamsInspection */
-        $exception = ServerErrorException::fromCommand($command, $response);
-
-        $this->assertInstanceOf(
-            'Apache\Usergrid\Api\Exception\ServerErrorException',
-            $exception
-        );
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php b/sdks/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
deleted file mode 100644
index 889e7de..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
+++ /dev/null
@@ -1,58 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Exception;
-
-
-use Apache\Usergrid\Api\Exception\UnauthorizedException;
-use Guzzle\Http\Message\Response;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class UnauthorizedExceptionTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UnauthorizedExceptionTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_create_the_exception()
-    {
-        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
-        $command
-            ->expects($this->once())
-            ->method('getRequest')
-            ->will($this->returnValue(
-                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
-            ));
-
-        $response = new Response(401);
-        $response->setBody('');
-
-        /** @noinspection PhpParamsInspection */
-        $exception = UnauthorizedException::fromCommand($command, $response);
-
-        $this->assertInstanceOf(
-            'Apache\Usergrid\Api\Exception\UnauthorizedException',
-            $exception
-        );
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php b/sdks/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
deleted file mode 100644
index 1550a55..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
+++ /dev/null
@@ -1,45 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Filters;
-
-
-use Apache\Usergrid\Api\Filters\Boolean;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class BooleanTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class BooleanTest extends PHPUnit_Framework_TestCase
-{
-
-    /** @test */
-    public function it_can_convert_booleans()
-    {
-        $this->assertEquals('true', Boolean::convert(1));
-        $this->assertEquals('true', Boolean::convert(true));
-
-        $this->assertEquals('false', Boolean::convert(0));
-        $this->assertEquals('false', Boolean::convert(false));
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/Filters/DateTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/Filters/DateTest.php b/sdks/php5/apache-usergrid/tests/Api/Filters/DateTest.php
deleted file mode 100644
index 13d37f6..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/Filters/DateTest.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api\Filters;
-
-
-use Apache\Usergrid\Api\Filters\Date;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class DateTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class DateTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_convert_dates()
-    {
-
-        $this->assertEquals('Tue, Oct 14, 2014 3:55 AM', Date::convert(1413258923819));
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/ManagementTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/ManagementTest.php b/sdks/php5/apache-usergrid/tests/Api/ManagementTest.php
deleted file mode 100644
index 46ea21c..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/ManagementTest.php
+++ /dev/null
@@ -1,59 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api;
-
-
-use Apache\Usergrid\Api\Exception\UsergridException;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class ManagementTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ManagementTest extends PHPUnit_Framework_TestCase
-{
-    protected $usergrid;
-    protected $config;
-
-    public function setUp()
-    {
-        $this->usergrid = $GLOBALS['usergrid'];
-    }
-
-    /**
-     * @test
-     * @group internet
-     */
-    public function it_can_make_management_call()
-    {
-        $error = null;
-
-        try {
-            $this->usergrid->management()->OrgAppsGet();
-        } catch (UsergridException $e) {
-            $error = $e;
-        }
-
-        $this->assertNull($error, "Should be no exception if  manifest files exits and sdk can make management calls");
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php b/sdks/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
deleted file mode 100644
index eaa7b0b..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
+++ /dev/null
@@ -1,40 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api;
-
-
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class QueryAggregatorTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class QueryAggregatorTest extends PHPUnit_Framework_TestCase
-{
-
-    /** @test */
-    public function it_can_test_the_aggregate_method()
-    {
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Api/UsergridTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Api/UsergridTest.php b/sdks/php5/apache-usergrid/tests/Api/UsergridTest.php
deleted file mode 100644
index 0c7a340..0000000
--- a/sdks/php5/apache-usergrid/tests/Api/UsergridTest.php
+++ /dev/null
@@ -1,153 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Tests\Api;
-
-use Apache\Usergrid\Api\Exception\UnauthorizedException;
-use PHPUnit_Framework_TestCase;
-
-/**
- * Class UsergridTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UsergridTest extends PHPUnit_Framework_TestCase
-{
-
-    /** @var  Usergrid Api Client */
-    protected $usergrid;
-
-    protected $config;
-
-    /**
-     * Setup resources and dependencies
-     *
-     * @return void
-     */
-    public function setup()
-    {
-        $this->usergrid = $GLOBALS['usergrid'];
-    }
-
-    /**
-     * @test
-     * @group internet
-     */
-    public function it_can_retrieve_oauth2_token()
-    {
-        $error = null;
-
-        try {
-            $this->usergrid->application()->EntityGet(['collection' => 'roles']);
-        } catch (UnauthorizedException $e) {
-            $error = $e;
-        }
-
-        $this->assertNull($error, 'Exception should be null if authorized');
-    }
-
-    /** @test */
-    public function it_can_set_the_oauth2_token()
-    {
-        $this->usergrid->setToken('ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890');
-
-        $this->assertEquals('ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890', $this->usergrid->getToken());
-    }
-
-    /** @test */
-    public function it_can_retrieve_user_agent()
-    {
-
-        $this->assertEquals('BaaS-Usergrid/1.0.0', $this->usergrid->getUserAgent());
-    }
-
-    /** @test */
-    public function it_can_set_the_user_agent()
-    {
-
-        $this->usergrid->setUserAgent('Foo/Bar');
-
-        $this->assertEquals('Foo/Bar', $this->usergrid->getUserAgent());
-    }
-
-    /** @test */
-    public function it_can_retrieve_the_manifest_path()
-    {
-
-        $this->assertEquals($this->usergrid->getManifestPath(), $this->usergrid->getManifestPath());
-    }
-
-    /** @test */
-    public function it_can_set_the_manifest_path()
-    {
-        $this->usergrid->setManifestPath('/usr/foo/bar');
-
-        $this->assertEquals('/usr/foo/bar', $this->usergrid->getManifestPath());
-    }
-
-    /** @test */
-    public function it_can_retrieve_api_version()
-    {
-        $this->assertEquals('1.0.1', $this->usergrid->getVersion());
-    }
-
-    /** @test */
-    public function it_can_set_api_version()
-    {
-        $this->usergrid->setVersion('1.0.1');
-
-        $this->assertEquals('1.0.1', $this->usergrid->getVersion());
-    }
-
-
-    /** @test */
-    public function it_can_retrieve_the_client_header()
-    {
-        $headers = $this->usergrid->getHeaders();
-
-        $expected = [
-            'Usergrid-Version' => '1.0.1',
-            'Authorization' => 'Bearer ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890'
-        ];
-
-        $this->assertEquals($headers, $expected);
-    }
-
-    /** @test */
-    public function it_can_set_client_headers()
-    {
-        $this->usergrid->setHeaders([
-            'some-header' => 'foo-bar',
-        ]);
-
-        $headers = $this->usergrid->getHeaders();
-
-        $expected = [
-            'Usergrid-Version' => '1.0.1',
-            'Authorization' => 'Bearer ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890',
-            'some-header' => 'foo-bar',
-        ];
-
-        $this->assertEquals($headers, $expected);
-    }
-
-
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php b/sdks/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
deleted file mode 100644
index 3362bfc..0000000
--- a/sdks/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
+++ /dev/null
@@ -1,53 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Tests\Laravel\Facades;
-
-use PHPUnit_Framework_TestCase;
-use ReflectionClass;
-
-/**
- * Class UsergridTest
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class UsergridTest extends PHPUnit_Framework_TestCase
-{
-    /** @test */
-    public function it_can_test_it_is_a_facade()
-    {
-        $facade = new ReflectionClass('Illuminate\Support\Facades\Facade');
-
-        $reflection = new ReflectionClass('Apache\Usergrid\Laravel\Facades\Usergrid');
-
-        $this->assertTrue($reflection->isSubclassOf($facade));
-    }
-
-    /** @test */
-    public function it_can_test_it_is_a_facade_accessor()
-    {
-        $reflection = new ReflectionClass('Apache\Usergrid\Laravel\Facades\Usergrid');
-
-        $method = $reflection->getMethod('getFacadeAccessor');
-        $method->setAccessible(true);
-
-
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/tests/bootstrap.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/tests/bootstrap.php b/sdks/php5/apache-usergrid/tests/bootstrap.php
deleted file mode 100644
index edc11d1..0000000
--- a/sdks/php5/apache-usergrid/tests/bootstrap.php
+++ /dev/null
@@ -1,61 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-include('vendor/autoload.php');
-
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-$config = [
-
-    'usergrid' => [
-
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1',
-        'orgName' => null,
-        'appName' => null,
-        'manifestPath' => null,
-        //its better not to set the real values here if using laravel set them in a .env file or
-        // if your not using Laravel set them as environment variable and include them here using $_ENV global.
-        // so that way you can be sure not to commit privates ID to a public repo
-        'clientId' => null,
-        'clientSecret' => null,
-        'username' => null,
-        'password' => null,
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$boot = new UsergridBootstrapper($config);
-$usergrid = $boot->createUsergrid();
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/Gemfile
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/Gemfile b/sdks/ruby-on-rails/Gemfile
deleted file mode 100644
index 60aff2b..0000000
--- a/sdks/ruby-on-rails/Gemfile
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-source 'https://rubygems.org'
-
-# Specify your gem's dependencies in usergrid_ironhorse.gemspec
-gemspec

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/LICENSE.txt
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/LICENSE.txt b/sdks/ruby-on-rails/LICENSE.txt
deleted file mode 100644
index ae1e83e..0000000
--- a/sdks/ruby-on-rails/LICENSE.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/README.md
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/README.md b/sdks/ruby-on-rails/README.md
deleted file mode 100644
index dce855b..0000000
--- a/sdks/ruby-on-rails/README.md
+++ /dev/null
@@ -1,212 +0,0 @@
-# Apache Usergrid_ironhorse
-
-Usergrid_ironhorse is based on Usergrid_iron and enables Ruby or Rails applications
-native Rails-style access to Apigee's App Services (aka Usergrid) REST API.
-
-## Compatibility
-
-**Usergrid_ironhorse is currently only compatible with Ruby on Rails 3.2.**
-
-Thus, if you are using Rails 4.x, you must use Usergrid_iron (the low-level API for Ruby).
-Alternatively, we would welcome your contributions to make Usergrid_ironhorse compatible with Rails 4.x. Thanks!
-
-## Installation
-
-Add this line to your application's Gemfile:
-
-    gem 'usergrid_ironhorse'
-
-And then execute:
-
-    $ bundle
-
-Or install it yourself as:
-
-    $ gem install usergrid_ironhorse
-
-
-## Usage
-
-### Not familiar with Usergrid's App Services?
-
-#### It's great stuff! Check it out, here:
-
-  Docs: <https://usergrid.apache.org/docs/>  
-  Open source: <https://github.com/usergrid/usergrid/>
-
-### Getting started with the Usergrid_ironhorse SDK is super simple!
-
-#### Setup
-
-* Add 'gem usergrid_ironhorse' to your Gemfile
-* Create a 'config/usergrid.yml' file that looks something like this (the
-auth_token is your application token):
-
-```
-development:
-  application_url: http://localhost:8080/my-organization/my-application
-  client_id: YXA6BVYasLdNEeKBd1A2yYstg
-  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
-  require_login: false
-
-test:
-  application_url: http://localhost:8080/my-organization/my-application
-  client_id: YXA6BVYasLdNEeKBd1A2yYstg
-  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
-  require_login: false
-
-production:
-  application_url: http://api.usergrid.com/my-organization/my-application
-  client_id: YXA6BVYasLdNEeKBd1A2yYstg
-  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
-  require_login: false
-```
-
-#### Get going!
-
-* Subclass Usergrid::Ironhorse::Base for your models.
-Your models will automatically be stored in a collection according to the name of your
-class as defined by Rails' ActiveModel::Naming module. (Which you may override by
-implementing model_name if desired.)
-
-```
-class Developer < Usergrid::Ironhorse::Base
-  validates :name, :presence => true  # Yes, of course you can use validation
-
-end
-```
-
-* Now just use the Rails methods you're already familiar with:
-
-```
-
-    dev = Developer.new language: 'Ruby'
-    dev.valid? # nope!
-    dev.errors # {:name=>["can't be blank"]}
-    dev.name = 'Scott'
-    dev.save!
-
-    dev = Developer.find_or_create_by_name 'Scott'
-    dev.favorite_color = 'green' # assign new attributes automatically
-
-    dev = Developer.find_by_name 'Scott'
-```
-
-* BTW: If you need to do management tasks, wrapping the work in an as_admin block
-will use the auth_token from your settings:
-
-```
-User.as_admin do
-  # do protected task
-end
-```
-
-
-#### (Optional) Need to have user-specific logins to UserGrid?
-
-* Create a User model and subclass `Usergrid::Ironhorse::Base` and `extend
-Usergrid::Ironhorse::UserContext` like so:
-
-```
-class User < Usergrid::Ironhorse::Base
-  extend Usergrid::Ironhorse::UserContext
-  ...
-end
-```
-
-* Set up your authentication
-	* Use `User.authenticate(username, password, session)` to login.
-	* Use `User.clear_authentication(session)` to log out.
-* Propogate the authentication in your ApplicationController:
-
-```
-before_filter :set_user_context
-def set_user_context
-  User.set_context session
-end
-```
-
-* Optionally, if you need to access the User from your view, you may add something
-like the following to your ApplicationController:
-
-```
-helper_method :current_user
-def current_user
-  User.current_user
-end
-```
-
-## Contributing
-
-We welcome your enhancements!
-
-1. Fork it
-2. Create your feature branch (`git checkout -b my-new-feature`)
-3. Write some broken rspecs.
-4. Fix the rspecs with your new code.
-3. Commit your changes (`git commit -am 'Added some feature'`)
-4. Push your changes to the upstream branch (`git push origin my-new-feature`)
-5. Create new Pull Request
-
-We're shooting for 100% rspec coverage, so keep that in mind!
-
-In order to run the tests, check out the Usergrid open source project
-(https://github.com/usergrid/usergrid/), build, and launch it locally.
-
-(Note: If you change your local Usergrid settings from the default, be sure to update
-usergrid_ironhorse/spec/spec_settings.yaml to match.)
-
-
-## Release notes
-
-### 0.1.1
-* New Features
-  1. Now prefer application client_id and client_secret (instead of auth_token) in usergrid.yml.
-
-### 0.1.0
-* New Features
-  1. next_page() added to return the next page of results from the server. An example of this used in conjunction
-     with to_a() is in base_spec.rb (see "should be able to page through results").
-* Incompatible changes
-  1. each() iteration will now transparently cross page boundaries (as generally expected by Rails users).
-     You may use limit(n) to restrict the result set, but note that limit will retrieve the number of entities
-     specified as a single batch (no paging).
-
-### 0.0.5
-* New Features
-  1. support MassAssignmentSecurity (attr_accessible & attr_protected)
-
-### 0.0.4
-* New Features
-  1. add require_login to config (with ability to skip individual logins)
-
-### 0.0.3
-* Internal
-  1. Improve authentication and user propagation
-
-### 0.0.2
-* New Features
-  1. Authentication and user propagation features
-
-### 0.0.1
-* Initial commit
-  1. Support for most ActiveModel stuff including Validations
-  1. No scoping support
-
-
-## License
-Licensed to the Apache Software Foundation (ASF) under one or more
-contributor license agreements.  See the NOTICE file distributed with
-this work for additional information regarding copyright ownership.
-the ASF licenses this file to You under the Apache License, Version 2.0
-(the "License"); you may not use this file except in compliance with
-the License.  You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/Rakefile
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/Rakefile b/sdks/ruby-on-rails/Rakefile
deleted file mode 100644
index 632aa48..0000000
--- a/sdks/ruby-on-rails/Rakefile
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/usr/bin/env rake
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require "bundler/gem_tasks"
-
-require 'rspec/core/rake_task'
-RSpec::Core::RakeTask.new(:spec)
-
-RSpec::Core::RakeTask.new("spec:coverage")

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/extensions/hash.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/extensions/hash.rb b/sdks/ruby-on-rails/lib/extensions/hash.rb
deleted file mode 100644
index a82062a..0000000
--- a/sdks/ruby-on-rails/lib/extensions/hash.rb
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-class Hash
-
-  def nested_under_indifferent_access
-    self
-  end
-
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/extensions/resource.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/extensions/resource.rb b/sdks/ruby-on-rails/lib/extensions/resource.rb
deleted file mode 100644
index b858b92..0000000
--- a/sdks/ruby-on-rails/lib/extensions/resource.rb
+++ /dev/null
@@ -1,66 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
-# overrides methods dealing with auth_token to operate on a thread basis
-module Usergrid
-  class Resource
-
-    def options
-      options = @options.clone
-      require_login = Ironhorse::Base.settings[:require_login] != false
-      if require_login
-        auth_token = Thread.current[:usergrid_auth_token]
-      else
-        unless Ironhorse::Base.settings[:auth_token]
-          as_admin {}
-        end
-        auth_token = Ironhorse::Base.settings[:auth_token]
-      end
-      options[:headers].delete :Authorization
-      options[:headers][:Authorization] = "Bearer #{auth_token}" if auth_token
-      options
-    end
-
-    def as_admin(&block)
-      save_auth_token = Thread.current[:usergrid_auth_token]
-      begin
-        unless Ironhorse::Base.settings[:auth_token]
-          resource = RestClient::Resource.new Ironhorse::Base.settings[:application_url]
-          response = resource['token'].post grant_type: 'client_credentials', client_id: Ironhorse::Base.settings[:client_id], client_secret: Ironhorse::Base.settings[:client_secret]
-          Ironhorse::Base.settings[:auth_token] = MultiJson.load(response)['access_token']
-        end
-        Thread.current[:usergrid_auth_token] = Ironhorse::Base.settings[:auth_token]
-        yield block
-      ensure
-        Thread.current[:usergrid_auth_token] = save_auth_token
-      end
-    end
-
-    # gets user token and automatically set auth header for future requests on this Thread
-    # precondition: resource must already be set to the correct context (application or management)
-    def login(username, password)
-      params = { grant_type: "password", username: username, password: password }
-      response = self['token'].get({ params: params })
-      user_uuid = response.data['user']['uuid']
-      user_access_token = response.data['access_token']
-      Thread.current[:usergrid_user_id] = user_uuid
-      Thread.current[:usergrid_auth_token] = user_access_token
-      @current_user = self["/users/#{user_uuid}"].get.entity
-      response
-    end
-
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/usergrid_ironhorse.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/usergrid_ironhorse.rb b/sdks/ruby-on-rails/lib/usergrid_ironhorse.rb
deleted file mode 100644
index 0dde1d1..0000000
--- a/sdks/ruby-on-rails/lib/usergrid_ironhorse.rb
+++ /dev/null
@@ -1,39 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'logger'
-require 'active_model'
-require 'rest-client'
-require 'active_support'
-require 'usergrid_iron'
-require 'active_record/errors'
-
-module Usergrid
-  module Ironhorse
-
-    Dir[Pathname.new(File.dirname(__FILE__)).join("extensions/**/*.rb")].each { |f| require f }
-
-    USERGRID_PATH = File.join File.dirname(__FILE__), 'usergrid_ironhorse'
-
-    def self.usergrid_path *path
-      File.join USERGRID_PATH, *path
-    end
-
-    require usergrid_path('base')
-    require usergrid_path('query')
-
-    autoload :UserContext, usergrid_path('user_context')
-  end
-end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ruby-on-rails/lib/usergrid_ironhorse/base.rb
----------------------------------------------------------------------
diff --git a/sdks/ruby-on-rails/lib/usergrid_ironhorse/base.rb b/sdks/ruby-on-rails/lib/usergrid_ironhorse/base.rb
deleted file mode 100644
index aa6f4d9..0000000
--- a/sdks/ruby-on-rails/lib/usergrid_ironhorse/base.rb
+++ /dev/null
@@ -1,370 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-require 'active_record/validations'
-require 'active_record/errors'
-require 'active_record/callbacks'
-
-module Usergrid
-  module Ironhorse
-
-    class Base
-      include ActiveModel::AttributeMethods
-      include ActiveModel::Conversion
-      include ActiveModel::Validations
-      include ActiveModel::Dirty
-      include ActiveModel::Serialization
-      include ActiveModel::MassAssignmentSecurity
-      extend  ActiveModel::Naming
-      extend  ActiveModel::Callbacks
-
-      RESERVED_ATTRIBUTES = %w(metadata created modified uuid type uri)
-
-      define_model_callbacks :create, :destroy, :save, :update
-
-      # todo: determine the subset to support...
-      # unsupported: :group, :joins, :preload, :eager_load, :includes, :from, :lock,
-      #              :having, :create_with, :uniq, :references, :none, :count,
-      #              :average, :minimum, :maximum, :sum, :calculate, :ids
-      #              :find_each, :find_in_batches, :offset, :readonly
-
-      #delegate :find, :take, :take!, :first, :first!, :last, :last!, :exists?, :any?, :many?, :to => :all
-      #delegate :first_or_create, :first_or_create!, :first_or_initialize, :to => :all
-      #delegate :find_by, :find_by!, :to => :all
-      #delegate :destroy, :destroy_all, :delete, :delete_all, :update, :update_all, :to => :all
-      #delegate :find_each, :find_in_batches, :to => :all
-      #delegate :select, :group, :order, :except, :reorder, :limit, :offset,
-      #         :where, :preload, :eager_load, :includes, :from, :lock, :readonly,
-      #         :having, :create_with, :uniq, :references, :none, :to => :all
-      #delegate :count, :average, :minimum, :maximum, :sum, :calculate, :pluck, :ids, :to => :all
-
-      @@settings ||= nil
-
-      attr_accessor :attributes
-
-      HashWithIndifferentAccess = ActiveSupport::HashWithIndifferentAccess
-      RecordNotSaved = ActiveRecord::RecordNotSaved
-
-      def initialize(attrs=nil)
-        @attributes = HashWithIndifferentAccess.new
-        assign_attributes attrs if attrs
-      end
-
-      def self.configure!(application_url, auth_token)
-        @@settings = HashWithIndifferentAccess.new application_url: application_url, auth_token: auth_token
-      end
-
-      def self.settings
-        return @@settings if @@settings
-        path = "config/usergrid.yml"
-        environment = defined?(Rails) && Rails.respond_to?(:env) ? Rails.env : ENV['RACK_ENV']
-        @@settings = HashWithIndifferentAccess.new YAML.load(ERB.new(File.new(path).read).result)[environment]
-      end
-
-      # forward to all
-      def self.method_missing(method, *args, &block)
-        all.send method, *args, &block
-      end
-
-      # forward to all
-      def method_missing(method, *args, &block)
-        if args.size == 0
-          attributes[method]
-        elsif args.size == 1 && method[-1] == '='
-          attr = method[0..-2]
-          if attributes[attr] != args[0]
-            attribute_will_change!(attr)
-            attributes[attr] = args[0]
-          end
-        else
-          all.send method, *args, &block
-        end
-      end
-
-      # todo: scopes
-      def self.all
-        unscoped
-      end
-
-      #def self.scope(symbol, scope)
-      #  @scopes[symbol] = scope
-      #end
-
-      #def self.current_scope
-      #  @current_scope ||= default_scope
-      #end
-      #
-      #def self.current_scope=(scope)
-      #  @current_scope = scope
-      #end
-      #
-      #def self.default_scope
-      #  @default_scope ||= unscoped
-      #end
-
-      def self.unscoped
-        Query.new(self)
-      end
-
-      def self.create(attributes=nil, options=nil, &block)
-        if attributes.is_a?(Array)
-          attributes.collect { |attr| create(attr, options, &block) }
-        else
-          object = new(attributes, &block)
-          object.save
-          object
-        end
-      end
-
-      def self.create!(attributes=nil, options=nil, &block)
-        if attributes.is_a?(Array)
-          attributes.collect {|attr| create!(attr, options, &block)}
-        else
-          object = new(attributes)
-          yield(object) if block_given?
-          object.save!
-          object
-        end
-      end
-
-      def self.class_attributes
-        @class_attributes ||= {}
-      end
-
-      # Returns true if the record is persisted, i.e. it's not a new record and it was
-      # not destroyed, otherwise returns false.
-      def persisted?
-        !(new_record? || destroyed?)
-      end
-
-      def new_record?
-        !self.uuid
-      end
-
-      def self.group
-        model_name.plural.downcase
-      end
-
-      # Creates a Usergrid::Resource
-      def self.resource
-        app = Usergrid::Application.new settings[:application_url]
-        #app.auth_token = Thread.current[:usergrid_auth_token]
-        app[group]
-      end
-
-      # Saves the model.
-      #
-      # If the model is new a record gets created in the database, otherwise
-      # the existing record gets updated.
-      #
-      # By default, save always run validations. If any of them fail the action
-      # is cancelled and +save+ returns +false+. However, if you supply
-      # :validate => false, validations are bypassed altogether. See
-      # ActiveRecord::Validations for more information.
-      #
-      # There's a series of callbacks associated with +save+. If any of the
-      # <tt>before_*</tt> callbacks return +false+ the action is cancelled and
-      # +save+ returns +false+. See ActiveRecord::Callbacks for further
-      # details.
-      def save
-        begin
-          create_or_update
-        rescue ActiveRecord::RecordInvalid
-          false
-        end
-      end
-
-      # Saves the model.
-      #
-      # If the model is new a record gets created in the database, otherwise
-      # the existing record gets updated.
-      #
-      # With <tt>save!</tt> validations always run. If any of them fail
-      # ActiveRecord::RecordInvalid gets raised. See ActiveRecord::Validations
-      # for more information.
-      #
-      # There's a series of callbacks associated with <tt>save!</tt>. If any of
-      # the <tt>before_*</tt> callbacks return +false+ the action is cancelled
-      # and <tt>save!</tt> raises ActiveRecord::RecordNotSaved. See
-      # ActiveRecord::Callbacks for further details.
-      def save!
-        create_or_update or raise RecordNotSaved
-      end
-
-      # Deletes the record in the database and freezes this instance to
-      # reflect that no changes should be made (since they can't be
-      # persisted). Returns the frozen instance.
-      #
-      # The row is simply removed with a +DELETE+ statement on the
-      # record's primary key, and no callbacks are executed.
-      #
-      # To enforce the object's +before_destroy+ and +after_destroy+
-      # callbacks, Observer methods, or any <tt>:dependent</tt> association
-      # options, use <tt>#destroy</tt>.
-      def delete
-        self.class.delete(id) if persisted?
-        @destroyed = true
-        freeze
-      end
-
-      # Deletes the record in the database and freezes this instance to reflect
-      # that no changes should be made (since they can't be persisted).
-      #
-      # There's a series of callbacks associated with <tt>destroy</tt>. If
-      # the <tt>before_destroy</tt> callback return +false+ the action is cancelled
-      # and <tt>destroy</tt> returns +false+. See
-      # ActiveRecord::Callbacks for further details.
-      def destroy
-        raise ReadOnlyRecord if readonly?
-        # todo: callbacks?
-        instance_resource.delete if persisted?
-        @destroyed = true
-        freeze
-      end
-
-      # Deletes the record in the database and freezes this instance to reflect
-      # that no changes should be made (since they can't be persisted).
-      #
-      # There's a series of callbacks associated with <tt>destroy!</tt>. If
-      # the <tt>before_destroy</tt> callback return +false+ the action is cancelled
-      # and <tt>destroy!</tt> raises ActiveRecord::RecordNotDestroyed. See
-      # ActiveRecord::Callbacks for further details.
-      def destroy!
-        destroy || raise(ActiveRecord::RecordNotDestroyed)
-      end
-
-      # Returns true if this object has been destroyed, otherwise returns false.
-      def destroyed?
-        !!@destroyed
-      end
-
-      # Reloads the attributes of this object from the database.
-      def reload
-        return false if !persisted?
-        fresh_object = self.class.find(id)
-        refresh_data fresh_object.instance_variable_get('@attributes')
-        self
-      end
-
-      # Updates the attributes of the model from the passed-in hash and saves the
-      # record, all wrapped in a transaction. If the object is invalid, the saving
-      # will fail and false will be returned.
-      def update_attributes(attributes)
-        assign_attributes attributes
-        save
-      end
-
-      # Updates its receiver just like +update_attributes+ but calls <tt>save!</tt> instead
-      # of +save+, so an exception is raised if the record is invalid.
-      def update_attributes!(attributes)
-        assign_attributes attributes
-        save!
-      end
-
-      # Note that whenever you include ActiveModel::AttributeMethods in your class,
-      # it requires you to implement an +attributes+ method which returns a hash
-      # with each attribute name in your model as hash key and the attribute value as
-      # hash value.
-      #
-      # Hash keys must be strings.
-      def attributes
-        @attributes ||= self.class.class_attributes.clone
-      end
-
-      def id; self.uuid end
-      def created_at; self.created end
-      def updated_at; self.modified end
-
-
-      protected
-
-
-      def assign_attributes(attrs)
-        attrs = sanitize_for_mass_assignment(attrs)
-        attrs.each do |attr,value|
-          attr = attr.to_s
-          unless attributes[attr] == value
-            attribute_will_change!(attr) unless RESERVED_ATTRIBUTES.include? attr
-            attributes[attr] = value
-          end
-        end
-      end
-
-      def create_or_update
-        raise ReadOnlyRecord if readonly?
-        if valid?
-          run_callbacks :save do
-            return new_record? ? do_create : do_update
-          end
-        end
-        false
-      end
-
-      def do_create
-        group_resource.post(unsaved_attributes) do |resp, req, res, &block|
-          if resp.code.to_s == "200" || resp.code.to_s == "201"
-            refresh_data resp.entity_data
-            return true
-          else
-            errors.add(resp.code.to_s, resp)
-            return false
-          end
-        end
-      end
-
-      def do_update
-        return false unless changed?
-
-        instance_resource.put(unsaved_attributes) do |resp, req, res, &block|
-          if resp.code.to_s == "200" || resp.code.to_s == "201"
-            refresh_data resp.entity_data
-            return true
-          else
-            errors.add(resp.code, resp)
-            return false
-          end
-        end
-      end
-
-      def unsaved_attributes
-        HashWithIndifferentAccess[changed.collect {|k| [k, attributes[k]]}]
-      end
-
-      def group_resource
-        self.class.resource
-      end
-
-      def instance_resource
-        self.class.resource["#{self.id}"]
-      end
-
-      def refresh_data(entity_data)
-        @previously_changed = changes
-        @changed_attributes.clear
-        @attributes = HashWithIndifferentAccess.new entity_data
-      end
-
-      def attribute_will_change!(attr)
-        begin
-          value = __send__(attr)
-          value = value.duplicable? ? value.clone : value
-        rescue TypeError, NoMethodError
-        end
-
-        changed_attributes[attr] = value unless changed_attributes.include?(attr)
-      end
-    end
-  end
-end


[17/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/management.json
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/management.json b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/management.json
new file mode 100644
index 0000000..8323222
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/management.json
@@ -0,0 +1,1905 @@
+{
+    "basePath": "${basePath}",
+    "swaggerVersion": "1.1-SHAPSHOT.121026",
+    "apiVersion": "0.1",
+    "apis": [
+        {
+            "path": "/management/token",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_auth_password_get",
+                    "summary": "Get management access token",
+                    "notes": "Get the management access token.  See the OAuth2 specification for details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "grant_type",
+                            "dataType": "string",
+                            "description": "Grant type",
+                            "defaultValue": "password",
+                            "allowableValues": {
+                                "values": [
+                                    "password",
+                                    "client_credentials",
+                                    "refresh_token",
+                                    "authorization_code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_secret",
+                            "dataType": "string",
+                            "description": "Client Secret (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_auth_password_post",
+                    "summary": "Get management access token",
+                    "notes": "Get the management access token.  See the OAuth2 specification for details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "grant_type",
+                            "dataType": "string",
+                            "description": "Grant type",
+                            "defaultValue": "password",
+                            "allowableValues": {
+                                "values": [
+                                    "password",
+                                    "client_credentials",
+                                    "refresh_token",
+                                    "authorization_code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "client_secret",
+                            "dataType": "string",
+                            "description": "Client Secret (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/authorize",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_authorize_get",
+                    "summary": "Authorize client",
+                    "notes": "Authorize the client.  See the OAuth2 specification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "response_type",
+                            "dataType": "string",
+                            "description": "Response type",
+                            "defaultValue": "token",
+                            "allowableValues": {
+                                "values": [
+                                    "token",
+                                    "code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "redirect_uri",
+                            "dataType": "string",
+                            "description": "Redirect URI",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "scope",
+                            "dataType": "string",
+                            "description": "Access Token Scope",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "state",
+                            "dataType": "string",
+                            "description": "Client State",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_authorize_post",
+                    "summary": "Authorize client",
+                    "notes": "Authorize the client.  See the OAuth2 specification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "response_type",
+                            "dataType": "string",
+                            "description": "Response type",
+                            "defaultValue": "token",
+                            "allowableValues": {
+                                "values": [
+                                    "token",
+                                    "code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "redirect_uri",
+                            "dataType": "string",
+                            "description": "Redirect URI",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "scope",
+                            "dataType": "string",
+                            "description": "Access Token Scope",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "state",
+                            "dataType": "string",
+                            "description": "Client State",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_json_post",
+                    "summary": "Create new organization",
+                    "notes": "Create new organization.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Organization to post",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_form_post",
+                    "summary": "Create new organization",
+                    "notes": "Create new organization using form post parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "organization",
+                            "dataType": "string",
+                            "description": "Organization",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Admin Username",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "name",
+                            "dataType": "string",
+                            "description": "Admin Name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "Admin Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Admin Password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_get",
+                    "summary": "Find organization by name or UUID",
+                    "notes": "Returns the organization details",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/activate",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_activate_get",
+                    "summary": "Activates the organization",
+                    "notes": "Activates the organization from link provided in email notification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "token",
+                            "dataType": "string",
+                            "description": "Activation Token (supplied via email)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "confirm",
+                            "dataType": "boolean",
+                            "description": "Send confirmation email",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/reactivate",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_reactivate_get",
+                    "summary": "Reactivates the organization",
+                    "notes": "Request organization reactivation.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/feed",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_feed_get",
+                    "summary": "Get organization activity feed",
+                    "notes": "Get organization activity feed.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/credentials",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_credentials_get",
+                    "summary": "Get organization client credentials",
+                    "notes": "Get the organization client credentials.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_credentials_post",
+                    "summary": "Generate organization client credentials",
+                    "notes": "Generate new organization client credentials.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/users",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_users_get",
+                    "summary": "Get admin users for organization",
+                    "notes": "Get admin users for organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_users_json_post",
+                    "summary": "Create new admin user for organization",
+                    "notes": "Create new admin user for organization using JSON payload.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Admin user to create",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_users_form_post",
+                    "summary": "Create new admin user for organization",
+                    "notes": "Create new admin user for organization using form parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Admin Username",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "name",
+                            "dataType": "string",
+                            "description": "Admin Name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "Admin Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Admin Password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "mgt_org_user_put",
+                    "summary": "Add admin users to organization",
+                    "notes": "Adds existing admin users for organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin user username, email, or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "DELETE",
+                    "nickname": "mgt_org_user_delete",
+                    "summary": "Remove admin user from organization",
+                    "notes": "Remove an admin user from organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin user username, email, or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/apps",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_apps_get",
+                    "summary": "Get apps for organization",
+                    "notes": "Get apps for organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_apps_json_post",
+                    "summary": "Create new application for organization",
+                    "notes": "Create new application for organization using JSON payload.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Application to create",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_apps_form_post",
+                    "summary": "Create new application for organization",
+                    "notes": "Create new application for organization using form parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "name",
+                            "dataType": "string",
+                            "description": "Application Name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "DELETE",
+                    "nickname": "mgt_org_app_delete",
+                    "summary": "Delete an application in an organization",
+                    "notes": "Delete an application in an organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Application name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_app_credentials_get",
+                    "summary": "Get application keys",
+                    "notes": "Get application keys.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Application name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_app_credentials_post",
+                    "summary": "Generate application keys",
+                    "notes": "Generate application keys.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Application name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_user_json_post",
+                    "summary": "Create new admin user",
+                    "notes": "Create new admin user.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Admin user to post",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_user_form_post",
+                    "summary": "Create new organization",
+                    "notes": "Create new admin using form post parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Admin Username",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "name",
+                            "dataType": "string",
+                            "description": "Admin Name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "Admin Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Admin Password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/resetpw",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_org_user_reset_password_get",
+                    "summary": "Initiate a user password reset",
+                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_org_user_reset_password_form_post",
+                    "summary": "Complete a user password reset",
+                    "notes": "Complete a user password reset.  Handles form POST response.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "Admin Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_challenge_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Challenge Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_response_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Response Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_get",
+                    "summary": "Returns the admin user details",
+                    "notes": "Returns the admin user details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "mgt_admin_user_json_put",
+                    "summary": "Updates the admin user details",
+                    "notes": "Updates the admin user details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Admin user details",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/activate",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_activate_get",
+                    "summary": "Activates the admin user",
+                    "notes": "Activates the admin user from link provided in email notification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "token",
+                            "dataType": "string",
+                            "description": "Activation Token (supplied via email)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "confirm",
+                            "dataType": "boolean",
+                            "description": "Send confirmation email",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/reactivate",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_reactivate_get",
+                    "summary": "Reactivates the admin user",
+                    "notes": "Request admin user reactivation.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/feed",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_feed_get",
+                    "summary": "Get admin user activity feed",
+                    "notes": "Get admin user activity feed.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/password",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "mgt_admin_user_password_json_put",
+                    "summary": "Set admin user password",
+                    "notes": "Set admin user password.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Old and new password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/resetpw",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_reset_password_get",
+                    "summary": "Initiate a user password reset",
+                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_admin_user_reset_password_form_post",
+                    "summary": "Complete a user password reset",
+                    "notes": "Complete a user password reset.  Handles form POST response.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "recaptcha_challenge_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Challenge Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_response_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Response Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Organization not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/orgs",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "mgt_admin_user_orgs_get",
+                    "summary": "Get organizations for admin user",
+                    "notes": "Get organizations for admin user.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_admin_user_orgs_json_post",
+                    "summary": "Create new organization for admin user",
+                    "notes": "Create new organization for admin user using JSON payload.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Organization to create",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "mgt_admin_user_orgs_form_post",
+                    "summary": "Create new organization for admin user",
+                    "notes": "Create new organization for admin user using form parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "organization",
+                            "dataType": "string",
+                            "description": "Organization name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}",
+            "description": "Management",
+            "operations": [
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "mgt_admin_user_org_put",
+                    "summary": "Add admin user to organization",
+                    "notes": "Add admin users to organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin user username, email, or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "DELETE",
+                    "nickname": "mgt_admin_user_org_delete",
+                    "summary": "Remove admin user from organization",
+                    "notes": "Remove an admin user from organization.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "Admin user username, email, or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "org_name_or_uuid",
+                            "dataType": "string",
+                            "description": "Organization name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        }
+    ],
+    "models": {
+        "response": {
+            "properties": {
+                "id": {
+                    "type": "long"
+                },
+                "name": {
+                    "type": "string"
+                }
+            },
+            "id": "response"
+        }
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/resources.json b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
new file mode 100644
index 0000000..8a6ffad
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
@@ -0,0 +1,15 @@
+{
+    "basePath": "${basePath}",
+    "swaggerVersion": "1.1-SHAPSHOT.121026",
+    "apiVersion": "0.1",
+    "apis": [
+        {
+            "path": "/applications.{format}",
+            "description": "Applications"
+        },
+        {
+            "path": "/management.{format}",
+            "description": "Management"
+        }
+    ]
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Native/ConfigRepository.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Native/ConfigRepository.php b/sdks/other/php5/apache-usergrid/src/Native/ConfigRepository.php
new file mode 100644
index 0000000..b6febf0
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Native/ConfigRepository.php
@@ -0,0 +1,102 @@
+<?php namespace Apache\Usergrid\Native;
+
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+use ArrayAccess;
+
+/**
+ * Class ConfigRepository
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ConfigRepository implements ArrayAccess
+{
+
+    /**
+     * The config file path.
+     *
+     * @var string
+     */
+    protected $file;
+
+    /**
+     * The config data.
+     *
+     * @var array
+     */
+    protected $config = [];
+
+    /**
+     * Constructor.
+     *
+     * @param  string $file
+     * @return \Apache\Usergrid\Native\ConfigRepository
+     */
+    public function __construct($file)
+    {
+        $this->file = $file;
+
+        $this->load();
+    }
+
+    /**
+     * Load the configuration file.
+     *
+     * @return void
+     */
+    protected function load()
+    {
+        $this->config = require $this->file;
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    public function offsetExists($key)
+    {
+        return isset($this->config[$key]);
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    public function offsetGet($key)
+    {
+        return $this->config[$key];
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    public function offsetSet($key, $value)
+    {
+        $this->config[$key] = $value;
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    public function offsetUnset($key)
+    {
+        unset($this->config[$key]);
+    }
+
+}


[32/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGQuery.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGQuery.h b/sdks/other/ios/UGAPI/UGQuery.h
new file mode 100755
index 0000000..b77e0a4
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGQuery.h
@@ -0,0 +1,104 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+#import <CoreLocation/CoreLocation.h>
+
+enum
+{
+    kUGQueryOperationEquals = 0,
+    kUGQueryOperationLessThan = 1,
+    kUGQueryOperationLessThanOrEqualTo = 2,
+    kUGQueryOperationGreaterThan = 3,
+    kUGQueryOperationGreaterThanOrEqualTo = 4
+};
+
+/***************************************************************
+ QUERY MANAGEMENT:
+ 
+ All query functions take one of these as an optional parameter
+ (the client may send nil if desired). This will specify the
+ limitations of the query. 
+***************************************************************/
+
+@interface UGQuery : NSObject
+
+// url terms used in UG searches. Set as you like.
+// These are convenience methods. the same effect can be done
+// by calling addURLTerm
+-(void)setConsumer: (NSString *)consumer;
+-(void)setLastUUID: (NSString *)lastUUID;
+-(void)setTime: (long)time;
+-(void)setPrev: (int)prev;
+-(void)setNext: (int)next;
+-(void)setLimit: (int)limit;
+-(void)setPos: (NSString *)pos;
+-(void)setUpdate: (BOOL)update;
+-(void)setSynchronized: (BOOL)synchronized;
+
+// a general function for adding additional URL terms.
+// Note that all of the set functions above turn around and
+// call this.
+-(void)addURLTerm: (NSString *)urlTerm equals:(NSString *)equals;
+
+// ql operation requirements. For each of these, you provide the term, followed 
+// by the operation (a kUGQueryOperationXXXX constant) followed by the value
+// in whatever form you have it (NSString, int, or float are supported)
+// Example: [foo addRequiredOperation: @"age" kUGQueryLessThan valueInt:27] would
+// add the term "age < 27" to the ql.
+-(void)addRequiredOperation: (NSString *)term op:(int)op valueStr:(NSString *)valueStr;
+-(void)addRequiredOperation: (NSString *)term op:(int)op valueInt:(int) valueInt;
+
+// adds a "contains" requirement to the query. This adds the requirement that a value
+// contain a given string. Example: [foo addRequiredContains:@"hobbies value:@"fishing"]
+// would add the term "hobbies contains 'fishing'" to the ql.
+-(void)addRequiredContains: (NSString *)term value:(NSString *)value;
+
+// adds an "in" requirement to the query. This adds a requirement that a field
+// be within a certain range. Example [foo appendRequiredIn:@"age" low:16.0 high:22.0]
+// would add the term "age in 16.0,22.0" to the ql. 
+// Note that the qualifier is inclusive, meaning it is true if low <= term <= high. 
+-(void)addRequiredIn:(NSString *)term low:(int)low high:(int)high;
+
+// adds a "within" requirement. This adds a constraint that the term be within a 
+// certain distance of the sent-in x,y coordinates.
+-(void)addRequiredWithin:(NSString *)term latitude:(float)latitude longitude:(float)longitude distance:(float)distance;
+
+// assembles a "within" requirement with a term name, CLLocation, and distance
+-(void)addRequiredWithinLocation:(NSString *)term location:(CLLocation *)location distance:(float)distance;
+
+//-------------------- Oblique usage ----------------------------
+// adds a requirement to the query. The requirements will
+// *all* be sent when the query is adopted. This is an escalating
+// list as you add them. Requirements are in UG Querty language.
+// So something like "firstname='bob'". This is one of the few places
+// where the data you give will be sent to the server almost untouched. 
+// So if you make a mistake in your query, you are likely to cause the whole
+// transaction to return an error. 
+// NOTE: This is different thant URL terms. These are query terms sent along
+// to the *single* URL term "ql". 
+// Note: This is an oblique-usage function. You will find all the ql operations
+// supported in the various addRequiredXXXX functions above. You would only use
+// this function if you already have ql strings prepared for some reason, or if
+// there are new ql format operations that are not supported by this API.
+-(void)addRequirement: (NSString *)requirement;
+
+// returns the URL-ready string that detailes all specified requirements.
+// This is used internally by UGClient, you don't need to call it.
+-(NSString *)getURLAppend;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGQuery.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGQuery.m b/sdks/other/ios/UGAPI/UGQuery.m
new file mode 100755
index 0000000..740ec5c
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGQuery.m
@@ -0,0 +1,277 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGQuery.h"
+#import "UGHTTPManager.h"
+
+@implementation UGQuery
+{
+    NSMutableArray *m_requirements;
+    NSMutableString *m_urlTerms;
+}
+
+-(id)init
+{
+    self = [super init];
+    if ( self )
+    {
+        m_requirements = [NSMutableArray new];
+        m_urlTerms = [NSMutableString new];
+    }
+    return self;
+}
+
+-(void)setConsumer: (NSString *)consumer
+{
+    [self addURLTerm:@"consumer" equals:consumer];    
+}
+
+-(void)setLastUUID: (NSString *)lastUUID
+{
+    [self addURLTerm:@"last" equals:lastUUID];    
+}
+
+-(void)setTime: (long)time
+{
+    NSMutableString *str = [NSMutableString new];
+    [str appendFormat:@"%ld", time];
+    [self addURLTerm:@"time" equals:str];
+}
+
+-(void)setPrev: (int)prev
+{
+    NSMutableString *str = [NSMutableString new];
+    [str appendFormat:@"%d", prev];
+    [self addURLTerm:@"prev" equals:str];
+}
+
+-(void)setNext: (int)next
+{
+    NSMutableString *str = [NSMutableString new];
+    [str appendFormat:@"%d", next];
+    [self addURLTerm:@"next" equals:str];
+}
+
+-(void)setLimit: (int)limit
+{
+    NSMutableString *str = [NSMutableString new];
+    [str appendFormat:@"%d", limit];
+    [self addURLTerm:@"limit" equals:str];
+}
+
+-(void)setPos: (NSString *)pos
+{
+    [self addURLTerm:@"pos" equals:pos];    
+}
+
+-(void)setUpdate: (BOOL)update
+{
+    if ( update )
+    {
+        [self addURLTerm:@"update" equals:@"true"];
+    }
+    else
+    {
+        [self addURLTerm:@"update" equals:@"false"];
+    }
+}
+
+-(void)setSynchronized: (BOOL)synchronized
+{
+    if ( synchronized )
+    {
+        [self addURLTerm:@"synchronized" equals:@"true"];
+    }
+    else
+    {
+        [self addURLTerm:@"synchronized" equals:@"false"];
+    }
+}
+
+-(void)addURLTerm: (NSString *)urlTerm equals:(NSString *)equals
+{
+    // ignore anything with a nil
+    if ( !urlTerm ) return;
+    if ( !equals ) return;
+
+    // escape the strings
+    NSString *escapedUrlTerm = [UGHTTPManager escapeSpecials:urlTerm];
+    NSString *escapedEquals = [UGHTTPManager escapeSpecials:equals];
+
+    // add it in
+    if ( [m_urlTerms length] > 0 )
+    {
+        // we already have some terms. Append an & before continuing
+        [m_urlTerms appendFormat:@"&"];
+    }
+    [m_urlTerms appendFormat:@"%@=%@", escapedUrlTerm, escapedEquals];
+}
+
+-(void)addRequiredOperation: (NSString *)term op:(int)op valueStr:(NSString *)valueStr
+{
+    // disregard invalid values
+    if ( !term ) return;
+    if ( !valueStr ) return;
+    
+    NSString *opStr = [self getOpStr: op];
+    if ( !opStr ) return; // nil opStr means they sent in an invalid op code
+    
+    // assemble the requirement string
+    NSMutableString *assembled = [NSMutableString new];
+    [assembled appendFormat:@"%@ %@ '%@'", term, opStr, valueStr];
+    
+    // add it as a req
+    [self addRequirement:assembled];
+}
+
+-(void)addRequiredOperation: (NSString *)term op:(int)op valueInt:(int) valueInt
+{
+    // disregard invalid values
+    if ( !term ) return;
+    
+    NSString *opStr = [self getOpStr: op];
+    if ( !opStr ) return; // nil opStr means they sent in an invalid op code
+    
+    // assemble the requirement string
+    NSMutableString *assembled = [NSMutableString new];
+    [assembled appendFormat:@"%@ %@ %d", term, opStr, valueInt];
+    
+    // add it as a req
+    [self addRequirement:assembled];
+}
+
+-(void)addRequiredContains: (NSString *)term value:(NSString *)value
+{
+    // disregard invalid values
+    if ( !term ) return;
+    if ( !value ) return;
+    
+    // assemble the requirement string
+    NSMutableString *assembled = [NSMutableString new];
+    [assembled appendFormat:@"%@ contains '%@'", term, value];
+    
+    // add it as a req
+    [self addRequirement:assembled];
+}
+
+-(void)addRequiredIn:(NSString *)term low:(int)low high:(int)high
+{
+    // disregard invalid values
+    if ( !term ) return;
+    
+    // assemble the requirement string
+    NSMutableString *assembled = [NSMutableString new];
+    [assembled appendFormat:@"%@ in %d,%d", term, low, high];
+    
+    // add it as a req
+    [self addRequirement:assembled];    
+}
+
+-(void)addRequiredWithin:(NSString *)term latitude:(float)latitude longitude:(float)longitude distance:(float)distance;
+{
+    // disregard invalid values
+    if ( !term ) return;
+    
+    // assemble the requirement string
+    NSMutableString *assembled = [NSMutableString new];
+    [assembled appendFormat:@"%@ within %f of %f,%f", term, distance, latitude, longitude];
+    
+    // add it as a req
+    [self addRequirement:assembled];   
+}
+
+-(void)addRequiredWithinLocation:(NSString *)term location:(CLLocation *)location distance:(float)distance
+{
+    [self addRequiredWithin:term latitude:location.coordinate.latitude longitude:location.coordinate.longitude distance:distance];
+}
+
+-(void)addRequirement: (NSString *)requirement
+{
+    // add the URL-ready requirement to our list
+    [m_requirements addObject:requirement];
+}
+
+-(NSString *)getURLAppend
+{    
+    // assemble a url append for all the requirements
+    // prep a mutable string
+    NSMutableString *ret = [NSMutableString new];
+    [ret setString:@"?"];
+  
+    // true if we've put anything in the string yet.
+    BOOL bHasContent = NO;
+    
+    // start with the ql term
+    if ( [m_requirements count] > 0 )
+    {    
+        // if we're here, there are queries
+        // assemble a single string for the ql
+        NSMutableString *ql = [NSMutableString new];
+        for ( int i=0 ; i<[m_requirements count] ; i++ )
+        {
+            if ( i>0 )
+            {
+                // connect terms
+                [ql appendFormat:@" and "];
+            }
+            [ql appendFormat:@"%@", [m_requirements objectAtIndex:i]];
+        }
+        
+        // escape it
+        NSString *escapedQL = [UGHTTPManager escapeSpecials:ql];
+        [ret appendFormat:@"ql=%@", escapedQL];
+        bHasContent = YES;
+    }
+
+    if ( [m_urlTerms length] > 0 )
+    {
+        if ( bHasContent ) 
+        {
+            [ret appendFormat:@"&%@", m_urlTerms];
+        }
+        else 
+        {
+            [ret appendFormat:@"%@", m_urlTerms];
+        }
+        bHasContent = YES;
+    }
+    
+    if ( !bHasContent )
+    {
+        // no content
+        return @"";
+    }
+    
+    // all prepared
+    return ret;
+}
+
+// Internal function
+ -(NSString *)getOpStr:(int)op
+{
+    switch (op)
+    {
+        case kUGQueryOperationEquals: return @"=";
+        case kUGQueryOperationGreaterThan: return @">";
+        case kUGQueryOperationGreaterThanOrEqualTo: return @">=";
+        case kUGQueryOperationLessThan: return @"<";
+        case kUGQueryOperationLessThanOrEqualTo: return @"<=";
+    }
+    return nil;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGUser.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGUser.h b/sdks/other/ios/UGAPI/UGUser.h
new file mode 100755
index 0000000..58e3b99
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGUser.h
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import <Foundation/Foundation.h>
+
+@interface UGUser : NSObject
+
+@property NSString *username;
+@property NSString *email;
+@property NSString *uuid;
+@property NSString *picture;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/UGUser.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/UGUser.m b/sdks/other/ios/UGAPI/UGUser.m
new file mode 100755
index 0000000..d683b6d
--- /dev/null
+++ b/sdks/other/ios/UGAPI/UGUser.m
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#import "UGUser.h"
+
+@implementation UGUser
+
+@synthesize username;
+@synthesize email;
+@synthesize uuid;
+@synthesize picture;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGConnection.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGConnection.h b/sdks/other/ios/UGAPI/v2/UGConnection.h
new file mode 100644
index 0000000..d44c8e9
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGConnection.h
@@ -0,0 +1,289 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+//
+//  UGConnection.h
+//  UGAPIApp
+//
+//  Created by Tim Burks on 3/30/13.
+//
+//
+#import <Foundation/Foundation.h>
+
+@class UGHTTPResult;
+
+@interface UGConnection : NSObject
+
+// These three properties tie a  UGConnection to a specific application instance
+@property (nonatomic, strong) NSString *server;
+@property (nonatomic, strong) NSString *organization;
+@property (nonatomic, strong) NSString *application;
+
+// As a convenience, a sharedConnection object is available,
+// but any number of UGConnection objects may be created and separately configured.
++ (UGConnection *) sharedConnection;
+
+// Query helper: construct query dictionary from arguments
+- (NSMutableDictionary *) queryWithString:(NSString *) queryString
+                                    limit:(int) limit
+                                startUUID:(NSString *) startUUID
+                                   cursor:(NSString *) cursor
+                                 reversed:(BOOL) reversed;
+
+// Authentication helper: call this method with the result of a getAccessToken request.
+- (BOOL) authenticateWithResult:(UGHTTPResult *) result;
+
+// Authentication helper: use this to confirm that a connection has a usable access token.
+- (BOOL) isAuthenticated;
+
+//
+// Usergrid API methods
+//
+// The following calls return NSMutableURLRequest objects that can be used to make Usergrid API calls.
+// We recommend (but do not require) that they be made with instances of the UGHTTPClient class.
+//
+// The goal here is to directly expose the complete Usergrid API.
+//
+// This follows http://apigee.com/docs/usergrid/content/app-services-resources
+//
+
+// Access tokens http://apigee.com/docs/usergrid/content/accesstoken
+
+- (NSMutableURLRequest *) getAccessTokenForAdminWithUsername:(NSString *) username
+                                                    password:(NSString *) password;
+
+- (NSMutableURLRequest *) getAccessTokenForOrganizationWithClientID:(NSString *) clientID
+                                                       clientSecret:(NSString *) clientSecret;
+
+- (NSMutableURLRequest *) getAccessTokenForApplicationWithUsername:(NSString *) username
+                                                          password:(NSString *) password;
+
+- (NSMutableURLRequest *) getAccessTokenForApplicationWithClientID:(NSString *) clientID
+                                                      clientSecret:(NSString *) clientSecret;
+
+// Admin users http://apigee.com/docs/usergrid/content/admin-user
+
+- (NSMutableURLRequest *) createAdminUserWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) updateAdminUser:(NSString *) adminUserIdentifier
+                               withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) getAdminUser:(NSString *) adminUserIdentifier;
+
+- (NSMutableURLRequest *) setPasswordForAdminUser:(NSString *) adminUserIdentifier
+                                          toValue:(NSString *) password;
+
+- (NSMutableURLRequest *) initiatePasswordResetForAdminUser;
+
+- (NSMutableURLRequest *) completePasswordResetForAdminUserWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) activateAdminUser:(NSString *) adminUserIdentifier
+                                  withToken:(NSString *) token
+                   sendingConfirmationEmail:(BOOL) sendingConfirmationEmail;
+
+- (NSMutableURLRequest *) reactivateAdminUser:(NSString *) adminUserIdentifier;
+
+- (NSMutableURLRequest *) getActivityFeedForAdminUser:(NSString *) adminUserIdentifier;
+
+// Client authorization http://apigee.com/docs/usergrid/content/client-authorization
+
+- (NSMutableURLRequest *) authorizeClient:(NSString *) clientIdentifier withResponseType:(NSString *) responseType;
+
+// Organizations and Applications http://apigee.com/docs/usergrid/content/organization
+
+- (NSMutableURLRequest *) createOrganizationWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) getOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) activateOrganization:(NSString *) organizationIdentifier
+                                     withToken:(NSString *) token
+                      sendingConfirmationEmail:(BOOL) sendingConfirmationEmail;
+
+- (NSMutableURLRequest *) reactivateOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) generateClientCredentialsForOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getClientCredentialsForOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getActivityFeedForOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) createApplicationInOrganization:(NSString *) organizationIdentifier
+                                               withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deleteApplication:(NSString *) applicationIdentifier
+                             inOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) generateClientCredentialsForApplication:(NSString *) applicationIdentifier
+                                                   inOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getClientCredentialsForApplication:(NSString *) applicationIdentifier
+                                              inOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getApplicationsInOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) addAdminUser:(NSString *) adminUserIdentifier
+                        toOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getAdminUsersInOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) removeAdminUser:(NSString *) adminUserIdentifier
+                         fromOrganization:(NSString *) organizationIdentifier;
+
+- (NSMutableURLRequest *) getApplication:(NSString *) applicationIdentifier
+                          inOrganization:(NSString *) organizationIdentifier;
+
+// Activity http://apigee.com/docs/usergrid/content/activity
+
+- (NSMutableURLRequest *) createActivityForUser:(NSString *) userIdentifier
+                                     withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) createActivityForGroup:(NSString *) groupIdentifier
+                                      withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) createActivityForFollowersOfUser:(NSString *) userIdentifier
+                                                   inGroup:(NSString *) groupIdentifier
+                                                withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) getActivitiesForUser:(NSString *) userIdentifier;
+
+- (NSMutableURLRequest *) getActivitiesForGroup:(NSString *) groupIdentifier;
+
+- (NSMutableURLRequest *) getActivityFeedForUser:(NSString *) userIdentifier;
+
+- (NSMutableURLRequest *) getActivityFeedForGroup:(NSString *) groupIdentifier;
+
+// Assets
+
+- (NSMutableURLRequest *) getDataForAsset:(NSString *) assetIdentifier;
+
+- (NSMutableURLRequest *) postData:(NSData *) data
+                          forAsset:(NSString *) assetIdentifier;
+
+// Collections (aka General-purpose endpoints) http://apigee.com/docs/usergrid/content/general-purpose-endpoints
+
+- (NSMutableURLRequest *) createEntityInCollection:(NSString *) collection
+                                        withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) getEntity:(NSString *) entityIdentifier
+                       inCollection:(NSString *) collection;
+
+- (NSMutableURLRequest *) updateEntity:(NSString *) entityIdentifier
+                          inCollection:(NSString *) collection
+                            withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deleteEntity:(NSString *) entityIdentifier
+                          inCollection:(NSString *) collection;
+
+- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
+                                            limit:(int) limit;
+
+- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
+                                       usingQuery:(NSDictionary *) query;
+
+- (NSMutableURLRequest *) updateEntitiesInCollection:(NSString *) collection
+                                          usingQuery:(NSDictionary *) query
+                                          withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection;
+
+- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
+                                          usingQuery:(NSDictionary *) query;
+
+
+// Devices http://apigee.com/docs/usergrid/content/device
+
+// there are no device-specific methods
+
+// Events and Counters http://apigee.com/docs/usergrid/content/events-and-counters
+
+- (NSMutableURLRequest *) createEventWithValues:(NSDictionary *) values;
+
+// Groups http://apigee.com/docs/usergrid/content/group
+
+- (NSMutableURLRequest *) createGroupWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) addUser:(NSString *) userIdentifier
+                          toGroup:(NSString *) groupIdentifier;
+
+- (NSMutableURLRequest *) getGroup:(NSString *) groupIdentifier;
+
+- (NSMutableURLRequest *) updateGroup:(NSString *) groupIdentifier
+                           withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) userIdentifier
+                           fromGroup:(NSString *) groupIdentifier;
+
+- (NSMutableURLRequest *) deleteGroup:(NSString *) groupIdentifier;
+
+- (NSMutableURLRequest *) getUsersInGroup:(NSString *) groupIdentifier;
+
+// Roles http://apigee.com/docs/usergrid/content/role
+
+- (NSMutableURLRequest *) createRoleWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) getRoles;
+
+- (NSMutableURLRequest *) deleteRole:(NSString *) roleName;
+
+- (NSMutableURLRequest *) getPermissionsForRole:(NSString *) roleName;
+
+- (NSMutableURLRequest *) addPermissionsToRole:(NSString *) roleName
+                                    withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deletePermissionsFromRole:(NSString *) roleName
+                                       usingPattern:(NSString *) pattern;
+
+- (NSMutableURLRequest *) addUser:(NSString *)userIdentifier
+                           toRole:(NSString *)roleName;
+
+- (NSMutableURLRequest *) getUsersInRole:(NSString *) roleName;
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) userIdentifier
+                            fromRole:(NSString *) roleName;
+
+// Users http://apigee.com/docs/usergrid/content/user
+
+- (NSMutableURLRequest *) createUserWithValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) setPasswordForUser:(NSString *) username
+                                  toPassword:(NSString *) newPassword
+                                fromPassword:(NSString *) oldPassword;
+
+- (NSMutableURLRequest *) getUser:(NSString *) username;
+
+- (NSMutableURLRequest *) updateUser:(NSString *) username
+                          withValues:(NSDictionary *) values;
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) username;
+
+- (NSMutableURLRequest *) getUsersUsingQuery:(NSDictionary *) query;
+
+- (NSMutableURLRequest *) connectEntity:(NSString *) entity1
+                           inCollection:(NSString *) collection
+                               toEntity:(NSString *) entity2
+                    throughRelationship:(NSString *) relationship;
+
+- (NSMutableURLRequest *) disconnectEntity:(NSString *) entity1
+                              inCollection:(NSString *) collection
+                                fromEntity:(NSString *) entity2
+                       throughRelationship:(NSString *) relationship;
+
+- (NSMutableURLRequest *) getConnectionsToEntity:(NSString *) entity
+                                    inCollection:(NSString *) collection
+                             throughRelationship:(NSString *) relationship
+                                      usingQuery:(NSDictionary *) query;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGConnection.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGConnection.m b/sdks/other/ios/UGAPI/v2/UGConnection.m
new file mode 100644
index 0000000..48840b3
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGConnection.m
@@ -0,0 +1,938 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+//
+//  UGConnection.m
+//  UGAPIApp
+//
+//  Created by Tim Burks on 3/30/13.
+//
+//
+#import "UGHTTPHelpers.h"
+#import "UGHTTPResult.h"
+#import "UGConnection.h"
+
+static NSString *boolean_representation(BOOL value)
+{
+    return (value ? @"true" : @"false");
+}
+
+@interface UGConnection ()
+@property (nonatomic, strong) NSString *token;
+@property (nonatomic, strong) NSDate *tokenExpirationDate;
+@end
+
+@implementation UGConnection
+
++ (UGConnection *) sharedConnection
+{
+    static UGConnection *connection = nil;
+    if (!connection) {
+        connection = [[UGConnection alloc] init];
+    }
+    return connection;
+}
+
+- (id) init {
+    if (self = [super init]) {
+        self.server = @"http://api.usergrid.com";
+    }
+    return self;
+}
+
+- (UGConnection *) copy
+{
+    UGConnection *copy = [super copy];
+    copy.server = self.server;
+    copy.organization = self.organization;
+    copy.application = self.application;
+    copy.token = self.token;
+    copy.tokenExpirationDate = self.tokenExpirationDate;
+    return copy;
+}
+
+#pragma mark - Internal helpers -
+
+- (NSString *) root
+{
+    return [NSString stringWithFormat:@"%@/%@/%@", self.server, self.organization, self.application];
+}
+
+- (NSMutableURLRequest *) authorizedRequestWithMethod:(NSString *) method
+                                                 path:(NSString *) path
+                                                 body:(NSData *) body
+{
+    NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:path]];
+    [request setHTTPMethod:method];
+    if (body) {
+        [request setHTTPBody:body];
+    }
+    if (self.token) {
+        [request setValue:[NSString stringWithFormat:@"Bearer %@", self.token] forHTTPHeaderField:@"Authorization"];
+    }
+    return request;
+}
+
+#pragma mark - External helpers -
+
+#pragma mark Queries
+
+- (NSMutableDictionary *) queryWithString:(NSString *) queryString
+                                    limit:(int) limit
+                                startUUID:(NSString *) startUUID
+                                   cursor:(NSString *) cursor
+                                 reversed:(BOOL) reversed
+{
+    NSMutableDictionary *query = [NSMutableDictionary dictionary];
+    if (queryString) {
+        query[@"ql"] = queryString;
+    }
+    if (limit > 0) {
+        query[@"limit"] = [NSNumber numberWithInt:limit];
+    }
+    if (startUUID) {
+        query[@"start"] = startUUID;
+    }
+    if (cursor) {
+        query[@"cursor"] = cursor;
+    }
+    if (reversed) {
+        query[@"reversed"] = @"true";
+    }
+    return query;
+}
+
+#pragma mark Authentication
+
+- (BOOL) authenticateWithResult:(UGHTTPResult *) result
+{
+    id results = result.object;
+    self.token = results[@"access_token"];
+    id expires = results[@"expires_in"];
+    self.tokenExpirationDate = [NSDate dateWithTimeIntervalSinceNow:[expires intValue]];
+    return [self isAuthenticated];
+}
+
+- (BOOL) isAuthenticated
+{
+    return (self.token &&
+            self.tokenExpirationDate &&
+            ([self.tokenExpirationDate compare:[NSDate date]] == NSOrderedDescending));
+}
+
+#pragma mark - Management API request generators -
+
+#pragma mark Access tokens
+// http://apigee.com/docs/usergrid/content/accesstoken
+
+- (NSMutableURLRequest *) getAccessTokenForAdminWithUsername:(NSString *) username
+                                                    password:(NSString *) password
+{
+    if (!username || !password) {
+        return nil;
+    }
+    NSDictionary *query = @{@"grant_type":@"password",
+                            @"username":username,
+                            @"password":password};
+    NSString *path = [NSMutableString stringWithFormat:@"%@/management/token?%@",
+                      self.server, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getAccessTokenForOrganizationWithClientID:(NSString *) clientID
+                                                       clientSecret:(NSString *) clientSecret
+{
+    if (!clientID || !clientSecret) {
+        return nil;
+    }
+    NSDictionary *query = @{@"grant_type":@"client_credentials",
+                            @"client_id":clientID,
+                            @"client_secret":clientSecret};
+    NSString *path = [NSMutableString stringWithFormat:@"%@/management/token?%@",
+                      self.server, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getAccessTokenForApplicationWithUsername:(NSString *) username
+                                                          password:(NSString *) password
+{
+    if (!username || !password) {
+        return nil;
+    }
+    NSDictionary *query = @{@"grant_type":@"password",
+                            @"username":username,
+                            @"password":password};
+    NSString *path = [NSMutableString stringWithFormat:@"%@/token?%@",
+                      self.root, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getAccessTokenForApplicationWithClientID:(NSString *) clientID
+                                                      clientSecret:(NSString *) clientSecret
+{
+    if (!clientID || !clientSecret) {
+        return nil;
+    }
+    NSDictionary *query = @{@"grant_type":@"client_credentials",
+                            @"client_id":clientID,
+                            @"client_secret":clientSecret};
+    NSString *path = [NSMutableString stringWithFormat:@"%@/token?%@",
+                      self.root, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Admin users
+// http://apigee.com/docs/usergrid/content/admin-user
+
+- (NSMutableURLRequest *) createAdminUserWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users",
+                      self.server];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) updateAdminUser:(NSString *) adminUserIdentifier
+                               withValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@",
+                      self.server, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) getAdminUser:(NSString *) adminUserIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@",
+                      self.server, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) setPasswordForAdminUser:(NSString *) adminUserIdentifier
+                                          toValue:(NSString *) password
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/password",
+                      self.server, adminUserIdentifier];
+    NSDictionary *values = @{@"password":password};
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) initiatePasswordResetForAdminUser
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/resetpw",
+                      self.server];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) completePasswordResetForAdminUserWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/resetpw",
+                      self.server];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) activateAdminUser:(NSString *) adminUserIdentifier
+                                  withToken:(NSString *) token
+                   sendingConfirmationEmail:(BOOL) sendingConfirmationEmail
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/activate",
+                      self.server, adminUserIdentifier];
+    NSDictionary *values = @{@"token":token,
+                             @"confirm_email":boolean_representation(sendingConfirmationEmail)};
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) reactivateAdminUser:(NSString *) adminUserIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/reactivate",
+                      self.server, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getActivityFeedForAdminUser:(NSString *) adminUserIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/feed",
+                      self.server, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Client authorization
+// http://apigee.com/docs/usergrid/content/client-authorization
+
+- (NSMutableURLRequest *) authorizeClient:(NSString *) clientIdentifier withResponseType:(NSString *) responseType
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/authorize",
+                      self.server];
+    NSDictionary *values = @{@"response_type":responseType,
+                             @"client_id":clientIdentifier};
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+
+#pragma mark Organizations and Applications
+// http://apigee.com/docs/usergrid/content/organization
+
+- (NSMutableURLRequest *) createOrganizationWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations",
+                      self.server];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) getOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) activateOrganization:(NSString *) organizationIdentifier
+                                     withToken:(NSString *) token
+                      sendingConfirmationEmail:(BOOL) sendingConfirmationEmail
+{
+    NSDictionary *values = @{@"token":token,
+                             @"confirm_email":boolean_representation(sendingConfirmationEmail)};
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/activate?%@",
+                      self.server, organizationIdentifier, [values URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) reactivateOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/reactivate",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) generateClientCredentialsForOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/credentials",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getClientCredentialsForOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/credentials",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getActivityFeedForOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/feed",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) createApplicationInOrganization:(NSString *)organizationIdentifier withValues:(NSDictionary *)values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) deleteApplication:(NSString *) applicationIdentifier
+                             inOrganization:(NSString *)organizationIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications/%@",
+                      self.server, organizationIdentifier, applicationIdentifier];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) generateClientCredentialsForApplication:(NSString *) applicationIdentifier
+                                                   inOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/applications/%@/credentials",
+                      self.server, organizationIdentifier, applicationIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getClientCredentialsForApplication:(NSString *) applicationIdentifier
+                                              inOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/applications/%@/credentials",
+                      self.server, organizationIdentifier, applicationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getApplicationsInOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) addAdminUser:(NSString *) adminUserIdentifier
+                        toOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users/%@",
+                      self.server, organizationIdentifier, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getAdminUsersInOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users",
+                      self.server, organizationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) removeAdminUser:(NSString *) adminUserIdentifier
+                         fromOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users/%@",
+                      self.server, organizationIdentifier, adminUserIdentifier];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getApplication:(NSString *) applicationIdentifier
+                          inOrganization:(NSString *) organizationIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/%@/%@",
+                      self.server, organizationIdentifier, applicationIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark - Application API request generators -
+
+#pragma mark Activity
+// http://apigee.com/docs/usergrid/content/activity
+
+- (NSMutableURLRequest *) createActivityForUser:(NSString *) userIdentifier
+                                     withValues:(NSDictionary *) values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/activities",
+                      self.root, userIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) createActivityForGroup:(NSString *) groupIdentifier
+                                      withValues:(NSDictionary *) values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/activities",
+                      self.root, groupIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) createActivityForFollowersOfUser:(NSString *) userIdentifier
+                                                   inGroup:(NSString *) groupIdentifier
+                                                withValues:(NSDictionary *) values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/users/%@/activities",
+                      self.root, groupIdentifier, userIdentifier];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+
+}
+
+- (NSMutableURLRequest *) getActivitiesForUser:(NSString *) userIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/activities",
+                      self.root, userIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getActivitiesForGroup:(NSString *) groupIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/activities",
+                      self.root, groupIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getActivityFeedForUser:(NSString *) userIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/feed",
+                      self.root, userIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getActivityFeedForGroup:(NSString *) groupIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/feed",
+                      self.root, groupIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Assets
+
+- (NSMutableURLRequest *) getDataForAsset:(NSString *) assetIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/assets/%@/data",
+                      self.root, assetIdentifier];
+    NSMutableURLRequest *request = [self authorizedRequestWithMethod:@"GET"
+                                                                path:path
+                                                                body:nil];
+    return request;
+}
+
+- (NSMutableURLRequest *) postData:(NSData *) data
+                          forAsset:(NSString *) assetIdentifier
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/assets/%@/data",
+                      self.root,
+                      assetIdentifier];
+    NSMutableURLRequest *request = [self authorizedRequestWithMethod:@"POST"
+                                                                path:path
+                                                                body:data];
+    [request setValue:@"application/octet-stream" forHTTPHeaderField:@"Content-Type"];
+    return request;
+}
+
+#pragma mark General-purpose endpoints
+// http://apigee.com/docs/usergrid/content/general-purpose-endpoints
+
+- (NSMutableURLRequest *) createEntityInCollection:(NSString *) collection
+                                        withValues:(NSDictionary *)values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/%@",
+                      self.root, collection];
+    NSError *error;
+    NSData *data = [NSJSONSerialization dataWithJSONObject:values options:0 error:&error];
+    if (!data) {
+        NSLog(@"%@", error);
+    }
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:data];
+}
+
+- (NSMutableURLRequest *) getEntity:(NSString *) entityIdentifier
+                       inCollection:(NSString *) collection
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/%@/%@",
+                      self.root, collection, entityIdentifier];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) updateEntity:(NSString *) entityIdentifier
+                          inCollection:(NSString *) collection
+                            withValues:(NSDictionary *) values {
+    NSString *path = [NSString stringWithFormat:@"%@/%@/%@", self.root, collection, entityIdentifier];
+    NSError *error;
+    NSData *data = [NSJSONSerialization dataWithJSONObject:values options:0 error:&error];
+    if (!data) {
+        NSLog(@"%@", error);
+    }
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:data];
+}
+
+- (NSMutableURLRequest *) deleteEntity:(NSString *) entityIdentifier
+                          inCollection:(NSString *) collection
+{
+    NSString *path = [NSString stringWithFormat:@"%@/%@/%@", self.root, collection, entityIdentifier];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
+                                            limit:(int) limit
+{
+    NSDictionary *query = [self queryWithString:@"select *"
+                                          limit:limit
+                                      startUUID:nil
+                                         cursor:nil
+                                       reversed:NO];
+    return [self getEntitiesInCollection:collection
+                              usingQuery:query];
+}
+
+- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
+                                       usingQuery:(NSDictionary *) query
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/%@?%@",
+                      self.root,
+                      collection,
+                      [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) updateEntitiesInCollection:(NSString *) collection
+                                          usingQuery:(NSDictionary *) query
+                                          withValues:(NSDictionary *) values
+{
+    NSString *path = [NSMutableString stringWithFormat:@"%@/%@?%@",
+                      self.root,
+                      collection,
+                      [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
+{
+    NSDictionary *query = [self queryWithString:@"select *"
+                                          limit:0
+                                      startUUID:nil
+                                         cursor:nil
+                                       reversed:NO];
+    return [self deleteEntitiesInCollection:collection
+                                 usingQuery:query];
+}
+
+- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
+                                          usingQuery:(NSDictionary *) query
+{
+    NSString *path = [NSString stringWithFormat:@"%@/%@?%@", self.root, collection, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Devices
+// http://apigee.com/docs/usergrid/content/device
+
+#pragma mark Events and Counters
+// http://apigee.com/docs/usergrid/content/events-and-counters
+
+- (NSMutableURLRequest *) createEventWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/events", self.root];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+#pragma mark Groups
+// http://apigee.com/docs/usergrid/content/group
+
+- (NSMutableURLRequest *) createGroupWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups", self.root];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) addUser:(NSString *) user
+                          toGroup:(NSString *) group
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users/%@",
+                      self.root, group, user];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getGroup:(NSString *) groupName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@", self.root, groupName];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) updateGroup:(NSString *) groupName
+                           withValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@",
+                      self.root, groupName];
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) user
+                           fromGroup:(NSString *) groupName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users/%@",
+                      self.root, groupName, user];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) deleteGroup:(NSString *) groupName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@",
+                      self.root, groupName];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getUsersInGroup:(NSString *) groupName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users",
+                      self.root, groupName];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Roles
+// http://apigee.com/docs/usergrid/content/role
+
+- (NSMutableURLRequest *) createRoleWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles", self.root];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) getRoles
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles", self.root];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) deleteRole:(NSString *) roleName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@",
+                      self.root, roleName];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getPermissionsForRole:(NSString *) roleName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@",
+                      self.root, roleName];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) addPermissionsToRole:(NSString *) roleName
+                                    withValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/permissions",
+                      self.root, roleName];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) deletePermissionsFromRole:(NSString *) roleName
+                                       usingPattern:(NSString *) pattern
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/permissions?pattern=%@",
+                      self.root, roleName, pattern];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) addUser:(NSString *)user
+                           toRole:(NSString *)roleName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users/%@",
+                      self.root, roleName, user];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getUsersInRole:(NSString *) roleName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users",
+                      self.root, roleName];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) user
+                            fromRole:(NSString *) roleName
+{
+    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users/%@",
+                      self.root, roleName, user];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+#pragma mark Users
+// http://apigee.com/docs/usergrid/content/user
+
+- (NSMutableURLRequest *) createUserWithValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/users", self.root];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) setPasswordForUser:(NSString *) username
+                                  toPassword:(NSString *) newPassword
+                                fromPassword:(NSString *) oldPassword
+{
+    NSDictionary *query = @{@"newpassword":newPassword,
+                            @"oldpassword":oldPassword};
+    NSString *path = [NSString stringWithFormat:@"%@/users/%@/password",
+                      self.root, username];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:[query URLQueryData]];
+}
+
+- (NSMutableURLRequest *) getUser:(NSString *) username
+{
+    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
+                      self.root, username];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) updateUser:(NSString *) username
+                          withValues:(NSDictionary *) values
+{
+    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
+                      self.root, username];
+    return [self authorizedRequestWithMethod:@"PUT"
+                                        path:path
+                                        body:[values URLQueryData]];
+}
+
+- (NSMutableURLRequest *) deleteUser:(NSString *) username
+{
+    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
+                      self.root, username];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getUsersUsingQuery:(NSDictionary *) query
+{
+    NSString *path = [NSString stringWithFormat:@"%@/users?%@",
+                      self.root, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) connectEntity:(NSString *) entity1
+                           inCollection:(NSString *) collection
+                               toEntity:(NSString *) entity2
+                    throughRelationship:(NSString *) relationship
+{
+    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@/%@",
+                      self.root, collection, entity1, relationship, entity2];
+    return [self authorizedRequestWithMethod:@"POST"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) disconnectEntity:(NSString *) entity1
+                              inCollection:(NSString *) collection
+                                fromEntity:(NSString *) entity2
+                       throughRelationship:(NSString *) relationship
+{
+    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@/%@",
+                      self.root, collection, entity1, relationship, entity2];
+    return [self authorizedRequestWithMethod:@"DELETE"
+                                        path:path
+                                        body:nil];
+}
+
+- (NSMutableURLRequest *) getConnectionsToEntity:(NSString *) entity
+                                    inCollection:(NSString *) collection
+                             throughRelationship:(NSString *) relationship
+                                      usingQuery:(NSDictionary *) query
+{
+    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@?%@",
+                      self.root, collection, entity, relationship, [query URLQueryString]];
+    return [self authorizedRequestWithMethod:@"GET"
+                                        path:path
+                                        body:nil];
+}
+
+@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPClient.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPClient.h b/sdks/other/ios/UGAPI/v2/UGHTTPClient.h
new file mode 100644
index 0000000..64fe9be
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPClient.h
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+#import <Foundation/Foundation.h>
+
+@class UGHTTPResult;
+
+typedef void (^UGHTTPCompletionHandler)(UGHTTPResult *result);
+typedef void (^UGHTTPProgressHandler)(CGFloat progress);
+
+@interface UGHTTPClient : NSObject
+#if TARGET_OS_IPHONE
+<NSURLConnectionDataDelegate>
+#endif
+
+@property (nonatomic, copy) UGHTTPCompletionHandler completionHandler;
+@property (nonatomic, copy) UGHTTPProgressHandler progressHandler;
+@property (readonly) CGFloat progress;
+@property (readonly) BOOL isRunning;
+
+- (id) initWithRequest:(NSMutableURLRequest *) request;
+
+- (UGHTTPResult *) connect;
+
+- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler;
+
+- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler
+                      progressHandler:(UGHTTPProgressHandler) progressHandler;
+
+- (void) cancel;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPClient.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPClient.m b/sdks/other/ios/UGAPI/v2/UGHTTPClient.m
new file mode 100644
index 0000000..38aee42
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPClient.m
@@ -0,0 +1,161 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+
+@interface UGHTTPClient ()
+@property (nonatomic, strong) NSMutableURLRequest *request;
+@property (nonatomic, strong) NSMutableData *data;
+@property (nonatomic, strong) NSHTTPURLResponse *response;
+@property (nonatomic, strong) NSURLConnection *connection;
+@end
+
+@implementation UGHTTPClient
+
+static int activityCount = 0;
+
++ (void) retainNetworkActivityIndicator {
+    activityCount++;
+#if TARGET_OS_IPHONE
+    [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:YES];
+#endif
+}
+
++ (void) releaseNetworkActivityIndicator {
+    activityCount--;
+#if TARGET_OS_IPHONE
+    if (activityCount == 0) {
+        [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:NO];
+    }
+#endif
+}
+
+- (id) initWithRequest:(NSMutableURLRequest *)request
+{
+    if (self = [super init]) {
+        self.request = request;
+    }
+    return self;
+}
+
+- (UGHTTPResult *) connect {
+    NSHTTPURLResponse *response;
+    NSError *error;
+    UGHTTPResult *result = [[UGHTTPResult alloc] init];
+    result.data = [NSURLConnection sendSynchronousRequest:self.request returningResponse:&response error:&error];
+    result.response = response;
+    result.error = error;
+    if (self.completionHandler) {
+        self.completionHandler(result);
+    }
+    return result;
+}
+
+- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler)completionHandler
+                      progressHandler:(UGHTTPProgressHandler)progressHandler
+{
+   	[self.request setCachePolicy:NSURLRequestReloadIgnoringLocalCacheData];
+    self.data = nil;
+    self.response = nil;
+	self.completionHandler = completionHandler;
+    self.progressHandler = progressHandler;
+	self.connection = [[NSURLConnection alloc] initWithRequest:self.request delegate:self];
+    [isa retainNetworkActivityIndicator];
+}
+
+- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler
+{
+    [self connectWithCompletionHandler:completionHandler progressHandler:nil];
+}
+
+- (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSHTTPURLResponse *)response
+{
+	self.response = response;
+    if (self.progressHandler) {
+        self.progressHandler(0.0);
+    }
+}
+
+- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)newData
+{
+    if (!self.data) {
+        self.data = [NSMutableData dataWithData:newData];
+    } else {
+        [self.data appendData:newData];
+    }
+    if (self.progressHandler) {
+        long long expectedLength = [self.response expectedContentLength];
+        if (expectedLength > 0) {
+            CGFloat progress = ((CGFloat) [self.data length]) / expectedLength;
+            self.progressHandler(progress);
+        }
+    }
+}
+
+- (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
+{
+    if (self.completionHandler) {
+        UGHTTPResult *result = [[UGHTTPResult alloc] init];
+        result.response = self.response;
+        result.data = self.data;
+        result.error = error;
+        self.completionHandler(result);
+    }
+	self.connection = nil;
+    self.data = nil;
+    [isa releaseNetworkActivityIndicator];
+}
+
+- (void)connectionDidFinishLoading:(NSURLConnection *)connection
+{
+    if (self.progressHandler) {
+        self.progressHandler(1.0);
+    }
+    if (self.completionHandler) {
+        UGHTTPResult *result = [[UGHTTPResult alloc] init];
+        result.response = self.response;
+        result.data = self.data;
+        result.error = nil;
+        //[self.data writeToFile:@"/tmp/data" atomically:NO];
+        self.completionHandler(result);
+    }
+    self.connection = nil;
+    self.data = nil;
+    [isa releaseNetworkActivityIndicator];
+}
+
+- (void) cancel {
+    if (self.connection) {
+        [self.connection cancel];
+    }
+    self.connection = nil;
+}
+
+- (BOOL) isRunning {
+    return (self.connection != nil);
+}
+
+- (CGFloat) progress {
+    long long expectedLength = [self.response expectedContentLength];
+    if (expectedLength > 0) {
+        return ((CGFloat) [self.data length]) / expectedLength;
+    } else {
+        return 0.0;
+    }
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.h b/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.h
new file mode 100644
index 0000000..64c678a
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.h
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+ //
+//  UGHTTPHelpers.h
+//  UGHTTP
+//
+//  Created by Tim Burks on 2/24/12.
+//
+#import <Foundation/Foundation.h>
+
+@interface NSString (UGHTTPHelpers)
+- (NSString *) URLEncodedString;
+- (NSString *) URLDecodedString;
+- (NSDictionary *) URLQueryDictionary;
+@end
+
+@interface NSData (UGHTTPHelpers)
+- (NSDictionary *) URLQueryDictionary;
+@end
+
+@interface NSDictionary (UGHTTPHelpers)
+- (NSString *) URLQueryString;
+- (NSData *) URLQueryData;
+@end
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.m b/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.m
new file mode 100644
index 0000000..9bad1b9
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPHelpers.m
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+//
+//  UGHTTPHelpers.m
+//  UGHTTP
+//
+//  Created by Tim Burks on 2/24/12.
+//
+
+#import "UGHTTPHelpers.h"
+#import <wctype.h>
+
+static unichar char_to_int(unichar c)
+{
+    switch (c) {
+        case '0': return 0;
+        case '1': return 1;
+        case '2': return 2;
+        case '3': return 3;
+        case '4': return 4;
+        case '5': return 5;
+        case '6': return 6;
+        case '7': return 7;
+        case '8': return 8;
+        case '9': return 9;
+        case 'A': case 'a': return 10;
+        case 'B': case 'b': return 11;
+        case 'C': case 'c': return 12;
+        case 'D': case 'd': return 13;
+        case 'E': case 'e': return 14;
+        case 'F': case 'f': return 15;
+    }
+    return 0;                                     // not good
+}
+
+static char int_to_char[] = "0123456789ABCDEF";
+
+@implementation NSString (UGHTTPHelpers)
+
+- (NSString *) URLEncodedString
+{
+    NSMutableString *result = [NSMutableString string];
+    int i = 0;
+    const char *source = [self cStringUsingEncoding:NSUTF8StringEncoding];
+    unsigned long max = strlen(source);
+    while (i < max) {
+        unsigned char c = source[i++];
+        if (c == ' ') {
+            [result appendString:@"%20"];
+        }
+        else if (iswalpha(c) || iswdigit(c) || (c == '-') || (c == '.') || (c == '_') || (c == '~')) {
+            [result appendFormat:@"%c", c];
+        }
+        else {
+            [result appendString:[NSString stringWithFormat:@"%%%c%c", int_to_char[(c/16)%16], int_to_char[c%16]]];
+        }
+    }
+    return result;
+}
+
+- (NSString *) URLDecodedString
+{
+    int i = 0;
+    NSUInteger max = [self length];
+    char *buffer = (char *) malloc ((max + 1) * sizeof(char));
+    int j = 0;
+    while (i < max) {
+        char c = [self characterAtIndex:i++];
+        switch (c) {
+            case '+':
+                buffer[j++] = ' ';
+                break;
+            case '%':
+                buffer[j++] =
+                char_to_int([self characterAtIndex:i])*16
+                + char_to_int([self characterAtIndex:i+1]);
+                i = i + 2;
+                break;
+            default:
+                buffer[j++] = c;
+                break;
+        }
+    }
+    buffer[j] = 0;
+    NSString *result = [NSMutableString stringWithCString:buffer encoding:NSUTF8StringEncoding];
+    if (!result) result = [NSMutableString stringWithCString:buffer encoding:NSASCIIStringEncoding];
+    free(buffer);
+    return result;
+}
+
+- (NSDictionary *) URLQueryDictionary
+{
+    NSMutableDictionary *result = [NSMutableDictionary dictionary];
+    NSArray *pairs = [self componentsSeparatedByString:@"&"];
+    int i;
+    NSUInteger max = [pairs count];
+    for (i = 0; i < max; i++) {
+        NSArray *pair = [[pairs objectAtIndex:i] componentsSeparatedByString:@"="];
+        if ([pair count] == 2) {
+            NSString *key = [[pair objectAtIndex:0] URLDecodedString];
+            NSString *value = [[pair objectAtIndex:1] URLDecodedString];
+            [result setObject:value forKey:key];
+        }
+    }
+    return result;
+}
+
+@end
+
+@implementation NSDictionary (UGHTTPHelpers)
+
+- (NSString *) URLQueryString
+{
+    NSMutableString *result = [NSMutableString string];
+    NSEnumerator *keyEnumerator = [[[self allKeys] sortedArrayUsingSelector:@selector(compare:)] objectEnumerator];
+    id key;
+    while ((key = [keyEnumerator nextObject])) {
+        id value = [self objectForKey:key];
+        if (![value isKindOfClass:[NSString class]]) {
+            if ([value respondsToSelector:@selector(stringValue)]) {
+                value = [value stringValue];
+            }
+        }
+        if ([value isKindOfClass:[NSString class]]) {
+            if ([result length] > 0) [result appendString:@"&"];
+            [result appendString:[NSString stringWithFormat:@"%@=%@",
+                                  [key URLEncodedString],
+                                  [value URLEncodedString]]];
+        }
+    }
+    return [NSString stringWithString:result];
+}
+
+- (NSData *) URLQueryData
+{
+    return [[self URLQueryString] dataUsingEncoding:NSUTF8StringEncoding];
+}
+
+@end
+
+@implementation NSData (UGHTTPHelpers)
+
+- (NSDictionary *) URLQueryDictionary {
+    return [[[NSString alloc] initWithData:self encoding:NSUTF8StringEncoding] URLQueryDictionary];
+}
+
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPResult.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPResult.h b/sdks/other/ios/UGAPI/v2/UGHTTPResult.h
new file mode 100644
index 0000000..e8faf9b
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPResult.h
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+//
+//  UGHTTPResult.h
+//  UGAPIApp
+//
+//  Created by Tim Burks on 4/3/13.
+//
+//
+
+#import <Foundation/Foundation.h>
+
+@interface UGHTTPResult : NSObject
+@property (nonatomic, strong) NSHTTPURLResponse *response;
+@property (nonatomic, strong) NSData *data;
+@property (nonatomic, strong) NSError *error;
+@property (nonatomic, strong) id object;
+@property (nonatomic, readonly) NSString *UTF8String;
+
+@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/v2/UGHTTPResult.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/v2/UGHTTPResult.m b/sdks/other/ios/UGAPI/v2/UGHTTPResult.m
new file mode 100644
index 0000000..2e0e115
--- /dev/null
+++ b/sdks/other/ios/UGAPI/v2/UGHTTPResult.m
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+//
+//  UGHTTPResult.m
+//  UGAPIApp
+//
+//  Created by Tim Burks on 4/3/13.
+//
+//
+
+#import "UGHTTPResult.h"
+
+@implementation UGHTTPResult
+
+- (id) object {
+    if (!_object && !_error) {
+        NSError *error;
+        // NSLog(@"JSON %@", [[NSString alloc] initWithData:_data encoding:NSUTF8StringEncoding]);
+        _object = [NSJSONSerialization JSONObjectWithData:_data options:0 error:&error];
+        _error = error;
+        if (_error) {
+            NSLog(@"JSON ERROR: %@", [error description]);
+        }
+    }
+    return _object;
+}
+
+- (NSString *) UTF8String {
+    return [[NSString alloc] initWithData:self.data encoding:NSUTF8StringEncoding];
+}
+
+@end
\ No newline at end of file


[16/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Native/Facades/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Native/Facades/Usergrid.php b/sdks/other/php5/apache-usergrid/src/Native/Facades/Usergrid.php
new file mode 100644
index 0000000..fbfcffe
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Native/Facades/Usergrid.php
@@ -0,0 +1,118 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Native\Facades;
+
+
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/**
+ * Class Usergrid
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Usergrid
+{
+    /**
+     * The Native Bootstrap instance.
+     *
+     * @var \Apache\Usergrid\Native\UsergridBootstrapper
+     */
+    protected static $instance;
+    /**
+     * The Usergrid API instance.
+     *
+     * @var \Apache\Usergrid\Api\Usergrid
+     */
+    protected $usergrid;
+
+    /**
+     * Constructor.
+     *
+     * @param  \Apache\Usergrid\Native\UsergridBootstrapper $bootstraper
+     * @return \Apache\Usergrid\Native\Facades\Usergrid
+     */
+    public function __construct(UsergridBootstrapper $bootstraper = null)
+    {
+        if (!$bootstraper) {
+            $bootstraper = new UsergridBootstrapper;
+        }
+
+        $this->usergrid = $bootstraper->createUsergrid();
+    }
+
+    /**
+     * Handle dynamic, static calls to the object.
+     *
+     * @param  string $method
+     * @param  array $args
+     * @return mixed
+     */
+    public static function __callStatic($method, $args)
+    {
+        $instance = static::instance()->getUsergrid();
+
+        switch (count($args)) {
+            case 0:
+                return $instance->{$method}();
+
+            case 1:
+                return $instance->{$method}($args[0]);
+
+            case 2:
+                return $instance->{$method}($args[0], $args[1]);
+
+            case 3:
+                return $instance->{$method}($args[0], $args[1], $args[2]);
+
+            case 4:
+                return $instance->{$method}($args[0], $args[1], $args[2], $args[3]);
+
+            default:
+                return call_user_func_array([$instance, $method], $args);
+        }
+    }
+
+    /**
+     * Creates a new Native Bootstraper instance.
+     *
+     * @param  \Apache\Usergrid\Native\UsergridBootstrapper $bootstrapper
+     * @return static
+     */
+    public static function instance(UsergridBootstrapper $bootstrapper = null)
+    {
+        if (static::$instance === null) {
+            static::$instance = new static($bootstrapper);
+        }
+
+        return static::$instance;
+    }
+
+    /**
+     * Returns the Usergrid API instance.
+     *
+     * @return \Apache\Usergrid\Api\Usergrid
+     */
+    public function getUsergrid()
+    {
+        return $this->usergrid;
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Native/UsergridBootstrapper.php b/sdks/other/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
new file mode 100644
index 0000000..0f71b78
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Native/UsergridBootstrapper.php
@@ -0,0 +1,150 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Native;
+
+
+use Apache\Usergrid\Api\Usergrid;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\ClientCredentials;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\PasswordCredentials;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\RefreshToken;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
+use Guzzle\Http\Client;
+
+/**
+ * Class UsergridBootstrapper
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UsergridBootstrapper
+{
+    /**
+     * The Usergrid configuration.
+     *
+     * @var array
+     */
+    protected $config;
+
+    /**
+     * The Oauth2 Plugin.
+     *
+     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin
+     */
+    protected $oauth2Plugin = null;
+
+    /**
+     * Constructor.
+     *
+     * @param  mixed $config
+     * @return \Apache\Usergrid\Native\UsergridBootstrapper
+     */
+    public function __construct($config = null)
+    {
+        $this->config = $config ?: new ConfigRepository($config);
+    }
+
+    /**
+     * Creates the Usergrid instance.
+     *
+     * @return \Apache\Usergrid\Api\Usergrid
+     */
+    public function createUsergrid()
+    {
+        $baseUrl = array_get($this->config, 'usergrid.url');
+
+        $orgName = array_get($this->config, 'usergrid.orgName');
+
+        $appName = array_get($this->config, 'usergrid.appName');
+
+        $manifestPath = array_get($this->config, 'usergrid.manifestPath');
+
+        $version = array_get($this->config, 'usergrid.version');
+
+        $enable_oauth2_plugin = array_get($this->config, 'usergrid.enable_oauth2_plugin');
+
+        //check if user wants to manage there own Oauth 2 auth flow
+        if ($enable_oauth2_plugin) {
+
+            $this->createOauth2Plugin();
+
+            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl, $this->oauth2Plugin);
+        } else {
+            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl);
+        }
+
+    }
+
+    private function createOauth2Plugin()
+    {
+        $base_url = array_get($this->config, 'usergrid.url');
+
+        $client_id = array_get($this->config, 'usergrid.clientId');
+
+        $client_secret = array_get($this->config, 'usergrid.clientSecret');
+
+        $grant_type = array_get($this->config, 'usergrid.grant_type');
+
+        $auth_type = array_get($this->config, 'usergrid.auth_type');
+
+        $username = array_get($this->config, 'usergrid.username');
+
+        $password = array_get($this->config, 'usergrid.password');
+
+
+        $org_name = array_get($this->config, 'usergrid.orgName');
+
+        $app_name = array_get($this->config, 'usergrid.appName');
+
+        if ($auth_type == 'organization') {
+
+            $url = $base_url . '/management/token';
+
+        } elseif ($auth_type == 'application') {
+            $url = $base_url . '/' . $org_name . '/' . $app_name . '/token';
+        }
+
+        $oauth2Client = new Client($url);
+
+
+        if ($grant_type == 'client_credentials') {
+            $config = [
+                'client_id' => $client_id,
+                'client_secret' => $client_secret,
+
+            ];
+            $grantType = new ClientCredentials($oauth2Client, $config);
+            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
+            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
+
+        } elseif ($grant_type == 'password') {
+            $config = [
+                'username' => $username,
+                'password' => $password,
+                'client_id' => $client_id,
+                'client_secret' => $client_secret
+            ];
+            $grantType = new PasswordCredentials($oauth2Client, $config);
+            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
+            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
+        }
+    }
+
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/config/config.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/config/config.php b/sdks/other/php5/apache-usergrid/src/config/config.php
new file mode 100644
index 0000000..75a886f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/config/config.php
@@ -0,0 +1,53 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'usergrid' => [
+
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.0',
+        'orgName' => null,
+        'appName' => null,
+        'manifestPath' => null,
+        //its better not to set the real values here if using laravel set them in a .env file or
+        // if your not using Laravel set them as environment variable and include them here using $_ENV global.
+        // so that way you can be sure not to commit privates ID to a public repo
+        'clientId' => null,
+        'clientSecret' => null,
+        'username' => null,
+        'password' => null,
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/ApplicationTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/ApplicationTest.php b/sdks/other/php5/apache-usergrid/tests/Api/ApplicationTest.php
new file mode 100644
index 0000000..d25a205
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/ApplicationTest.php
@@ -0,0 +1,72 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api;
+
+
+use Apache\Usergrid\Api\Exception\UsergridException;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class ApplicationTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ApplicationTest extends PHPUnit_Framework_TestCase
+{
+
+    /**
+     * Usergrid client
+     *
+     * @var Usergrid $usergrid
+     */
+    protected $usergrid;
+
+    protected $config;
+
+    /**
+     *
+     */
+    public function setUp()
+    {
+        $this->usergrid = $GLOBALS['usergrid'];
+    }
+
+    /**
+     * @test
+     * @group internet
+     */
+    public function it_can_get_entity()
+    {
+
+        $error = null;
+
+        try {
+            $this->usergrid->application()->EntityGet(['collection' => 'users']);
+        } catch (UsergridException  $e) {
+            $error = $e;
+        }
+
+        $this->assertNull($error, 'Exception should be null');
+    }
+
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/AttributeTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/AttributeTest.php b/sdks/other/php5/apache-usergrid/tests/Api/AttributeTest.php
new file mode 100644
index 0000000..cc1f29e
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/AttributeTest.php
@@ -0,0 +1,59 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api;
+
+
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class AttributeTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class AttributeTest extends PHPUnit_Framework_TestCase
+{
+    /** @var  Usergrid Api Client */
+    protected $usergrid;
+
+
+    /**
+     * Setup resources and dependencies
+     *
+     * @return void
+     */
+    public function setup()
+    {
+        $this->usergrid = $GLOBALS['usergrid'];
+    }
+
+    /**
+     * @test
+     * @group internet
+     */
+    public function it_should_have_attribute()
+    {
+        $this->assertTrue(method_exists('Apache\Usergrid\Api\Models\User', 'deviceAttribute'),
+            'Class does not have method Attribute Method'
+        );
+    }
+}
+ 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
new file mode 100644
index 0000000..b716e3d
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Exception/BadRequestExceptionTest.php
@@ -0,0 +1,59 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Exception;
+
+use Apache\Usergrid\Api\Exception\BadRequestException;
+use Guzzle\Http\Message\Response;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class BadRequestExceptionTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class BadRequestExceptionTest extends PHPUnit_Framework_TestCase
+{
+
+    /** @test */
+    public function it_can_create_the_exception()
+    {
+        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
+        $command
+            ->expects($this->once())
+            ->method('getRequest')
+            ->will($this->returnValue(
+                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
+            ));
+
+        $response = new Response(400);
+        $response->setBody('');
+
+        /** @noinspection PhpParamsInspection */
+        $exception = BadRequestException::fromCommand($command, $response);
+
+        $this->assertInstanceOf(
+            'Apache\Usergrid\Api\Exception\BadRequestException',
+            $exception
+        );
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
new file mode 100644
index 0000000..b74aa64
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Exception/InvalidIdExceptionTest.php
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Exception;
+
+use Apache\Usergrid\Api\Exception\InvalidIdException;
+use Guzzle\Http\Message\Response;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class InvalidIdExceptionTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class InvalidIdExceptionTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_create_the_exception()
+    {
+        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
+        $command
+            ->expects($this->once())
+            ->method('getRequest')
+            ->will($this->returnValue(
+                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
+            ));
+
+        $response = new Response(400);
+        $response->setBody('');
+
+        /** @noinspection PhpParamsInspection */
+        $exception = InvalidIdException::fromCommand($command, $response);
+
+        $this->assertInstanceOf(
+            'Apache\Usergrid\Api\Exception\InvalidIdException',
+            $exception
+        );
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
new file mode 100644
index 0000000..c264751
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Exception/NotFoundExceptionTest.php
@@ -0,0 +1,57 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Exception;
+
+use Apache\Usergrid\Api\Exception\NotFoundException;
+use Guzzle\Http\Message\Response;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class UnauthorizedExceptionTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class NotFoundExceptionTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_create_the_exception()
+    {
+        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
+        $command
+            ->expects($this->once())
+            ->method('getRequest')
+            ->will($this->returnValue(
+                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
+            ));
+
+        $response = new Response(404);
+        $response->setBody('');
+
+        /** @noinspection PhpParamsInspection */
+        $exception = NotFoundException::fromCommand($command, $response);
+
+        $this->assertInstanceOf(
+            'Apache\Usergrid\Api\Exception\NotFoundException',
+            $exception
+        );
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
new file mode 100644
index 0000000..514288f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Exception/ServerErrorExceptionTest.php
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Exception;
+
+use Apache\Usergrid\Api\Exception\ServerErrorException;
+use Guzzle\Http\Message\Response;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class ServerErrorException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ServerErrorExceptionTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_create_the_exception()
+    {
+        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
+        $command
+            ->expects($this->once())
+            ->method('getRequest')
+            ->will($this->returnValue(
+                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
+            ));
+
+        $response = new Response(400);
+        $response->setBody('');
+
+        /** @noinspection PhpParamsInspection */
+        $exception = ServerErrorException::fromCommand($command, $response);
+
+        $this->assertInstanceOf(
+            'Apache\Usergrid\Api\Exception\ServerErrorException',
+            $exception
+        );
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
new file mode 100644
index 0000000..889e7de
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Exception/UnauthorizedExceptionTest.php
@@ -0,0 +1,58 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Exception;
+
+
+use Apache\Usergrid\Api\Exception\UnauthorizedException;
+use Guzzle\Http\Message\Response;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class UnauthorizedExceptionTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UnauthorizedExceptionTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_create_the_exception()
+    {
+        $command = $this->getMock('Guzzle\Service\Command\CommandInterface');
+        $command
+            ->expects($this->once())
+            ->method('getRequest')
+            ->will($this->returnValue(
+                $this->getMock('Guzzle\Http\Message\Request', [], [], '', false)
+            ));
+
+        $response = new Response(401);
+        $response->setBody('');
+
+        /** @noinspection PhpParamsInspection */
+        $exception = UnauthorizedException::fromCommand($command, $response);
+
+        $this->assertInstanceOf(
+            'Apache\Usergrid\Api\Exception\UnauthorizedException',
+            $exception
+        );
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
new file mode 100644
index 0000000..1550a55
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Filters/BooleanTest.php
@@ -0,0 +1,45 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Filters;
+
+
+use Apache\Usergrid\Api\Filters\Boolean;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class BooleanTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class BooleanTest extends PHPUnit_Framework_TestCase
+{
+
+    /** @test */
+    public function it_can_convert_booleans()
+    {
+        $this->assertEquals('true', Boolean::convert(1));
+        $this->assertEquals('true', Boolean::convert(true));
+
+        $this->assertEquals('false', Boolean::convert(0));
+        $this->assertEquals('false', Boolean::convert(false));
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/Filters/DateTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/Filters/DateTest.php b/sdks/other/php5/apache-usergrid/tests/Api/Filters/DateTest.php
new file mode 100644
index 0000000..13d37f6
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/Filters/DateTest.php
@@ -0,0 +1,41 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api\Filters;
+
+
+use Apache\Usergrid\Api\Filters\Date;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class DateTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class DateTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_convert_dates()
+    {
+
+        $this->assertEquals('Tue, Oct 14, 2014 3:55 AM', Date::convert(1413258923819));
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/ManagementTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/ManagementTest.php b/sdks/other/php5/apache-usergrid/tests/Api/ManagementTest.php
new file mode 100644
index 0000000..46ea21c
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/ManagementTest.php
@@ -0,0 +1,59 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api;
+
+
+use Apache\Usergrid\Api\Exception\UsergridException;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class ManagementTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ManagementTest extends PHPUnit_Framework_TestCase
+{
+    protected $usergrid;
+    protected $config;
+
+    public function setUp()
+    {
+        $this->usergrid = $GLOBALS['usergrid'];
+    }
+
+    /**
+     * @test
+     * @group internet
+     */
+    public function it_can_make_management_call()
+    {
+        $error = null;
+
+        try {
+            $this->usergrid->management()->OrgAppsGet();
+        } catch (UsergridException $e) {
+            $error = $e;
+        }
+
+        $this->assertNull($error, "Should be no exception if  manifest files exits and sdk can make management calls");
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php b/sdks/other/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
new file mode 100644
index 0000000..eaa7b0b
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/QueryAggregatorTest.php
@@ -0,0 +1,40 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api;
+
+
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class QueryAggregatorTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class QueryAggregatorTest extends PHPUnit_Framework_TestCase
+{
+
+    /** @test */
+    public function it_can_test_the_aggregate_method()
+    {
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Api/UsergridTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Api/UsergridTest.php b/sdks/other/php5/apache-usergrid/tests/Api/UsergridTest.php
new file mode 100644
index 0000000..0c7a340
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Api/UsergridTest.php
@@ -0,0 +1,153 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Tests\Api;
+
+use Apache\Usergrid\Api\Exception\UnauthorizedException;
+use PHPUnit_Framework_TestCase;
+
+/**
+ * Class UsergridTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UsergridTest extends PHPUnit_Framework_TestCase
+{
+
+    /** @var  Usergrid Api Client */
+    protected $usergrid;
+
+    protected $config;
+
+    /**
+     * Setup resources and dependencies
+     *
+     * @return void
+     */
+    public function setup()
+    {
+        $this->usergrid = $GLOBALS['usergrid'];
+    }
+
+    /**
+     * @test
+     * @group internet
+     */
+    public function it_can_retrieve_oauth2_token()
+    {
+        $error = null;
+
+        try {
+            $this->usergrid->application()->EntityGet(['collection' => 'roles']);
+        } catch (UnauthorizedException $e) {
+            $error = $e;
+        }
+
+        $this->assertNull($error, 'Exception should be null if authorized');
+    }
+
+    /** @test */
+    public function it_can_set_the_oauth2_token()
+    {
+        $this->usergrid->setToken('ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890');
+
+        $this->assertEquals('ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890', $this->usergrid->getToken());
+    }
+
+    /** @test */
+    public function it_can_retrieve_user_agent()
+    {
+
+        $this->assertEquals('BaaS-Usergrid/1.0.0', $this->usergrid->getUserAgent());
+    }
+
+    /** @test */
+    public function it_can_set_the_user_agent()
+    {
+
+        $this->usergrid->setUserAgent('Foo/Bar');
+
+        $this->assertEquals('Foo/Bar', $this->usergrid->getUserAgent());
+    }
+
+    /** @test */
+    public function it_can_retrieve_the_manifest_path()
+    {
+
+        $this->assertEquals($this->usergrid->getManifestPath(), $this->usergrid->getManifestPath());
+    }
+
+    /** @test */
+    public function it_can_set_the_manifest_path()
+    {
+        $this->usergrid->setManifestPath('/usr/foo/bar');
+
+        $this->assertEquals('/usr/foo/bar', $this->usergrid->getManifestPath());
+    }
+
+    /** @test */
+    public function it_can_retrieve_api_version()
+    {
+        $this->assertEquals('1.0.1', $this->usergrid->getVersion());
+    }
+
+    /** @test */
+    public function it_can_set_api_version()
+    {
+        $this->usergrid->setVersion('1.0.1');
+
+        $this->assertEquals('1.0.1', $this->usergrid->getVersion());
+    }
+
+
+    /** @test */
+    public function it_can_retrieve_the_client_header()
+    {
+        $headers = $this->usergrid->getHeaders();
+
+        $expected = [
+            'Usergrid-Version' => '1.0.1',
+            'Authorization' => 'Bearer ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890'
+        ];
+
+        $this->assertEquals($headers, $expected);
+    }
+
+    /** @test */
+    public function it_can_set_client_headers()
+    {
+        $this->usergrid->setHeaders([
+            'some-header' => 'foo-bar',
+        ]);
+
+        $headers = $this->usergrid->getHeaders();
+
+        $expected = [
+            'Usergrid-Version' => '1.0.1',
+            'Authorization' => 'Bearer ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890',
+            'some-header' => 'foo-bar',
+        ];
+
+        $this->assertEquals($headers, $expected);
+    }
+
+
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php b/sdks/other/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
new file mode 100644
index 0000000..3362bfc
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/Laravel/Facades/UsergridTest.php
@@ -0,0 +1,53 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Tests\Laravel\Facades;
+
+use PHPUnit_Framework_TestCase;
+use ReflectionClass;
+
+/**
+ * Class UsergridTest
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UsergridTest extends PHPUnit_Framework_TestCase
+{
+    /** @test */
+    public function it_can_test_it_is_a_facade()
+    {
+        $facade = new ReflectionClass('Illuminate\Support\Facades\Facade');
+
+        $reflection = new ReflectionClass('Apache\Usergrid\Laravel\Facades\Usergrid');
+
+        $this->assertTrue($reflection->isSubclassOf($facade));
+    }
+
+    /** @test */
+    public function it_can_test_it_is_a_facade_accessor()
+    {
+        $reflection = new ReflectionClass('Apache\Usergrid\Laravel\Facades\Usergrid');
+
+        $method = $reflection->getMethod('getFacadeAccessor');
+        $method->setAccessible(true);
+
+
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/tests/bootstrap.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/tests/bootstrap.php b/sdks/other/php5/apache-usergrid/tests/bootstrap.php
new file mode 100644
index 0000000..edc11d1
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/tests/bootstrap.php
@@ -0,0 +1,61 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+include('vendor/autoload.php');
+
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+$config = [
+
+    'usergrid' => [
+
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1',
+        'orgName' => null,
+        'appName' => null,
+        'manifestPath' => null,
+        //its better not to set the real values here if using laravel set them in a .env file or
+        // if your not using Laravel set them as environment variable and include them here using $_ENV global.
+        // so that way you can be sure not to commit privates ID to a public repo
+        'clientId' => null,
+        'clientSecret' => null,
+        'username' => null,
+        'password' => null,
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$boot = new UsergridBootstrapper($config);
+$usergrid = $boot->createUsergrid();
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/Gemfile
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/Gemfile b/sdks/other/ruby-on-rails/Gemfile
new file mode 100644
index 0000000..60aff2b
--- /dev/null
+++ b/sdks/other/ruby-on-rails/Gemfile
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+source 'https://rubygems.org'
+
+# Specify your gem's dependencies in usergrid_ironhorse.gemspec
+gemspec

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/LICENSE.txt
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/LICENSE.txt b/sdks/other/ruby-on-rails/LICENSE.txt
new file mode 100644
index 0000000..ae1e83e
--- /dev/null
+++ b/sdks/other/ruby-on-rails/LICENSE.txt
@@ -0,0 +1,14 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/README.md b/sdks/other/ruby-on-rails/README.md
new file mode 100644
index 0000000..dce855b
--- /dev/null
+++ b/sdks/other/ruby-on-rails/README.md
@@ -0,0 +1,212 @@
+# Apache Usergrid_ironhorse
+
+Usergrid_ironhorse is based on Usergrid_iron and enables Ruby or Rails applications
+native Rails-style access to Apigee's App Services (aka Usergrid) REST API.
+
+## Compatibility
+
+**Usergrid_ironhorse is currently only compatible with Ruby on Rails 3.2.**
+
+Thus, if you are using Rails 4.x, you must use Usergrid_iron (the low-level API for Ruby).
+Alternatively, we would welcome your contributions to make Usergrid_ironhorse compatible with Rails 4.x. Thanks!
+
+## Installation
+
+Add this line to your application's Gemfile:
+
+    gem 'usergrid_ironhorse'
+
+And then execute:
+
+    $ bundle
+
+Or install it yourself as:
+
+    $ gem install usergrid_ironhorse
+
+
+## Usage
+
+### Not familiar with Usergrid's App Services?
+
+#### It's great stuff! Check it out, here:
+
+  Docs: <https://usergrid.apache.org/docs/>  
+  Open source: <https://github.com/usergrid/usergrid/>
+
+### Getting started with the Usergrid_ironhorse SDK is super simple!
+
+#### Setup
+
+* Add 'gem usergrid_ironhorse' to your Gemfile
+* Create a 'config/usergrid.yml' file that looks something like this (the
+auth_token is your application token):
+
+```
+development:
+  application_url: http://localhost:8080/my-organization/my-application
+  client_id: YXA6BVYasLdNEeKBd1A2yYstg
+  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
+  require_login: false
+
+test:
+  application_url: http://localhost:8080/my-organization/my-application
+  client_id: YXA6BVYasLdNEeKBd1A2yYstg
+  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
+  require_login: false
+
+production:
+  application_url: http://api.usergrid.com/my-organization/my-application
+  client_id: YXA6BVYasLdNEeKBd1A2yYstg
+  client_secret: YXA60Dnbzaxg1ObkE8ffsIxsGzsSo8
+  require_login: false
+```
+
+#### Get going!
+
+* Subclass Usergrid::Ironhorse::Base for your models.
+Your models will automatically be stored in a collection according to the name of your
+class as defined by Rails' ActiveModel::Naming module. (Which you may override by
+implementing model_name if desired.)
+
+```
+class Developer < Usergrid::Ironhorse::Base
+  validates :name, :presence => true  # Yes, of course you can use validation
+
+end
+```
+
+* Now just use the Rails methods you're already familiar with:
+
+```
+
+    dev = Developer.new language: 'Ruby'
+    dev.valid? # nope!
+    dev.errors # {:name=>["can't be blank"]}
+    dev.name = 'Scott'
+    dev.save!
+
+    dev = Developer.find_or_create_by_name 'Scott'
+    dev.favorite_color = 'green' # assign new attributes automatically
+
+    dev = Developer.find_by_name 'Scott'
+```
+
+* BTW: If you need to do management tasks, wrapping the work in an as_admin block
+will use the auth_token from your settings:
+
+```
+User.as_admin do
+  # do protected task
+end
+```
+
+
+#### (Optional) Need to have user-specific logins to UserGrid?
+
+* Create a User model and subclass `Usergrid::Ironhorse::Base` and `extend
+Usergrid::Ironhorse::UserContext` like so:
+
+```
+class User < Usergrid::Ironhorse::Base
+  extend Usergrid::Ironhorse::UserContext
+  ...
+end
+```
+
+* Set up your authentication
+	* Use `User.authenticate(username, password, session)` to login.
+	* Use `User.clear_authentication(session)` to log out.
+* Propogate the authentication in your ApplicationController:
+
+```
+before_filter :set_user_context
+def set_user_context
+  User.set_context session
+end
+```
+
+* Optionally, if you need to access the User from your view, you may add something
+like the following to your ApplicationController:
+
+```
+helper_method :current_user
+def current_user
+  User.current_user
+end
+```
+
+## Contributing
+
+We welcome your enhancements!
+
+1. Fork it
+2. Create your feature branch (`git checkout -b my-new-feature`)
+3. Write some broken rspecs.
+4. Fix the rspecs with your new code.
+3. Commit your changes (`git commit -am 'Added some feature'`)
+4. Push your changes to the upstream branch (`git push origin my-new-feature`)
+5. Create new Pull Request
+
+We're shooting for 100% rspec coverage, so keep that in mind!
+
+In order to run the tests, check out the Usergrid open source project
+(https://github.com/usergrid/usergrid/), build, and launch it locally.
+
+(Note: If you change your local Usergrid settings from the default, be sure to update
+usergrid_ironhorse/spec/spec_settings.yaml to match.)
+
+
+## Release notes
+
+### 0.1.1
+* New Features
+  1. Now prefer application client_id and client_secret (instead of auth_token) in usergrid.yml.
+
+### 0.1.0
+* New Features
+  1. next_page() added to return the next page of results from the server. An example of this used in conjunction
+     with to_a() is in base_spec.rb (see "should be able to page through results").
+* Incompatible changes
+  1. each() iteration will now transparently cross page boundaries (as generally expected by Rails users).
+     You may use limit(n) to restrict the result set, but note that limit will retrieve the number of entities
+     specified as a single batch (no paging).
+
+### 0.0.5
+* New Features
+  1. support MassAssignmentSecurity (attr_accessible & attr_protected)
+
+### 0.0.4
+* New Features
+  1. add require_login to config (with ability to skip individual logins)
+
+### 0.0.3
+* Internal
+  1. Improve authentication and user propagation
+
+### 0.0.2
+* New Features
+  1. Authentication and user propagation features
+
+### 0.0.1
+* Initial commit
+  1. Support for most ActiveModel stuff including Validations
+  1. No scoping support
+
+
+## License
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+the ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/Rakefile
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/Rakefile b/sdks/other/ruby-on-rails/Rakefile
new file mode 100644
index 0000000..632aa48
--- /dev/null
+++ b/sdks/other/ruby-on-rails/Rakefile
@@ -0,0 +1,22 @@
+#!/usr/bin/env rake
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require "bundler/gem_tasks"
+
+require 'rspec/core/rake_task'
+RSpec::Core::RakeTask.new(:spec)
+
+RSpec::Core::RakeTask.new("spec:coverage")

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/extensions/hash.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/extensions/hash.rb b/sdks/other/ruby-on-rails/lib/extensions/hash.rb
new file mode 100644
index 0000000..a82062a
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/extensions/hash.rb
@@ -0,0 +1,23 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+class Hash
+
+  def nested_under_indifferent_access
+    self
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/extensions/resource.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/extensions/resource.rb b/sdks/other/ruby-on-rails/lib/extensions/resource.rb
new file mode 100644
index 0000000..b858b92
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/extensions/resource.rb
@@ -0,0 +1,66 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+# overrides methods dealing with auth_token to operate on a thread basis
+module Usergrid
+  class Resource
+
+    def options
+      options = @options.clone
+      require_login = Ironhorse::Base.settings[:require_login] != false
+      if require_login
+        auth_token = Thread.current[:usergrid_auth_token]
+      else
+        unless Ironhorse::Base.settings[:auth_token]
+          as_admin {}
+        end
+        auth_token = Ironhorse::Base.settings[:auth_token]
+      end
+      options[:headers].delete :Authorization
+      options[:headers][:Authorization] = "Bearer #{auth_token}" if auth_token
+      options
+    end
+
+    def as_admin(&block)
+      save_auth_token = Thread.current[:usergrid_auth_token]
+      begin
+        unless Ironhorse::Base.settings[:auth_token]
+          resource = RestClient::Resource.new Ironhorse::Base.settings[:application_url]
+          response = resource['token'].post grant_type: 'client_credentials', client_id: Ironhorse::Base.settings[:client_id], client_secret: Ironhorse::Base.settings[:client_secret]
+          Ironhorse::Base.settings[:auth_token] = MultiJson.load(response)['access_token']
+        end
+        Thread.current[:usergrid_auth_token] = Ironhorse::Base.settings[:auth_token]
+        yield block
+      ensure
+        Thread.current[:usergrid_auth_token] = save_auth_token
+      end
+    end
+
+    # gets user token and automatically set auth header for future requests on this Thread
+    # precondition: resource must already be set to the correct context (application or management)
+    def login(username, password)
+      params = { grant_type: "password", username: username, password: password }
+      response = self['token'].get({ params: params })
+      user_uuid = response.data['user']['uuid']
+      user_access_token = response.data['access_token']
+      Thread.current[:usergrid_user_id] = user_uuid
+      Thread.current[:usergrid_auth_token] = user_access_token
+      @current_user = self["/users/#{user_uuid}"].get.entity
+      response
+    end
+
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/usergrid_ironhorse.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/usergrid_ironhorse.rb b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse.rb
new file mode 100644
index 0000000..0dde1d1
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse.rb
@@ -0,0 +1,39 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'logger'
+require 'active_model'
+require 'rest-client'
+require 'active_support'
+require 'usergrid_iron'
+require 'active_record/errors'
+
+module Usergrid
+  module Ironhorse
+
+    Dir[Pathname.new(File.dirname(__FILE__)).join("extensions/**/*.rb")].each { |f| require f }
+
+    USERGRID_PATH = File.join File.dirname(__FILE__), 'usergrid_ironhorse'
+
+    def self.usergrid_path *path
+      File.join USERGRID_PATH, *path
+    end
+
+    require usergrid_path('base')
+    require usergrid_path('query')
+
+    autoload :UserContext, usergrid_path('user_context')
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/base.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/base.rb b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/base.rb
new file mode 100644
index 0000000..aa6f4d9
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/base.rb
@@ -0,0 +1,370 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'active_record/validations'
+require 'active_record/errors'
+require 'active_record/callbacks'
+
+module Usergrid
+  module Ironhorse
+
+    class Base
+      include ActiveModel::AttributeMethods
+      include ActiveModel::Conversion
+      include ActiveModel::Validations
+      include ActiveModel::Dirty
+      include ActiveModel::Serialization
+      include ActiveModel::MassAssignmentSecurity
+      extend  ActiveModel::Naming
+      extend  ActiveModel::Callbacks
+
+      RESERVED_ATTRIBUTES = %w(metadata created modified uuid type uri)
+
+      define_model_callbacks :create, :destroy, :save, :update
+
+      # todo: determine the subset to support...
+      # unsupported: :group, :joins, :preload, :eager_load, :includes, :from, :lock,
+      #              :having, :create_with, :uniq, :references, :none, :count,
+      #              :average, :minimum, :maximum, :sum, :calculate, :ids
+      #              :find_each, :find_in_batches, :offset, :readonly
+
+      #delegate :find, :take, :take!, :first, :first!, :last, :last!, :exists?, :any?, :many?, :to => :all
+      #delegate :first_or_create, :first_or_create!, :first_or_initialize, :to => :all
+      #delegate :find_by, :find_by!, :to => :all
+      #delegate :destroy, :destroy_all, :delete, :delete_all, :update, :update_all, :to => :all
+      #delegate :find_each, :find_in_batches, :to => :all
+      #delegate :select, :group, :order, :except, :reorder, :limit, :offset,
+      #         :where, :preload, :eager_load, :includes, :from, :lock, :readonly,
+      #         :having, :create_with, :uniq, :references, :none, :to => :all
+      #delegate :count, :average, :minimum, :maximum, :sum, :calculate, :pluck, :ids, :to => :all
+
+      @@settings ||= nil
+
+      attr_accessor :attributes
+
+      HashWithIndifferentAccess = ActiveSupport::HashWithIndifferentAccess
+      RecordNotSaved = ActiveRecord::RecordNotSaved
+
+      def initialize(attrs=nil)
+        @attributes = HashWithIndifferentAccess.new
+        assign_attributes attrs if attrs
+      end
+
+      def self.configure!(application_url, auth_token)
+        @@settings = HashWithIndifferentAccess.new application_url: application_url, auth_token: auth_token
+      end
+
+      def self.settings
+        return @@settings if @@settings
+        path = "config/usergrid.yml"
+        environment = defined?(Rails) && Rails.respond_to?(:env) ? Rails.env : ENV['RACK_ENV']
+        @@settings = HashWithIndifferentAccess.new YAML.load(ERB.new(File.new(path).read).result)[environment]
+      end
+
+      # forward to all
+      def self.method_missing(method, *args, &block)
+        all.send method, *args, &block
+      end
+
+      # forward to all
+      def method_missing(method, *args, &block)
+        if args.size == 0
+          attributes[method]
+        elsif args.size == 1 && method[-1] == '='
+          attr = method[0..-2]
+          if attributes[attr] != args[0]
+            attribute_will_change!(attr)
+            attributes[attr] = args[0]
+          end
+        else
+          all.send method, *args, &block
+        end
+      end
+
+      # todo: scopes
+      def self.all
+        unscoped
+      end
+
+      #def self.scope(symbol, scope)
+      #  @scopes[symbol] = scope
+      #end
+
+      #def self.current_scope
+      #  @current_scope ||= default_scope
+      #end
+      #
+      #def self.current_scope=(scope)
+      #  @current_scope = scope
+      #end
+      #
+      #def self.default_scope
+      #  @default_scope ||= unscoped
+      #end
+
+      def self.unscoped
+        Query.new(self)
+      end
+
+      def self.create(attributes=nil, options=nil, &block)
+        if attributes.is_a?(Array)
+          attributes.collect { |attr| create(attr, options, &block) }
+        else
+          object = new(attributes, &block)
+          object.save
+          object
+        end
+      end
+
+      def self.create!(attributes=nil, options=nil, &block)
+        if attributes.is_a?(Array)
+          attributes.collect {|attr| create!(attr, options, &block)}
+        else
+          object = new(attributes)
+          yield(object) if block_given?
+          object.save!
+          object
+        end
+      end
+
+      def self.class_attributes
+        @class_attributes ||= {}
+      end
+
+      # Returns true if the record is persisted, i.e. it's not a new record and it was
+      # not destroyed, otherwise returns false.
+      def persisted?
+        !(new_record? || destroyed?)
+      end
+
+      def new_record?
+        !self.uuid
+      end
+
+      def self.group
+        model_name.plural.downcase
+      end
+
+      # Creates a Usergrid::Resource
+      def self.resource
+        app = Usergrid::Application.new settings[:application_url]
+        #app.auth_token = Thread.current[:usergrid_auth_token]
+        app[group]
+      end
+
+      # Saves the model.
+      #
+      # If the model is new a record gets created in the database, otherwise
+      # the existing record gets updated.
+      #
+      # By default, save always run validations. If any of them fail the action
+      # is cancelled and +save+ returns +false+. However, if you supply
+      # :validate => false, validations are bypassed altogether. See
+      # ActiveRecord::Validations for more information.
+      #
+      # There's a series of callbacks associated with +save+. If any of the
+      # <tt>before_*</tt> callbacks return +false+ the action is cancelled and
+      # +save+ returns +false+. See ActiveRecord::Callbacks for further
+      # details.
+      def save
+        begin
+          create_or_update
+        rescue ActiveRecord::RecordInvalid
+          false
+        end
+      end
+
+      # Saves the model.
+      #
+      # If the model is new a record gets created in the database, otherwise
+      # the existing record gets updated.
+      #
+      # With <tt>save!</tt> validations always run. If any of them fail
+      # ActiveRecord::RecordInvalid gets raised. See ActiveRecord::Validations
+      # for more information.
+      #
+      # There's a series of callbacks associated with <tt>save!</tt>. If any of
+      # the <tt>before_*</tt> callbacks return +false+ the action is cancelled
+      # and <tt>save!</tt> raises ActiveRecord::RecordNotSaved. See
+      # ActiveRecord::Callbacks for further details.
+      def save!
+        create_or_update or raise RecordNotSaved
+      end
+
+      # Deletes the record in the database and freezes this instance to
+      # reflect that no changes should be made (since they can't be
+      # persisted). Returns the frozen instance.
+      #
+      # The row is simply removed with a +DELETE+ statement on the
+      # record's primary key, and no callbacks are executed.
+      #
+      # To enforce the object's +before_destroy+ and +after_destroy+
+      # callbacks, Observer methods, or any <tt>:dependent</tt> association
+      # options, use <tt>#destroy</tt>.
+      def delete
+        self.class.delete(id) if persisted?
+        @destroyed = true
+        freeze
+      end
+
+      # Deletes the record in the database and freezes this instance to reflect
+      # that no changes should be made (since they can't be persisted).
+      #
+      # There's a series of callbacks associated with <tt>destroy</tt>. If
+      # the <tt>before_destroy</tt> callback return +false+ the action is cancelled
+      # and <tt>destroy</tt> returns +false+. See
+      # ActiveRecord::Callbacks for further details.
+      def destroy
+        raise ReadOnlyRecord if readonly?
+        # todo: callbacks?
+        instance_resource.delete if persisted?
+        @destroyed = true
+        freeze
+      end
+
+      # Deletes the record in the database and freezes this instance to reflect
+      # that no changes should be made (since they can't be persisted).
+      #
+      # There's a series of callbacks associated with <tt>destroy!</tt>. If
+      # the <tt>before_destroy</tt> callback return +false+ the action is cancelled
+      # and <tt>destroy!</tt> raises ActiveRecord::RecordNotDestroyed. See
+      # ActiveRecord::Callbacks for further details.
+      def destroy!
+        destroy || raise(ActiveRecord::RecordNotDestroyed)
+      end
+
+      # Returns true if this object has been destroyed, otherwise returns false.
+      def destroyed?
+        !!@destroyed
+      end
+
+      # Reloads the attributes of this object from the database.
+      def reload
+        return false if !persisted?
+        fresh_object = self.class.find(id)
+        refresh_data fresh_object.instance_variable_get('@attributes')
+        self
+      end
+
+      # Updates the attributes of the model from the passed-in hash and saves the
+      # record, all wrapped in a transaction. If the object is invalid, the saving
+      # will fail and false will be returned.
+      def update_attributes(attributes)
+        assign_attributes attributes
+        save
+      end
+
+      # Updates its receiver just like +update_attributes+ but calls <tt>save!</tt> instead
+      # of +save+, so an exception is raised if the record is invalid.
+      def update_attributes!(attributes)
+        assign_attributes attributes
+        save!
+      end
+
+      # Note that whenever you include ActiveModel::AttributeMethods in your class,
+      # it requires you to implement an +attributes+ method which returns a hash
+      # with each attribute name in your model as hash key and the attribute value as
+      # hash value.
+      #
+      # Hash keys must be strings.
+      def attributes
+        @attributes ||= self.class.class_attributes.clone
+      end
+
+      def id; self.uuid end
+      def created_at; self.created end
+      def updated_at; self.modified end
+
+
+      protected
+
+
+      def assign_attributes(attrs)
+        attrs = sanitize_for_mass_assignment(attrs)
+        attrs.each do |attr,value|
+          attr = attr.to_s
+          unless attributes[attr] == value
+            attribute_will_change!(attr) unless RESERVED_ATTRIBUTES.include? attr
+            attributes[attr] = value
+          end
+        end
+      end
+
+      def create_or_update
+        raise ReadOnlyRecord if readonly?
+        if valid?
+          run_callbacks :save do
+            return new_record? ? do_create : do_update
+          end
+        end
+        false
+      end
+
+      def do_create
+        group_resource.post(unsaved_attributes) do |resp, req, res, &block|
+          if resp.code.to_s == "200" || resp.code.to_s == "201"
+            refresh_data resp.entity_data
+            return true
+          else
+            errors.add(resp.code.to_s, resp)
+            return false
+          end
+        end
+      end
+
+      def do_update
+        return false unless changed?
+
+        instance_resource.put(unsaved_attributes) do |resp, req, res, &block|
+          if resp.code.to_s == "200" || resp.code.to_s == "201"
+            refresh_data resp.entity_data
+            return true
+          else
+            errors.add(resp.code, resp)
+            return false
+          end
+        end
+      end
+
+      def unsaved_attributes
+        HashWithIndifferentAccess[changed.collect {|k| [k, attributes[k]]}]
+      end
+
+      def group_resource
+        self.class.resource
+      end
+
+      def instance_resource
+        self.class.resource["#{self.id}"]
+      end
+
+      def refresh_data(entity_data)
+        @previously_changed = changes
+        @changed_attributes.clear
+        @attributes = HashWithIndifferentAccess.new entity_data
+      end
+
+      def attribute_will_change!(attr)
+        begin
+          value = __send__(attr)
+          value = value.duplicable? ? value.clone : value
+        rescue TypeError, NoMethodError
+        end
+
+        changed_attributes[attr] = value unless changed_attributes.include?(attr)
+      end
+    end
+  end
+end


[18/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
new file mode 100644
index 0000000..4006819
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Roles.php
@@ -0,0 +1,381 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'roles'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'find' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query Roles.',
+        'summary' => 'Query the roles collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'roles'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'findById' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
+        'notes' => 'Find Role by uuid.',
+        'summary' => 'Find role by uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'roles'
+            ],
+            'uuid' => [
+                'description' => 'Group UUID (entity uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'create' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new Role.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new Role entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'roles'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'destroy' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete a Role entity.',
+        'summary' => 'Delete a Role entity by name or uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'roles'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'update' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update a Role entity.',
+        'summary' => 'Update a Roles entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Role',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'r'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Users.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
new file mode 100644
index 0000000..0f28d4d
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
@@ -0,0 +1,381 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'find' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query Users.',
+        'summary' => 'Query the users collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'findById' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
+        'notes' => 'Find User by uuid.',
+        'summary' => 'Find user by uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'uuid' => [
+                'description' => 'User UUID (entity uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'create' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new User.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new User entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'destroy' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete a User entity.',
+        'summary' => 'Delete a User entity by name or uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'update' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update a User entity.',
+        'summary' => 'Update a User entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/applications.json b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
new file mode 100644
index 0000000..f747154
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/swagger-json/applications.json
@@ -0,0 +1,1262 @@
+{
+    "basePath": "${basePath}",
+    "swaggerVersion": "1.1-SHAPSHOT.121026",
+    "apiVersion": "0.1",
+    "apis": [
+        {
+            "path": "/apps/{app_name_or_uuid}/token",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_auth_password_get",
+                    "summary": "Get app access token",
+                    "notes": "Get the app access token.  See the OAuth2 specification for details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "grant_type",
+                            "dataType": "string",
+                            "description": "Grant type",
+                            "defaultValue": "password",
+                            "allowableValues": {
+                                "values": [
+                                    "password",
+                                    "client_credentials",
+                                    "refresh_token",
+                                    "authorization_code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_secret",
+                            "dataType": "string",
+                            "description": "Client Secret (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_auth_password_post",
+                    "summary": "Get app access token",
+                    "notes": "Get the app access token.  See the OAuth2 specification for details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "grant_type",
+                            "dataType": "string",
+                            "description": "Grant type",
+                            "defaultValue": "password",
+                            "allowableValues": {
+                                "values": [
+                                    "password",
+                                    "client_credentials",
+                                    "refresh_token",
+                                    "authorization_code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password (for grant_type=password)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "client_secret",
+                            "dataType": "string",
+                            "description": "Client Secret (for grant_type=client_credentials)",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/authorize",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_authorize_get",
+                    "summary": "Authorize app client",
+                    "notes": "Authorize the app client.  See the OAuth2 specification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "response_type",
+                            "dataType": "string",
+                            "description": "Response type",
+                            "defaultValue": "token",
+                            "allowableValues": {
+                                "values": [
+                                    "token",
+                                    "code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "redirect_uri",
+                            "dataType": "string",
+                            "description": "Redirect URI",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "scope",
+                            "dataType": "string",
+                            "description": "Access Token Scope",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "state",
+                            "dataType": "string",
+                            "description": "Client State",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_authorize_post",
+                    "summary": "Authorize app client",
+                    "notes": "Authorize the app client.  See the OAuth2 specification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "response_type",
+                            "dataType": "string",
+                            "description": "Response type",
+                            "defaultValue": "token",
+                            "allowableValues": {
+                                "values": [
+                                    "token",
+                                    "code"
+                                ],
+                                "valueType": "LIST"
+                            },
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "client_id",
+                            "dataType": "string",
+                            "description": "Client ID",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "redirect_uri",
+                            "dataType": "string",
+                            "description": "Redirect URI",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "scope",
+                            "dataType": "string",
+                            "description": "Access Token Scope",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "state",
+                            "dataType": "string",
+                            "description": "Client State",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "Password",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/credentials",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_credentials_get",
+                    "summary": "Get app client credentials",
+                    "notes": "Get the app client credentials.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_credentials_post",
+                    "summary": "Generate app client credentials",
+                    "notes": "Generate new app client credentials.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_user_json_post",
+                    "summary": "Create new app user",
+                    "notes": "Create new app user.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "User to post",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_user_form_post",
+                    "summary": "Create new app user",
+                    "notes": "Create new app user using form post parameters.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "username",
+                            "dataType": "string",
+                            "description": "Username",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "name",
+                            "dataType": "string",
+                            "description": "User Full Name",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "User Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "password",
+                            "dataType": "string",
+                            "description": "User Password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/resetpw",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_users_reset_password_get",
+                    "summary": "Initiate a user password reset",
+                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_users_reset_password_form_post",
+                    "summary": "Complete a user password reset",
+                    "notes": "Complete a user password reset.  Handles form POST response.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "email",
+                            "dataType": "string",
+                            "description": "User Email",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_challenge_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Challenge Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_response_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Response Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_user_get",
+                    "summary": "Returns the app user details",
+                    "notes": "Returns the app user details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "app_user_json_put",
+                    "summary": "Updates the app user details",
+                    "notes": "Updates the app user details.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "App user details",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_user_activate_get",
+                    "summary": "Activates the app user",
+                    "notes": "Activates the app user from link provided in email notification.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "token",
+                            "dataType": "string",
+                            "description": "Activation Token (supplied via email)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "confirm",
+                            "dataType": "boolean",
+                            "description": "Send confirmation email",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_user_reactivate_get",
+                    "summary": "Reactivates the app user",
+                    "notes": "Request app user reactivation.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_user_feed_get",
+                    "summary": "Get app user activity feed",
+                    "notes": "Get app user activity feed.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "app_user_password_json_put",
+                    "summary": "Set app user password",
+                    "notes": "Set app user password.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "access_token",
+                            "dataType": "string",
+                            "description": "The OAuth2 access token",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "Old and new password",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "User not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_user_reset_password_get",
+                    "summary": "Initiate a user password reset",
+                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_user_reset_password_form_post",
+                    "summary": "Complete a user password reset",
+                    "notes": "Complete a user password reset.  Handles form POST response.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "user_username_email_or_uuid",
+                            "dataType": "string",
+                            "description": "User username, email or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "recaptcha_challenge_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Challenge Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        },
+                        {
+                            "name": "recaptcha_response_field",
+                            "dataType": "string",
+                            "description": "Recaptcha Response Field",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "post"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/{collection}",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "GET",
+                    "nickname": "app_entity_get",
+                    "summary": "Query an app collection",
+                    "notes": "Query an app collection.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "collection",
+                            "dataType": "string",
+                            "description": "collection name (entity type)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "ql",
+                            "dataType": "string",
+                            "description": "a query in the query language",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "reversed",
+                            "dataType": "boolean",
+                            "description": "return results in reverse order",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "start",
+                            "dataType": "string",
+                            "description": "the first entity UUID to return",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "cursor",
+                            "dataType": "string",
+                            "description": "an encoded representation of the query position for paging",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "limit",
+                            "dataType": "integer",
+                            "description": "an encoded representation of the query position for paging",
+                            "required": false,
+                            "allowMultiple": false,
+                            "paramType": "query"
+                        },
+                        {
+                            "name": "filter",
+                            "dataType": "integer",
+                            "description": "a condition to filter on",
+                            "required": false,
+                            "allowMultiple": true,
+                            "paramType": "query"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "POST",
+                    "nickname": "app_entity_json_post",
+                    "summary": "Create new app entity",
+                    "notes": "Create new app entity.  See Usergrid documentation for JSON format of body.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "collection",
+                            "dataType": "string",
+                            "description": "collection name (entity type)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "User to post",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        },
+        {
+            "path": "/apps/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}",
+            "description": "Applications",
+            "operations": [
+                {
+                    "httpMethod": "PUT",
+                    "nickname": "app_entity_put",
+                    "summary": "Update an app entity",
+                    "notes": "Update an app entity in a collection.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "collection",
+                            "dataType": "string",
+                            "description": "collection name (entity type)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "entity_name_or_uuid",
+                            "dataType": "string",
+                            "description": "entity name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "json",
+                            "dataType": "string",
+                            "description": "User to post",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "body"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                },
+                {
+                    "httpMethod": "DELETE",
+                    "nickname": "app_entity_delete",
+                    "summary": "Delete an app entity",
+                    "notes": "Delete an app entity.",
+                    "responseTypeInternal": "",
+                    "responseClass": "response",
+                    "parameters": [
+                        {
+                            "name": "app_name_or_uuid",
+                            "dataType": "string",
+                            "description": "app name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "collection",
+                            "dataType": "string",
+                            "description": "collection name (entity type)",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        },
+                        {
+                            "name": "entity_name_or_uuid",
+                            "dataType": "string",
+                            "description": "entity name or uuid",
+                            "required": true,
+                            "allowMultiple": false,
+                            "paramType": "path"
+                        }
+                    ],
+                    "errorResponses": [
+                        {
+                            "reason": "Invalid ID supplied",
+                            "code": 400
+                        },
+                        {
+                            "reason": "Application not found",
+                            "code": 404
+                        }
+                    ]
+                }
+            ]
+        }
+    ],
+    "models": {
+        "response": {
+            "properties": {
+                "id": {
+                    "type": "long"
+                },
+                "name": {
+                    "type": "string"
+                }
+            },
+            "id": "response"
+        }
+    }
+}
\ No newline at end of file


[38/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGEntityViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGEntityViewController.h b/sdks/ios/samples/Browser/browser/UGEntityViewController.h
deleted file mode 100644
index af95c4c..0000000
--- a/sdks/ios/samples/Browser/browser/UGEntityViewController.h
+++ /dev/null
@@ -1,22 +0,0 @@
-//
-//  UGEntityViewController.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@interface UGEntityViewController : UITableViewController
-@property (nonatomic, strong) NSDictionary *entity;
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGEntityViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGEntityViewController.m b/sdks/ios/samples/Browser/browser/UGEntityViewController.m
deleted file mode 100644
index 7cb2d17..0000000
--- a/sdks/ios/samples/Browser/browser/UGEntityViewController.m
+++ /dev/null
@@ -1,86 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGEntityViewController.m
-//  Browser
-//
-
-#import "UGEntityViewController.h"
-#import "UGTextViewController.h"
-
-@interface UGEntityViewController ()
-
-@end
-
-@implementation UGEntityViewController
-
-- (id)initWithStyle:(UITableViewStyle)style
-{
-    self = [super initWithStyle:style];
-    if (self) {
-        // Custom initialization
-    }
-    return self;
-}
-
-- (void) loadView
-{
-    [super loadView];
-    self.navigationItem.title = self.entity[@"name"];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    return [self.entity count];
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
-    return cell;
-}
-
-#pragma mark - Table view delegate
-
-- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    NSArray *keys = [[self.entity allKeys] sortedArrayUsingSelector:@selector(compare:)];
-    NSString *key = keys[[indexPath row]];
-    cell.textLabel.text = key;
-    id entity = self.entity[key];
-    cell.detailTextLabel.text = [entity description];
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    NSArray *keys = [[self.entity allKeys] sortedArrayUsingSelector:@selector(compare:)];
-    NSString *key = keys[[indexPath row]];
-    UGTextViewController *textViewController = [[UGTextViewController alloc] init];
-    textViewController.key = key;
-    textViewController.binding = self.entity;
-    [self.navigationController pushViewController:textViewController animated:YES];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGSignInViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGSignInViewController.h b/sdks/ios/samples/Browser/browser/UGSignInViewController.h
deleted file mode 100644
index 58481cf..0000000
--- a/sdks/ios/samples/Browser/browser/UGSignInViewController.h
+++ /dev/null
@@ -1,24 +0,0 @@
-//
-//  UGSignInViewController.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@class UGAppViewController;
-
-@interface UGSignInViewController : UITableViewController
-@property (nonatomic, weak) UGAppViewController *appViewController;
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGSignInViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGSignInViewController.m b/sdks/ios/samples/Browser/browser/UGSignInViewController.m
deleted file mode 100644
index 7e346c9..0000000
--- a/sdks/ios/samples/Browser/browser/UGSignInViewController.m
+++ /dev/null
@@ -1,185 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGSignInViewController.m
-//  Browser
-//
-
-#import "UGHTTPClient.h"
-#import "UGConnection.h"
-#import "UGSignInViewController.h"
-#import "UGAppViewController.h"
-
-#define SERVER @"http://api.usergrid.com"
-
-@interface UGFormTableViewCell : UITableViewCell <UITextFieldDelegate>
-@property (nonatomic, strong) UILabel *label;
-@property (nonatomic, strong) UITextField *textField;
-@property (nonatomic, strong) NSString *key;
-@property (nonatomic, weak) id binding;
-@end
-
-@implementation UGFormTableViewCell
-
-- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
-{
-    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
-        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
-        self.label.backgroundColor = [UIColor clearColor];
-        self.label.font = [UIFont systemFontOfSize:10];
-        self.label.textColor = [UIColor grayColor];
-        self.label.textAlignment = UITextAlignmentLeft;
-        [self.contentView addSubview:self.label];
-        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
-        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
-        self.textField.font = [UIFont systemFontOfSize:18];
-        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
-        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
-        self.textField.delegate = self;
-        if ([key isEqualToString:@"password"]) {
-            self.textField.secureTextEntry = YES;
-        }
-        [self.contentView addSubview:self.textField];
-        self.selectionStyle = UITableViewCellSelectionStyleNone;
-        // individual cell properties
-        self.label.text = title;
-        self.key = key;
-        self.binding = binding;
-    }
-    return self;
-}
-
-- (void) layoutSubviews
-{
-    [super layoutSubviews];
-    CGRect textFieldFrame = self.textField.frame;
-    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
-    self.textField.frame = textFieldFrame;
-}
-
-- (void) textFieldDidEndEditing:(UITextField *)textField
-{
-    [self.binding setObject:textField.text forKey:self.key];
-}
-
-@end
-
-@interface UGSignInViewController ()
-@property (nonatomic, strong) NSMutableDictionary *values;
-@property (nonatomic, strong) NSArray *cells;
-@end
-
-@implementation UGSignInViewController
-
-- (id)init {
-    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
-        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
-        if (!self.values) {
-            self.values = [NSMutableDictionary dictionary];
-            [self.values setObject:SERVER forKey:@"server"];
-        }
-        self.cells =
-        @[[[UGFormTableViewCell alloc] initWithTitle:@"Server" key:@"server" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Organization" key:@"organization" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Application" key:@"application" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Username" key:@"username" binding:self.values],
-          [[UGFormTableViewCell alloc] initWithTitle:@"Password" key:@"password" binding:self.values]];
-    }
-    return self;
-}
-
-- (void) loadView
-{
-    [super loadView];
-    self.title = @"Connection";
-    self.tableView.backgroundView = nil;
-    self.tableView.backgroundColor = [UIColor darkGrayColor];
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithTitle:@"Cancel"
-                                             style:UIBarButtonItemStyleBordered
-                                             target:self
-                                             action:@selector(cancel:)];
-    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
-                                              initWithTitle:@"Sign In"
-                                              style:UIBarButtonItemStyleBordered
-                                              target:self
-                                              action:@selector(signin:)];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 1;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    return [self.cells count];
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    return [self.cells objectAtIndex:[indexPath row]];
-}
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UGFormTableViewCell *formCell = (UGFormTableViewCell *) cell;
-    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    UGFormTableViewCell *formCell = (UGFormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
-    [formCell.textField becomeFirstResponder];
-}
-
-#pragma mark - Sign In
-
-- (void) cancel:(id) sender
-{
-    [self dismissModalViewControllerAnimated:YES];
-}
-
-- (void) signin:(id) sender
-{
-    for (UGFormTableViewCell *cell in self.cells) {
-        [cell.textField resignFirstResponder];
-    }
-    [[NSUserDefaults standardUserDefaults] setObject:self.values forKey:@"usergrid"];
-    [[NSUserDefaults standardUserDefaults] synchronize];
-    
-    UGConnection *connection = [UGConnection sharedConnection];
-    connection.server = [self.values objectForKey:@"server"];
-    connection.organization = [self.values objectForKey:@"organization"];
-    connection.application = [self.values objectForKey:@"application"];
-    
-    [[[UGHTTPClient alloc] initWithRequest:
-      [connection getAccessTokenForApplicationWithUsername:[self.values objectForKey:@"username"]
-                                              password:[self.values objectForKey:@"password"]]]
-     connectWithCompletionHandler:^(UGHTTPResult *result) {
-         [connection authenticateWithResult:result];
-         [(UGAppViewController *) self.appViewController downloadApplicationDescription];
-         [self dismissModalViewControllerAnimated:YES];
-     }];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGTextViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGTextViewController.h b/sdks/ios/samples/Browser/browser/UGTextViewController.h
deleted file mode 100644
index 57e2c8f..0000000
--- a/sdks/ios/samples/Browser/browser/UGTextViewController.h
+++ /dev/null
@@ -1,23 +0,0 @@
-//
-//  UGTextViewController.h
-//  Browser
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-@interface UGTextViewController : UIViewController
-@property (nonatomic, strong) NSString *key;
-@property (nonatomic, strong) NSDictionary *binding;
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/UGTextViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/UGTextViewController.m b/sdks/ios/samples/Browser/browser/UGTextViewController.m
deleted file mode 100644
index d428913..0000000
--- a/sdks/ios/samples/Browser/browser/UGTextViewController.m
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  UGTextViewController.m
-//  Browser
-//
-
-
-#import "UGTextViewController.h"
-
-@interface UGTextViewController ()
-@property (nonatomic, strong) UITextView *textView;
-@end
-
-@implementation UGTextViewController
-
-- (void) loadView
-{
-    [super loadView];
-    self.textView = [[UITextView alloc] initWithFrame:self.view.bounds];
-    self.textView.autoresizingMask = UIViewAutoresizingFlexibleWidth+UIViewAutoresizingFlexibleHeight;
-    self.textView.font = [UIFont systemFontOfSize:20];
-    [self.view addSubview:self.textView];
-    self.textView.text = [self.binding[self.key] description];
-    self.navigationItem.title = self.key;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/browser-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/browser-Info.plist b/sdks/ios/samples/Browser/browser/browser-Info.plist
deleted file mode 100644
index 212588c..0000000
--- a/sdks/ios/samples/Browser/browser/browser-Info.plist
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
--->
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>en</string>
-	<key>CFBundleDisplayName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleShortVersionString</key>
-	<string>1.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>LSRequiresIPhoneOS</key>
-	<true/>
-	<key>UIRequiredDeviceCapabilities</key>
-	<array>
-		<string>armv7</string>
-	</array>
-	<key>UISupportedInterfaceOrientations</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-	<key>UISupportedInterfaceOrientations~ipad</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationPortraitUpsideDown</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-</dict>
-</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/browser-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/browser-Prefix.pch b/sdks/ios/samples/Browser/browser/browser-Prefix.pch
deleted file mode 100644
index 86a5940..0000000
--- a/sdks/ios/samples/Browser/browser/browser-Prefix.pch
+++ /dev/null
@@ -1,14 +0,0 @@
-//
-// Prefix header for all source files of the 'browser' target in the 'browser' project
-//
-
-#import <Availability.h>
-
-#ifndef __IPHONE_3_0
-#warning "This project uses features only available in iOS SDK 3.0 and later."
-#endif
-
-#ifdef __OBJC__
-    #import <UIKit/UIKit.h>
-    #import <Foundation/Foundation.h>
-#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/en.lproj/InfoPlist.strings b/sdks/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
deleted file mode 100644
index 477b28f..0000000
--- a/sdks/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,2 +0,0 @@
-/* Localized versions of Info.plist keys */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Browser/browser/main.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Browser/browser/main.m b/sdks/ios/samples/Browser/browser/main.m
deleted file mode 100644
index 11cecbf..0000000
--- a/sdks/ios/samples/Browser/browser/main.m
+++ /dev/null
@@ -1,30 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  main.m
-//  Browser
-//
-
-#import "UGAppDelegate.h"
-
-int main(int argc, char *argv[])
-{
-    @autoreleasepool {
-        return UIApplicationMain(argc, argv, nil, NSStringFromClass([UGAppDelegate class]));
-    }
-}


[15/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/query.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/query.rb b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/query.rb
new file mode 100644
index 0000000..6562b8f
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/query.rb
@@ -0,0 +1,929 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# http://guides.rubyonrails.org/active_record_querying.html
+
+module Usergrid
+  module Ironhorse
+
+    class Query
+
+      RecordNotFound = ActiveRecord::RecordNotFound
+
+      def initialize(model_class)
+        @model_class = model_class
+        @options = {}
+      end
+
+      ## Initializes new record from relation while maintaining the current
+      ## scope.
+      ##
+      ## Expects arguments in the same format as +Base.new+.
+      ##
+      ##   users = User.where(name: 'DHH')
+      ##   user = users.new # => #<User id: nil, name: "DHH", created_at: nil, updated_at: nil>
+      ##
+      ## You can also pass a block to new with the new record as argument:
+      ##
+      ##   user = users.new { |user| user.name = 'Oscar' }
+      ##   user.name # => Oscar
+      #def new(*args, &block)
+      #  scoping { @model_class.new(*args, &block) }
+      #end
+
+      # Find by uuid or name - This can either be a specific uuid or name (1), a list of uuids
+      # or names (1, 5, 6), or an array of uuids or names ([5, 6, 10]).
+      # If no record can be found for all of the listed ids, then RecordNotFound will be raised.
+      #
+      #   Person.find(1)       # returns the object for ID = 1
+      #   Person.find("1")     # returns the object for ID = 1
+      #   Person.find(1, 2, 6) # returns an array for objects with IDs in (1, 2, 6)
+      #   Person.find([7, 17]) # returns an array for objects with IDs in (7, 17)
+      #   Person.find([1])     # returns an array for the object with ID = 1
+      #   Person.where("administrator = 1").order("created_on DESC").find(1)
+      #
+      def find(*ids)
+        raise RecordNotFound unless ids
+        ids = ids.first if ids.first.is_a? Array
+        @records = ids.collect { |id| find_one! id } # todo: can this be optimized in one call?
+        #entities = @model_class.resource[ids.join '&'].get.entities
+        #raise RecordNotFound unless (entities.size == ids.size)
+        #@records = entities.collect {|entity| @model_class.model_name.constantize.new(entity.data) }
+        @records.size == 1 ? @records.first : @records
+      end
+
+      # Finds the first record matching the specified conditions. There
+      # is no implied ordering so if order matters, you should specify it
+      # yourself.
+      #
+      # If no record is found, returns <tt>nil</tt>.
+      #
+      #   Post.find_by name: 'Spartacus', rating: 4
+      #   Post.find_by "published_at < ?", 2.weeks.ago
+      def find_by(*conditions)
+        where(*conditions).take
+      end
+
+      # Like <tt>find_by</tt>, except that if no record is found, raises
+      # an <tt>ActiveRecord::RecordNotFound</tt> error.
+      def find_by!(*conditions)
+        where(*conditions).take!
+      end
+
+      # Gives a record (or N records if a parameter is supplied) without any implied
+      # order.
+      #
+      #   Person.take # returns an object fetched by SELECT * FROM people
+      #   Person.take(5) # returns 5 objects fetched by SELECT * FROM people LIMIT 5
+      #   Person.where(["name LIKE '%?'", name]).take
+      def take(limit=1)
+        limit(limit).to_a
+      end
+
+      # Same as +take+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
+      # is found. Note that <tt>take!</tt> accepts no arguments.
+      def take!
+        take or raise RecordNotFound
+      end
+
+      # Find the first record (or first N records if a parameter is supplied).
+      # If no order is defined it will order by primary key.
+      #
+      #   Person.first # returns the first object fetched by SELECT * FROM people
+      #   Person.where(["user_name = ?", user_name]).first
+      #   Person.where(["user_name = :u", { :u => user_name }]).first
+      #   Person.order("created_on DESC").offset(5).first
+      #   Person.first(3) # returns the first three objects fetched by SELECT * FROM people LIMIT 3
+      def first(limit=1)
+        limit(limit).load.first
+      end
+
+      # Same as +first+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
+      # is found. Note that <tt>first!</tt> accepts no arguments.
+      def first!
+        first or raise RecordNotFound
+      end
+
+      # Find the last record (or last N records if a parameter is supplied).
+      # If no order is defined it will order by primary key.
+      #
+      #   Person.last # returns the last object fetched by SELECT * FROM people
+      #   Person.where(["user_name = ?", user_name]).last
+      #   Person.order("created_on DESC").offset(5).last
+      #   Person.last(3) # returns the last three objects fetched by SELECT * FROM people.
+      #
+      # Take note that in that last case, the results are sorted in ascending order:
+      #
+      #   [#<Person id:2>, #<Person id:3>, #<Person id:4>]
+      #
+      # and not:
+      #
+      #   [#<Person id:4>, #<Person id:3>, #<Person id:2>]
+      def last(limit=1)
+        limit(limit).reverse_order.load.first
+      end
+
+      # Same as +last+ but raises <tt>ActiveRecord::RecordNotFound</tt> if no record
+      # is found. Note that <tt>last!</tt> accepts no arguments.
+      def last!
+        last or raise RecordNotFound
+      end
+
+      def each
+        to_a.each { |*block_args| yield(*block_args) }
+        while @response.data['cursor'] && !limit_value
+          next_page
+          to_a.each { |*block_args| yield(*block_args) }
+        end
+      end
+
+      def next_page
+        @options[:cursor] = @response.data['cursor']
+        @records = nil
+        load
+        self
+      end
+
+      # Returns +true+ if a record exists in the table that matches the +id+ or
+      # conditions given, or +false+ otherwise. The argument can take six forms:
+      #
+      # * String - Finds the record with a primary key corresponding to this
+      #   string (such as <tt>'5'</tt>).
+      # * Array - Finds the record that matches these +find+-style conditions
+      #   (such as <tt>['color = ?', 'red']</tt>).
+      # * Hash - Finds the record that matches these +find+-style conditions
+      #   (such as <tt>{color: 'red'}</tt>).
+      # * +false+ - Returns always +false+.
+      # * No args - Returns +false+ if the table is empty, +true+ otherwise.
+      #
+      # For more information about specifying conditions as a Hash or Array,
+      # see the Conditions section in the introduction to ActiveRecord::Base.
+      def exists?(conditions=nil)
+        # todo: does not yet handle all conditions described above
+        case conditions
+          when Array, Hash
+            pluck :uuid
+            !where(conditions).take.empty?
+          else
+            !!find_one(conditions)
+        end
+      end
+      alias_method :any?, :exists?
+      alias_method :many?, :exists?
+
+      def limit(limit=1)
+        @options[:limit] = limit
+        self
+      end
+
+      def offset(num)
+        @options[:offset] = num
+        self
+      end
+
+      # Removes from the query the condition(s) specified in +skips+.
+      #
+      # Example:
+      #
+      #   Post.order('id asc').except(:order)                  # discards the order condition
+      #   Post.where('id > 10').order('id asc').except(:where) # discards the where condition but keeps the order
+      #
+      def except(*skips)
+        skips.each {|option| @options.delete option}
+      end
+
+      # Removes any condition from the query other than the one(s) specified in +onlies+.
+      #
+      # Example:
+      #
+      #   Post.order('id asc').only(:where)         # discards the order condition
+      #   Post.order('id asc').only(:where, :order) # uses the specified order
+      #
+      def only(*onlies)
+        @options.keys do |k|
+          unless onlines.include? k
+            @options.delete k
+          end
+        end
+      end
+
+      # Allows to specify an order attribute:
+      #
+      #   User.order('name')
+      #   => SELECT "users".* FROM "users" ORDER BY name
+      #
+      #   User.order('name DESC')
+      #   => SELECT "users".* FROM "users" ORDER BY name DESC
+      #
+      #   User.order('name DESC, email')
+      #   => SELECT "users".* FROM "users" ORDER BY name DESC, email
+      def order(*args)
+        @options[:order] << args
+      end
+
+      # Replaces any existing order defined on the relation with the specified order.
+      #
+      #   User.order('email DESC').reorder('id ASC') # generated SQL has 'ORDER BY id ASC'
+      #
+      # Subsequent calls to order on the same relation will be appended. For example:
+      #
+      #   User.order('email DESC').reorder('id ASC').order('name ASC')
+      #
+      # generates a query with 'ORDER BY name ASC, id ASC'.
+      def reorder(*args)
+        @options[:order] = args
+      end
+
+      def all
+        @options[:conditions] = nil
+        self
+      end
+
+      # Works in two unique ways.
+      #
+      # First: takes a block so it can be used just like Array#select.
+      #
+      #   Model.all.select { |m| m.field == value }
+      #
+      # This will build an array of objects from the database for the scope,
+      # converting them into an array and iterating through them using Array#select.
+      #
+      # Second: Modifies the SELECT statement for the query so that only certain
+      # fields are retrieved:
+      #
+      #   Model.select(:field)
+      #   # => [#<Model field:value>]
+      #
+      # Although in the above example it looks as though this method returns an
+      # array, it actually returns a relation object and can have other query
+      # methods appended to it, such as the other methods in ActiveRecord::QueryMethods.
+      #
+      # The argument to the method can also be an array of fields.
+      #
+      #   Model.select(:field, :other_field, :and_one_more)
+      #   # => [#<Model field: "value", other_field: "value", and_one_more: "value">]
+      #
+      def select(*fields)
+        if block_given?
+          to_a.select { |*block_args| yield(*block_args) }
+        else
+          raise ArgumentError, 'Call this with at least one field' if fields.empty?
+          clone.select!(*fields)
+        end
+      end
+
+      # Like #select, but modifies relation in place.
+      def select!(*fields)
+        @options[:select] ||= fields.join ','
+        self
+      end
+      alias_method :pluck, :select!
+
+      def reverse_order
+        @options[:reversed] = true
+        self
+      end
+
+      def readonly
+        @options[:readonly] = true
+        self
+      end
+
+      def to_a
+        load
+        @records
+      end
+
+      def as_json(options = nil) #:nodoc:
+        to_a.as_json(options)
+      end
+
+      # Returns size of the results (not size of the stored collection)
+      def size
+        loaded? ? @records.length : count
+      end
+
+      # true if there are no records
+      def empty?
+        return @records.empty? if loaded?
+
+        c = count
+        c.respond_to?(:zero?) ? c.zero? : c.empty?
+      end
+
+      # true if there are any records
+      def any?
+        if block_given?
+          to_a.any? { |*block_args| yield(*block_args) }
+        else
+          !empty?
+        end
+      end
+
+      # true if there is more than one record
+      def many?
+        if block_given?
+          to_a.many? { |*block_args| yield(*block_args) }
+        else
+          limit_value ? to_a.many? : size > 1
+        end
+      end
+
+      # find_all_by_
+      # find_by_
+      # find_first_by_
+      # find_last_by_
+      def method_missing(method_name, *args)
+
+        method = method_name.to_s
+
+        if method.end_with? '!'
+          method.chop!
+          error_on_empty = true
+        end
+
+        if method.start_with? 'find_all_by_'
+          attribs = method.gsub /^find_all_by_/, ''
+        elsif method.start_with? 'find_by_'
+          attribs = method.gsub /^find_by_/, ''
+          limit(1)
+        elsif method.start_with? 'find_first_by_'
+          limit(1)
+          find_first = true
+          attribs = method.gsub /^find_first_by_/, ''
+        elsif method.start_with? 'find_last_by_'
+          limit(1)
+          find_last = true
+          attribs = method.gsub /^find_last_by_/, ''
+        else
+          super
+        end
+
+        attribs = attribs.split '_and_'
+        conditions = {}
+        attribs.each { |attr| conditions[attr] = args.shift }
+
+        where(conditions, *args)
+        load
+        raise RecordNotFound if error_on_empty && @records.empty?
+        return @records.first if limit_value == 1
+        @records
+      end
+
+      # Tries to create a new record with the same scoped attributes
+      # defined in the relation. Returns the initialized object if validation fails.
+      #
+      # Expects arguments in the same format as +Base.create+.
+      #
+      # ==== Examples
+      #   users = User.where(name: 'Oscar')
+      #   users.create # #<User id: 3, name: "oscar", ...>
+      #
+      #   users.create(name: 'fxn')
+      #   users.create # #<User id: 4, name: "fxn", ...>
+      #
+      #   users.create { |user| user.name = 'tenderlove' }
+      #   # #<User id: 5, name: "tenderlove", ...>
+      #
+      #   users.create(name: nil) # validation on name
+      #   # #<User id: nil, name: nil, ...>
+      def create(*args, &block)
+        @model_class.create(*args, &block)
+      end
+
+      # Similar to #create, but calls +create!+ on the base class. Raises
+      # an exception if a validation error occurs.
+      #
+      # Expects arguments in the same format as <tt>Base.create!</tt>.
+      def create!(*args, &block)
+        @model_class.create!(*args, &block)
+      end
+
+      # Tries to load the first record; if it fails, then <tt>create</tt> is called with the same arguments as this method.
+      #
+      # Expects arguments in the same format as +Base.create+.
+      #
+      # ==== Examples
+      #   # Find the first user named Pen�lope or create a new one.
+      #   User.where(:first_name => 'Pen�lope').first_or_create
+      #   # => <User id: 1, first_name: 'Pen�lope', last_name: nil>
+      #
+      #   # Find the first user named Pen�lope or create a new one.
+      #   # We already have one so the existing record will be returned.
+      #   User.where(:first_name => 'Pen�lope').first_or_create
+      #   # => <User id: 1, first_name: 'Pen�lope', last_name: nil>
+      #
+      #   # Find the first user named Scarlett or create a new one with a particular last name.
+      #   User.where(:first_name => 'Scarlett').first_or_create(:last_name => 'Johansson')
+      #   # => <User id: 2, first_name: 'Scarlett', last_name: 'Johansson'>
+      #
+      #   # Find the first user named Scarlett or create a new one with a different last name.
+      #   # We already have one so the existing record will be returned.
+      #   User.where(:first_name => 'Scarlett').first_or_create do |user|
+      #     user.last_name = "O'Hara"
+      #   end
+      #   # => <User id: 2, first_name: 'Scarlett', last_name: 'Johansson'>
+      def first_or_create(attributes={}, &block)
+        result = first
+        unless result
+          attributes = @options[:hash].merge(attributes) if @options[:hash]
+          result = create(attributes, &block)
+        end
+        result
+      end
+
+      # Like <tt>first_or_create</tt> but calls <tt>create!</tt> so an exception is raised if the created record is invalid.
+      #
+      # Expects arguments in the same format as <tt>Base.create!</tt>.
+      def first_or_create!(attributes={}, &block)
+        result = first
+        unless result
+          attributes = @options[:hash].merge(attributes) if @options[:hash]
+          result = create!(attributes, &block)
+        end
+        result
+      end
+
+      # Like <tt>first_or_create</tt> but calls <tt>new</tt> instead of <tt>create</tt>.
+      #
+      # Expects arguments in the same format as <tt>Base.new</tt>.
+      def first_or_initialize(attributes={}, &block)
+        result = first
+        unless result
+          attributes = @options[:hash].merge(attributes) if @options[:hash]
+          result = @model_class.new(attributes, &block)
+        end
+        result
+      end
+
+      # Destroys the records matching +conditions+ by instantiating each
+      # record and calling its +destroy+ method. Each object's callbacks are
+      # executed (including <tt>:dependent</tt> association options and
+      # +before_destroy+/+after_destroy+ Observer methods). Returns the
+      # collection of objects that were destroyed; each will be frozen, to
+      # reflect that no changes should be made (since they can't be
+      # persisted).
+      #
+      # Note: Instantiation, callback execution, and deletion of each
+      # record can be time consuming when you're removing many records at
+      # once. It generates at least one SQL +DELETE+ query per record (or
+      # possibly more, to enforce your callbacks). If you want to delete many
+      # rows quickly, without concern for their associations or callbacks, use
+      # +delete_all+ instead.
+      #
+      # ==== Parameters
+      #
+      # * +conditions+ - A string, array, or hash that specifies which records
+      #   to destroy. If omitted, all records are destroyed. See the
+      #   Conditions section in the introduction to ActiveRecord::Base for
+      #   more information.
+      #
+      # ==== Examples
+      #
+      #   Person.destroy_all("last_login < '2004-04-04'")
+      #   Person.destroy_all(status: "inactive")
+      #   Person.where(:age => 0..18).destroy_all
+      def destroy_all(conditions=nil)
+        if conditions
+          where(conditions).destroy_all
+        else
+          to_a.each {|object| object.destroy}
+          @records
+        end
+      end
+
+      # Destroy an object (or multiple objects) that has the given id. The object is instantiated first,
+      # therefore all callbacks and filters are fired off before the object is deleted. This method is
+      # less efficient than ActiveRecord#delete but allows cleanup methods and other actions to be run.
+      #
+      # This essentially finds the object (or multiple objects) with the given id, creates a new object
+      # from the attributes, and then calls destroy on it.
+      #
+      # ==== Parameters
+      #
+      # * +id+ - Can be either an Integer or an Array of Integers.
+      #
+      # ==== Examples
+      #
+      #   # Destroy a single object
+      #   Foo.destroy(1)
+      #
+      #   # Destroy multiple objects
+      #   foos = [1,2,3]
+      #   Foo.destroy(foos)
+      def destroy(id)
+        if id.is_a?(Array)
+          id.map {|one_id| destroy(one_id)}
+        else
+          find(id).destroy
+        end
+      end
+
+      # Deletes the records matching +conditions+ without instantiating the records
+      # first, and hence not calling the +destroy+ method nor invoking callbacks. This
+      # is a single SQL DELETE statement that goes straight to the database, much more
+      # efficient than +destroy_all+. Be careful with relations though, in particular
+      # <tt>:dependent</tt> rules defined on associations are not honored. Returns the
+      # number of rows affected.
+      #
+      #   Post.delete_all("person_id = 5 AND (category = 'Something' OR category = 'Else')")
+      #   Post.delete_all(["person_id = ? AND (category = ? OR category = ?)", 5, 'Something', 'Else'])
+      #   Post.where(:person_id => 5).where(:category => ['Something', 'Else']).delete_all
+      #
+      # Both calls delete the affected posts all at once with a single DELETE statement.
+      # If you need to destroy dependent associations or call your <tt>before_*</tt> or
+      # +after_destroy+ callbacks, use the +destroy_all+ method instead.
+      #
+      # If a limit scope is supplied, +delete_all+ raises an ActiveRecord error:
+      #
+      #   Post.limit(100).delete_all
+      #   # => ActiveRecord::ActiveRecordError: delete_all doesn't support limit scope
+      def delete_all(conditions=nil)
+        raise ActiveRecordError.new("delete_all doesn't support limit scope") if self.limit_value
+
+        if conditions
+          where(conditions).delete_all
+        else
+          pluck :uuid
+          response = load
+          response.each {|entity| entity.delete} # todo: can this be optimized into one call?
+          response.size
+        end
+      end
+
+      # Deletes the row with a primary key matching the +id+ argument, using a
+      # SQL +DELETE+ statement, and returns the number of rows deleted. Active
+      # Record objects are not instantiated, so the object's callbacks are not
+      # executed, including any <tt>:dependent</tt> association options or
+      # Observer methods.
+      #
+      # You can delete multiple rows at once by passing an Array of <tt>id</tt>s.
+      #
+      # Note: Although it is often much faster than the alternative,
+      # <tt>#destroy</tt>, skipping callbacks might bypass business logic in
+      # your application that ensures referential integrity or performs other
+      # essential jobs.
+      #
+      # ==== Examples
+      #
+      #   # Delete a single row
+      #   Foo.delete(1)
+      #
+      #   # Delete multiple rows
+      #   Foo.delete([2,3,4])
+      def delete(id_or_array)
+        if id_or_array.is_a? Array
+          id_or_array.each {|id| @model_class.resource[id].delete} # todo: can this be optimized into one call?
+        else
+          @model_class.resource[id_or_array].delete
+        end
+      end
+
+      # Updates all records with details given if they match a set of conditions supplied, limits and order can
+      # also be supplied. This method sends a single update straight to the database. It does not instantiate
+      # the involved models and it does not trigger Active Record callbacks or validations.
+      #
+      # ==== Parameters
+      #
+      # * +updates+ - hash of attribute updates
+      #
+      # ==== Examples
+      #
+      #   # Update all customers with the given attributes
+      #   Customer.update_all wants_email: true
+      #
+      #   # Update all books with 'Rails' in their title
+      #   Book.where('title LIKE ?', '%Rails%').update_all(author: 'David')
+      #
+      #   # Update all books that match conditions, but limit it to 5 ordered by date
+      #   Book.where('title LIKE ?', '%Rails%').order(:created).limit(5).update_all(:author => 'David')
+      def update_all(updates)
+        raise ArgumentError, "Empty list of attributes to change" if updates.blank?
+        raise ArgumentError, "updates must be a Hash" unless updates.is_a? Hash
+        run_update(updates)
+      end
+
+      # Looping through a collection of records from the database
+      # (using the +all+ method, for example) is very inefficient
+      # since it will try to instantiate all the objects at once.
+      #
+      # In that case, batch processing methods allow you to work
+      # with the records in batches, thereby greatly reducing memory consumption.
+      #
+      # The #find_each method uses #find_in_batches with a batch size of 1000 (or as
+      # specified by the +:batch_size+ option).
+      #
+      #   Person.all.find_each do |person|
+      #     person.do_awesome_stuff
+      #   end
+      #
+      #   Person.where("age > 21").find_each do |person|
+      #     person.party_all_night!
+      #   end
+      #
+      #  You can also pass the +:start+ option to specify
+      #  an offset to control the starting point.
+      def find_each(options = {})
+        find_in_batches(options) do |records|
+          records.each { |record| yield record }
+        end
+      end
+
+      # Yields each batch of records that was found by the find +options+ as
+      # an array. The size of each batch is set by the +:batch_size+
+      # option; the default is 1000.
+      #
+      # You can control the starting point for the batch processing by
+      # supplying the +:start+ option. This is especially useful if you
+      # want multiple workers dealing with the same processing queue. You can
+      # make worker 1 handle all the records between id 0 and 10,000 and
+      # worker 2 handle from 10,000 and beyond (by setting the +:start+
+      # option on that worker).
+      #
+      # It's not possible to set the order. That is automatically set to
+      # ascending on the primary key ("id ASC") to make the batch ordering
+      # work. This also mean that this method only works with integer-based
+      # primary keys. You can't set the limit either, that's used to control
+      # the batch sizes.
+      #
+      #   Person.where("age > 21").find_in_batches do |group|
+      #     sleep(50) # Make sure it doesn't get too crowded in there!
+      #     group.each { |person| person.party_all_night! }
+      #   end
+      #
+      #   # Let's process the next 2000 records
+      #   Person.all.find_in_batches(start: 2000, batch_size: 2000) do |group|
+      #     group.each { |person| person.party_all_night! }
+      #   end
+      def find_in_batches(options={})
+        options.assert_valid_keys(:start, :batch_size)
+
+        raise "Not yet implemented" # todo
+
+        start = options.delete(:start) || 0
+        batch_size = options.delete(:batch_size) || 1000
+
+        while records.any?
+          records_size = records.size
+          primary_key_offset = records.last.id
+
+          yield records
+
+          break if records_size < batch_size
+
+          if primary_key_offset
+            records = relation.where(table[primary_key].gt(primary_key_offset)).to_a
+          else
+            raise "Primary key not included in the custom select clause"
+          end
+        end
+      end
+
+      # Updates an object (or multiple objects) and saves it to the database, if validations pass.
+      # The resulting object is returned whether the object was saved successfully to the database or not.
+      #
+      # ==== Parameters
+      #
+      # * +id+ - This should be the id or an array of ids to be updated.
+      # * +attributes+ - This should be a hash of attributes or an array of hashes.
+      #
+      # ==== Examples
+      #
+      #   # Updates one record
+      #   Person.update(15, user_name: 'Samuel', group: 'expert')
+      #
+      #   # Updates multiple records
+      #   people = { 1 => { "first_name" => "David" }, 2 => { "first_name" => "Jeremy" } }
+      #   Person.update(people.keys, people.values)
+      def update(id, attributes)
+        if id.is_a?(Array)
+          id.map.with_index { |one_id, idx| update(one_id, attributes[idx]) }
+        else
+          object = find(id)
+          object.update_attributes(attributes)
+          object
+        end
+      end
+
+      ## todo: scoping
+      ## Scope all queries to the current scope.
+      ##
+      ##   Comment.where(:post_id => 1).scoping do
+      ##     Comment.first # SELECT * FROM comments WHERE post_id = 1
+      ##   end
+      ##
+      ## Please check unscoped if you want to remove all previous scopes (including
+      ## the default_scope) during the execution of a block.
+      #def scoping
+      #  previous, @model_class.current_scope = @model_class.current_scope, self
+      #  yield
+      #ensure
+      #  klass.current_scope = previous
+      #end
+
+
+      # #where accepts conditions in one of several formats.
+      #
+      # === string
+      #
+      # A single string, without additional arguments, is used in the where clause of the query.
+      #
+      #    Client.where("orders_count = '2'")
+      #    # SELECT * where orders_count = '2';
+      #
+      # Note that building your own string from user input may expose your application
+      # to injection attacks if not done properly. As an alternative, it is recommended
+      # to use one of the following methods.
+      #
+      # === array
+      #
+      # If an array is passed, then the first element of the array is treated as a template, and
+      # the remaining elements are inserted into the template to generate the condition.
+      # Active Record takes care of building the query to avoid injection attacks, and will
+      # convert from the ruby type to the database type where needed. Elements are inserted
+      # into the string in the order in which they appear.
+      #
+      #   User.where(["name = ? and email = ?", "Joe", "joe@example.com"])
+      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
+      #
+      # Alternatively, you can use named placeholders in the template, and pass a hash as the
+      # second element of the array. The names in the template are replaced with the corresponding
+      # values from the hash.
+      #
+      #   User.where(["name = :name and email = :email", { name: "Joe", email: "joe@example.com" }])
+      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
+      #
+      # This can make for more readable code in complex queries.
+      #
+      # Lastly, you can use sprintf-style % escapes in the template. This works slightly differently
+      # than the previous methods; you are responsible for ensuring that the values in the template
+      # are properly quoted. The values are passed to the connector for quoting, but the caller
+      # is responsible for ensuring they are enclosed in quotes in the resulting SQL. After quoting,
+      # the values are inserted using the same escapes as the Ruby core method <tt>Kernel::sprintf</tt>.
+      #
+      #   User.where(["name = '%s' and email = '%s'", "Joe", "joe@example.com"])
+      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
+      #
+      # If #where is called with multiple arguments, these are treated as if they were passed as
+      # the elements of a single array.
+      #
+      #   User.where("name = :name and email = :email", { name: "Joe", email: "joe@example.com" })
+      #   # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com';
+      #
+      # When using strings to specify conditions, you can use any operator available from
+      # the database. While this provides the most flexibility, you can also unintentionally introduce
+      # dependencies on the underlying database. If your code is intended for general consumption,
+      # test with multiple database backends.
+      #
+      # === hash
+      #
+      # #where will also accept a hash condition, in which the keys are fields and the values
+      # are values to be searched for.
+      #
+      # Fields can be symbols or strings. Values can be single values, arrays, or ranges.
+      #
+      #    User.where({ name: "Joe", email: "joe@example.com" })
+      #    # SELECT * WHERE name = 'Joe' AND email = 'joe@example.com'
+      #
+      #    User.where({ name: ["Alice", "Bob"]})
+      #    # SELECT * WHERE name IN ('Alice', 'Bob')
+      #
+      #    User.where({ created_at: (Time.now.midnight - 1.day)..Time.now.midnight })
+      #    # SELECT * WHERE (created_at BETWEEN '2012-06-09 07:00:00.000000' AND '2012-06-10 07:00:00.000000')
+      #
+      # In the case of a belongs_to relationship, an association key can be used
+      # to specify the model if an ActiveRecord object is used as the value.
+      #
+      #    author = Author.find(1)
+      #
+      #    # The following queries will be equivalent:
+      #    Post.where(:author => author)
+      #    Post.where(:author_id => author)
+      #
+      # === empty condition
+      #
+      # If the condition returns true for blank?, then where is a no-op and returns the current relation.
+      #
+      def where(opts, *rest)
+        return self if opts.blank?
+        case opts
+          when Hash
+            @options[:hash] = opts # keep around for first_or_create stuff...
+            opts.each do |k,v|
+              # todo: can we support IN and BETWEEN syntax as documented above?
+              v = "'#{v}'" if v.is_a? String
+              query_conditions << "#{k} = #{v}"
+            end
+          when String
+            query_conditions << opts
+          when Array
+            query = opts.shift.gsub '?', "'%s'"
+            query = query % opts
+            query_conditions << query
+        end
+        self
+      end
+
+
+      protected
+
+
+      def limit_value
+        @options[:limit]
+      end
+
+      def query_conditions
+        @options[:conditions] ||= []
+      end
+
+      def loaded?
+        !!@records
+      end
+
+      def reversed?
+        !!@options[:reversed]
+      end
+
+      def find_one(id_or_name=nil)
+        begin
+          entity = @model_class.resource[id_or_name].query(nil, limit: 1).entity
+          @model_class.model_name.constantize.new(entity.data) if entity
+        rescue RestClient::ResourceNotFound
+          nil
+        end
+      end
+
+      def find_one!(id_or_name=nil)
+        find_one(id_or_name) or raise RecordNotFound
+      end
+
+      # Server-side options:
+      # Xql	       string   Query in the query language
+      # type	     string   Entity type to return
+      # Xreversed   string   Return results in reverse order
+      # connection string   Connection type (e.g., "likes")
+      # start      string   First entity's UUID to return
+      # cursor     string   Encoded representation of the query position for paging
+      # Xlimit      integer  Number of results to return
+      # permission string   Permission type
+      # Xfilter     string   Condition on which to filter
+      def query_options
+        # todo: support more options?
+        options = {}
+        options.merge!({:limit => limit_value.to_json}) if limit_value
+        options.merge!({:skip => @options[:skip].to_json}) if @options[:skip]
+        options.merge!({:reversed => reversed?.to_json}) if reversed?
+        options.merge!({:order => @options[:order]}) if @options[:order]
+        options.merge!({:cursor => @options[:cursor]}) if @options[:cursor]
+        options
+      end
+
+      def create_query
+        select = @options[:select] || '*'
+        where = ('where ' + query_conditions.join(' and ')) unless query_conditions.blank?
+        "select #{select} #{where}"
+      end
+
+      def run_query
+        @model_class.resource.query(create_query, query_options)
+      end
+
+      def run_update(attributes)
+        @model_class.resource.update_query(attributes, create_query, query_options)
+      end
+
+      def load
+        return if loaded?
+        begin
+          @response = run_query
+          if (!@options[:select] or @options[:select] == '*')
+            @records = @response.entities.collect {|r| @model_class.model_name.constantize.new(r.data)}
+          else # handle list
+            selects = @options[:select].split ','
+            @records = @response.entities.collect do |r|
+              data = {}
+              (0..selects.size).each do |i|
+                data[selects[i]] = r[i]
+              end
+              @model_class.model_name.constantize.new(data)
+            end
+          end
+        rescue RestClient::ResourceNotFound
+          @records = []
+        end
+      end
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
new file mode 100644
index 0000000..b7a0804
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/user_context.rb
@@ -0,0 +1,96 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+module Usergrid
+  module Ironhorse
+    module UserContext
+
+      # returns user if logged in, nil otherwise
+      # if session is passed, stores user_id and auth_token in the session
+      # and sets User as current_user
+      def authenticate(username, password, session=nil)
+        application = Usergrid::Application.new Usergrid::Ironhorse::Base.settings[:application_url]
+        begin
+          application.login username, password
+          user = new application.current_user.data
+          if session
+            session[:usergrid_user_id] = user.id
+            session[:usergrid_auth_token] = user.current_auth_token
+            set_thread_context(session)
+            Thread.current[:usergrid_current_user] = user
+          end
+          user
+        rescue
+          Rails.logger.info $!
+          raise $!
+        end
+      end
+
+      # clears auth from session and thread
+      def clear_authentication(session)
+        session[:usergrid_user_id] = nil
+        session[:usergrid_auth_token] = nil
+        clear_thread_context(session)
+      end
+
+      # allows admin actions to be done in a block
+      def as_admin(&block)
+        save_auth_token = Thread.current[:usergrid_auth_token]
+        begin
+          unless Base.settings[:auth_token]
+            resource = RestClient::Resource.new Base.settings[:application_url]
+            response = resource['token'].post grant_type: 'client_credentials', client_id: Base.settings[:client_id], client_secret: Base.settings[:client_secret]
+            Base.settings[:auth_token] = MultiJson.load(response)['access_token']
+          end
+          Thread.current[:usergrid_auth_token] = Base.settings[:auth_token]
+          yield block
+        ensure
+          Thread.current[:usergrid_auth_token] = save_auth_token
+        end
+      end
+
+      # sets auth for current thread
+      def set_thread_context(session)
+        Thread.current[:usergrid_user_id] = session[:usergrid_user_id]
+        Thread.current[:usergrid_auth_token] = session[:usergrid_auth_token]
+        Thread.current[:usergrid_current_user] = nil
+      end
+      alias_method :set_context, :set_thread_context
+
+      # clears auth from current thread
+      def clear_thread_context
+        Thread.current[:usergrid_user_id] = nil
+        Thread.current[:usergrid_auth_token] = nil
+        Thread.current[:usergrid_current_user] = nil
+      end
+      alias_method :clear_context, :clear_thread_context
+
+      # returns the auth token for the current thread
+      def current_auth_token
+        Thread.current[:usergrid_auth_token]
+      end
+
+      # does a find and return
+      def current_user
+        unless Thread.current[:usergrid_current_user]
+          Thread.current[:usergrid_current_user] = find(Thread.current[:usergrid_user_id]) if Thread.current[:usergrid_user_id]
+        end
+        Thread.current[:usergrid_current_user]
+      end
+
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/version.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/version.rb b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/version.rb
new file mode 100644
index 0000000..990b730
--- /dev/null
+++ b/sdks/other/ruby-on-rails/lib/usergrid_ironhorse/version.rb
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+module Usergrid
+  module Ironhorse
+    VERSION = '0.1.2'
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/spec/spec_helper.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/spec/spec_helper.rb b/sdks/other/ruby-on-rails/spec/spec_helper.rb
new file mode 100644
index 0000000..2cee2c2
--- /dev/null
+++ b/sdks/other/ruby-on-rails/spec/spec_helper.rb
@@ -0,0 +1,93 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'simplecov'
+require 'test/unit'
+require 'rspec'
+require 'yaml'
+require 'securerandom'
+require_relative '../lib/usergrid_ironhorse'
+
+ENV["RAILS_ENV"] ||= 'test'
+Dir[Pathname.new(File.dirname(__FILE__)).join("support/**/*.rb")].each { |f| require f }
+
+RSpec.configure do |config|
+  config.mock_with :rspec
+  config.expect_with :stdlib
+  config.expect_with :rspec
+end
+
+LOG = Logger.new(STDOUT)
+RestClient.log=LOG
+
+SimpleCov.at_exit do
+  SimpleCov.result.format!
+  #index = File.join(SimpleCov.coverage_path, 'index.html')
+  #`open #{index}` if File.exists?(index)
+end
+SimpleCov.start
+
+
+SPEC_SETTINGS = YAML::load_file(File.join File.dirname(__FILE__), 'spec_settings.yaml')
+Usergrid::Ironhorse::Base.configure! nil, nil
+
+def login_management
+  management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
+  management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
+  management
+end
+
+# ensure we are correctly setup (management login & organization)
+management = login_management
+
+begin
+  management.create_organization(SPEC_SETTINGS[:organization][:name],
+                                 SPEC_SETTINGS[:organization][:username],
+                                 SPEC_SETTINGS[:organization][:username],
+                                 "#{SPEC_SETTINGS[:organization][:username]}@email.com",
+                                 SPEC_SETTINGS[:organization][:password])
+  LOG.info "created organization with user #{SPEC_SETTINGS[:organization][:username]}@email.com"
+rescue
+  if MultiJson.load($!.response)['error'] == "duplicate_unique_property_exists"
+    LOG.debug "test organization exists"
+  else
+    raise $!
+  end
+end
+
+def create_random_application
+  management = login_management
+  organization = management.organization SPEC_SETTINGS[:organization][:name]
+  app_name = "_test_app_#{SecureRandom.hex}"
+  organization.create_application app_name
+  management.application SPEC_SETTINGS[:organization][:name], app_name
+end
+
+def delete_application(application)
+  management = login_management
+  application.auth_token = management.auth_token
+  application.delete rescue nil  # not implemented on server yet
+end
+
+def create_random_user(application, login=false)
+  random = SecureRandom.hex
+  user_hash = {username: "username_#{random}",
+               password: random,
+               email:    "#{random}@email.com",
+               name:     "#{random} name" }
+  entity = application['users'].post(user_hash).entity
+  application.login user_hash[:username], user_hash[:password] if login
+  entity
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/spec/spec_settings.yaml
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/spec/spec_settings.yaml b/sdks/other/ruby-on-rails/spec/spec_settings.yaml
new file mode 100644
index 0000000..815ba43
--- /dev/null
+++ b/sdks/other/ruby-on-rails/spec/spec_settings.yaml
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+:api_url: http://localhost:8080
+:organization:
+  :name: test-organization
+  :username: test
+  :password: test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/spec/support/active_model_lint.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/spec/support/active_model_lint.rb b/sdks/other/ruby-on-rails/spec/support/active_model_lint.rb
new file mode 100644
index 0000000..267be05
--- /dev/null
+++ b/sdks/other/ruby-on-rails/spec/support/active_model_lint.rb
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+# spec/support/active_model_lint.rb
+# adapted from rspec-rails: http://github.com/rspec/rspec-rails/blob/master/spec/rspec/rails/mocks/mock_model_spec.rb
+
+shared_examples_for "ActiveModel" do
+  include ActiveModel::Lint::Tests
+
+  # to_s is to support ruby-1.9
+  ActiveModel::Lint::Tests.public_instance_methods.map{|m| m.to_s}.grep(/^test/).each do |m|
+    example m.sub('_',' ') do
+      send m
+    end
+  end
+
+  def model
+    subject
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb b/sdks/other/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
new file mode 100644
index 0000000..4aa1da6
--- /dev/null
+++ b/sdks/other/ruby-on-rails/spec/usergrid_ironhorse/base_spec.rb
@@ -0,0 +1,452 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+describe Usergrid::Ironhorse::Base do
+
+  it_should_behave_like 'ActiveModel'
+
+  class User < Usergrid::Ironhorse::Base
+    extend Usergrid::Ironhorse::UserContext
+  end
+
+  before :all do
+    @application = create_random_application
+    Foo.configure!(@application.url, @application.auth_token)
+    @user = create_random_user @application, true
+    @foo = (@application.create_entity 'foos', name: 'foo42', answer: 42).entity
+  end
+
+  after :all do
+    @foo.delete
+    @user.delete
+    #delete_application @application # not supported on server yet
+  end
+
+  class Foo < Usergrid::Ironhorse::Base; end
+  Foo.validates :name, :presence => true
+
+  class Bar < Usergrid::Ironhorse::Base; end
+
+  describe 'subclasses should be able to' do
+
+    it "do tasks as admin when requested" do
+      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
+      organization.logout
+
+      # should fail under current user's context
+      expect {
+        organization.create_application "_test_app_#{SecureRandom.hex}"
+      }.to raise_error RestClient::Unauthorized
+
+      # should succeed under admin context
+      User.as_admin do
+        organization.create_application "_test_app_#{SecureRandom.hex}"
+      end
+    end
+
+    it "do tasks as admin if require_login is false" do
+      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
+      organization.logout
+
+      # should fail under current user's context
+      expect {
+        organization.create_application "_test_app_#{SecureRandom.hex}"
+      }.to raise_error RestClient::Unauthorized
+
+      # should succeed once require_login is false
+      User.settings[:require_login] = false
+      organization.create_application "_test_app_#{SecureRandom.hex}"
+      User.settings[:require_login] = true
+    end
+
+    it 'be created and destroyed' do
+      foo = Foo.create name: 'foo man'
+      foo.persisted?.should be_true
+      foo.name.should eq 'foo man'
+      foo = Foo.find_by_name 'foo man'
+      foo.should_not be_nil
+      foo.destroy.should be_true
+      foo.persisted?.should be_false
+      foo = Foo.find_by_name 'foo man'
+      foo.should be_nil
+    end
+
+    it 'be changed and saved' do
+      foo = Foo.find_by_name @foo.name
+      foo.answer.should eq @foo.answer
+      foo.number = 43
+      foo.changed?.should be_true
+      foo.number.should == 43
+      foo.save!
+      foo = Foo.find_by_name @foo.name
+      foo.number.should == 43
+    end
+
+    it 'be reloaded' do
+      foo = Foo.find @foo.uuid
+      foo.answer = 44
+      foo.changed?.should be_true
+      foo.answer.should == 44
+      foo.reload
+      foo.answer.should == 42
+    end
+
+    it 'be found using find_by_name' do
+      foo = Foo.find_by_name @foo.name
+      foo.uuid.should_not be_nil
+      foo.name.should eq @foo.name
+      foo.should be_a Foo
+      foo.persisted?.should be_true
+    end
+
+    it 'be found using find_by_name!' do
+      foo = Foo.find_by_name! @foo.name
+      foo.uuid.should_not be_nil
+      foo.name.should eq @foo.name
+      foo.should be_a Foo
+      foo.persisted?.should be_true
+    end
+
+    it 'throw a RecordNotFound when find_by_name! misses' do
+      expect { Foo.find_by_name! 'name3' }.to raise_error(ActiveRecord::RecordNotFound)
+    end
+
+    it 'add a validation' do
+      foo = Foo.new
+      foo.valid?.should be_false
+      foo.name = 'joe'
+      foo.valid?.should be_true
+    end
+
+    it 'fail to save an invalid record and save the errors' do
+      foo = Foo.new
+      foo.save.should be_false
+      foo.persisted?.should be_false
+      foo.errors.count.should == 1
+      foo.errors.get(:name).first.should eq "can't be blank"
+    end
+
+    it 'fail to create an invalid record and save the errors' do
+      foo = Foo.create
+      foo.persisted?.should be_false
+      foo.errors.count.should == 1
+      foo.errors.get(:name).first.should eq "can't be blank"
+    end
+
+    it 'fail to save! an invalid record' do
+      expect { Foo.new.save! }.to raise_error(ActiveRecord::RecordNotSaved)
+    end
+
+    it 'fail to create! an invalid record' do
+      expect { Foo.create! }.to raise_error(ActiveRecord::RecordNotSaved)
+    end
+
+    it 'retrieve first' do
+      foo2 = Foo.create! name: 'foo2'
+      foo = Foo.first
+      foo.uuid.should eq @foo.uuid
+      foo2.destroy
+    end
+
+    it 'retrieve last' do
+      foo2 = Foo.create! name: 'foo2'
+      foo = Foo.last
+      foo.uuid.should eq foo2.uuid
+      foo2.destroy
+    end
+
+    it 'take multiple' do
+      foo2 = Foo.create! name: 'foo2'
+      foos = Foo.take(2)
+      foos.size.should == 2
+      foos.first.uuid.should_not be_nil
+      foo2.destroy
+    end
+
+    it 'find multiple by id' do
+      foo2 = Foo.create name: 'foo2'
+      foos = Foo.find @foo.uuid, foo2.uuid
+      foos.size.should == 2
+      foos.first.uuid.should eq @foo.uuid
+      foos.last.uuid.should eq foo2.uuid
+      foo2.destroy
+    end
+
+    it 'find multiple by name' do
+      foo2 = Foo.create! name: 'foo2'
+      foos = Foo.find @foo.name, foo2.name
+      foos.size.should == 2
+      foos.first.uuid.should eq @foo.uuid
+      foos.last.uuid.should eq foo2.uuid
+      foo2.destroy
+    end
+
+    it 'check exists?(string)' do
+      Foo.exists?(@foo.name).should be_true
+    end
+
+    it 'check not exists?(string)' do
+      Foo.exists?('asdfasdf').should be_false
+    end
+
+    it 'check exists?(Array)' do
+      Foo.exists?(['name = ?', @foo.name]).should be_true
+    end
+
+    it 'check not exists?(Array)' do
+      Foo.exists?(['name = ?', 'asdfasdf']).should be_false
+    end
+
+    it 'check exists?(Hash)' do
+      Foo.exists?(name: @foo.name).should be_true
+    end
+
+    it 'check not exists?(Hash)' do
+      Foo.exists?(name: 'asfasdf').should be_false
+    end
+
+    it 'check exists?(nil)' do
+      Foo.exists?.should be_true
+    end
+
+    it 'check not exists?(nil)' do
+      Bar.exists?.should be_false
+    end
+
+    it 'perform first_or_create where found' do
+      foo = Foo.where(name: @foo.name).first_or_create
+      foo.uuid.should eq @foo.uuid
+    end
+
+    it 'perform first_or_create where not found' do
+      foo = Foo.where(name: 'foo2').first_or_create(number: 42)
+      foo.name.should eq 'foo2'
+      foo.number.should == 42
+      foo.destroy
+    end
+
+    it 'perform first_or_create! where found' do
+      foo = Foo.where(name: @foo.name).first_or_create!
+      foo.uuid.should eq @foo.uuid
+    end
+
+    it 'perform first_or_create! where not found' do
+      expect { Foo.where(nuumber: 'foo2').first_or_create! }.to raise_error(ActiveRecord::RecordNotSaved)
+    end
+
+    it 'perform first_or_initialize where found' do
+      foo = Foo.where(name: @foo.name).first_or_initialize(xxx: 42)
+      foo.uuid.should eq @foo.uuid
+      foo.xxx.should be_nil
+    end
+
+    it 'perform first_or_initialize where not found' do
+      foo = Foo.where(name: 'foo2').first_or_initialize(number: 42)
+      foo.name.should eq 'foo2'
+      foo.number.should == 42
+      foo.persisted?.should be_false
+    end
+
+    it "should destroy by id" do
+      foo = Foo.create! name: 'foo'
+      Foo.destroy(foo.id)
+      foo = Foo.find_by_name 'foo'
+      foo.should be_nil
+    end
+
+    it "should destroy by ids" do
+      foo = Foo.create! name: 'foo'
+      foo2 = Foo.create! name: 'foo2'
+      Foo.destroy([foo.id, foo2.id])
+      Foo.find_by_name('foo').should be_nil
+      Foo.find_by_name('foo2').should be_nil
+    end
+
+    it "should destroy_all" do
+      foo = Foo.create! name: 'foo', number: 42
+      foo2 = Foo.create! name: 'foo2', number: 42
+      Foo.destroy_all(number: 42)
+      Foo.find_by_name('foo').should be_nil
+      Foo.find_by_name('foo2').should be_nil
+    end
+
+    it "should delete by id" do
+      foo = Foo.create! name: 'foo'
+      Foo.delete(foo.id)
+      foo = Foo.find_by_name 'foo'
+      foo.should be_nil
+    end
+
+    it "should delete by ids" do
+      foo = Foo.create! name: 'foo'
+      foo2 = Foo.create! name: 'foo2'
+      Foo.delete([foo.id, foo2.id])
+      Foo.find_by_name('foo').should be_nil
+      Foo.find_by_name('foo2').should be_nil
+    end
+
+    it "should delete_all" do
+      foo = Foo.create! name: 'foo', number: 42
+      foo2 = Foo.create! name: 'foo2', number: 42
+      Foo.delete_all(number: 42)
+      Foo.find_by_name('foo').should be_nil
+      Foo.find_by_name('foo2').should be_nil
+    end
+
+    it "should update one" do
+      foo = Foo.create! name: 'foo', number: 42
+      Foo.update foo.uuid, { number: 43 }
+      foo.reload.number.should == 43
+      foo.destroy
+    end
+
+    it "should update multiple" do
+      foo = Foo.create! name: 'foo', number: 42
+      foo2 = Foo.create! name: 'foo2', number: 42
+      updates = { foo.uuid => {number: 43}, foo2.uuid => {number: 44}}
+      Foo.update(updates.keys, updates.values)
+      foo.reload.number.should == 43
+      foo2.reload.number.should == 44
+      foo.destroy
+      foo2.destroy
+    end
+
+    it "should update_all" do
+      foo = Foo.create! name: 'foo', number: 43
+      Foo.where(number: 43).update_all({number: 44})
+      Foo.find_by_number(44).should_not be_nil
+      foo.destroy
+    end
+
+    it "should fail on unaccessible mass assignment" do
+      Foo.attr_accessible :name
+      foo = Foo.create! name: 'foo', number: 43
+      foo.number.should_not eq 43
+      foo.update_attributes number: 44, foo: 'bar'
+      foo.number.should_not eq 44
+      foo.destroy
+      Foo._accessible_attributes = nil
+    end
+
+    it "should fail on protected mass assignment" do
+      Foo.attr_protected :number
+      foo = Foo.create! name: 'foo', number: 43
+      foo.number.should_not eq 43
+      foo.update_attributes number: 44, foo: 'bar'
+      foo.number.should_not eq 44
+      foo.destroy
+      Foo._protected_attributes = nil
+    end
+
+    it "should be able to page through results" do
+      bars = (1..15).collect do |i|
+        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
+      end
+      query = Bar.all
+      page = query.to_a # first page
+      page.count.should eq 10
+      page = query.next_page # second page
+      count = 10
+      page.each do |bar|
+        bars[count].name.should eq bar.name
+        count += 1
+      end
+      count.should eq bars.count
+      bars.each {|bar| bar.delete}
+    end
+
+    it "should iterate past page boundaries" do
+      bars = (1..15).collect do |i|
+        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
+      end
+      count = 0
+      Bar.all.each do |bar|
+        bars[count].name.should eq bar.name
+        count += 1
+      end
+      count.should eq bars.count
+      bars.each {|bar| bar.delete}
+    end
+
+    it "should honor limit" do
+      bars = (1..15).collect do |i|
+        Bar.create! name: "name_#{i}", value: "value_#{i+1}"
+      end
+      count = 0
+      Bar.limit(13).each do |bar|
+        bars[count].name.should eq bar.name
+        count += 1
+      end
+      count.should eq 13
+      bars.each {|bar| bar.delete}
+    end
+
+    it "perform as admin only when requested if require_login is true" do
+
+      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
+
+      creds = nil
+      User.as_admin do
+        creds = organization.credentials
+      end
+
+      Usergrid::Ironhorse::Base.settings[:client_id] = creds.data.credentials.client_id
+      Usergrid::Ironhorse::Base.settings[:client_secret] = creds.data.credentials.client_secret
+      Usergrid::Ironhorse::Base.settings[:auth_token] = nil
+      User.clear_thread_context
+      organization.logout
+      User.settings[:require_login] = true
+
+      # should fail (login is required)
+      expect {
+        organization.create_application "_test_app_#{SecureRandom.hex}"
+      }.to raise_error RestClient::Unauthorized
+
+      # should succeed under admin context
+      User.as_admin do
+        organization.create_application "_test_app_#{SecureRandom.hex}"
+      end
+
+      Usergrid::Ironhorse::Base.settings[:client_id] = nil
+      Usergrid::Ironhorse::Base.settings[:client_secret] = nil
+    end
+
+    it "perform as admin if require_login is false" do
+
+      organization = @foo.management.organization SPEC_SETTINGS[:organization][:name]
+      organization.logout
+
+      creds = nil
+      User.as_admin do
+        creds = organization.credentials
+      end
+
+      Usergrid::Ironhorse::Base.settings[:client_id] = creds.data.credentials.client_id
+      Usergrid::Ironhorse::Base.settings[:client_secret] = creds.data.credentials.client_secret
+      Usergrid::Ironhorse::Base.settings[:auth_token] = nil
+      User.clear_thread_context
+      organization.logout
+
+      User.settings[:require_login] = false
+
+      # should succeed
+      organization.create_application "_test_app_#{SecureRandom.hex}"
+
+      Usergrid::Ironhorse::Base.settings[:client_id] = nil
+      Usergrid::Ironhorse::Base.settings[:client_secret] = nil
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby-on-rails/usergrid_ironhorse.gemspec
----------------------------------------------------------------------
diff --git a/sdks/other/ruby-on-rails/usergrid_ironhorse.gemspec b/sdks/other/ruby-on-rails/usergrid_ironhorse.gemspec
new file mode 100644
index 0000000..430c5c1
--- /dev/null
+++ b/sdks/other/ruby-on-rails/usergrid_ironhorse.gemspec
@@ -0,0 +1,44 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# -*- encoding: utf-8 -*-
+lib = File.expand_path('../lib', __FILE__)
+$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
+require 'usergrid_ironhorse/version'
+
+Gem::Specification.new do |gem|
+  gem.name          = "usergrid_ironhorse"
+  gem.version       = Usergrid::Ironhorse::VERSION
+  gem.authors       = ["Scott Ganyo"]
+  gem.email         = ["scott@ganyo.com"]
+  gem.description   = %q{Rails ActiveModel gem to access Usergrid / Apigee App Services}
+  gem.summary       = %q{Usergrid_ironhorse enables simple ActiveModel access to Apigee's App Services
+                        (aka Usergrid) REST API for Rails developers.}
+  gem.homepage      = "https://github.com/scottganyo/usergrid_ironhorse"
+
+  gem.files         = `git ls-files`.split($/)
+  gem.executables   = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
+  gem.test_files    = gem.files.grep(%r{^(test|spec|features)/})
+  gem.require_paths = ["lib"]
+
+  gem.add_dependency 'usergrid_iron', '0.9.1'
+  gem.add_dependency 'activemodel', '~> 3.2'
+  gem.add_dependency 'activerecord', '~> 3.2'
+  gem.add_dependency 'i18n'
+
+  gem.add_development_dependency 'rake'
+  gem.add_development_dependency 'rspec'
+  gem.add_development_dependency 'simplecov'
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/.gitignore b/sdks/other/ruby/.gitignore
new file mode 100644
index 0000000..30b994d
--- /dev/null
+++ b/sdks/other/ruby/.gitignore
@@ -0,0 +1,18 @@
+*.gem
+*.rbc
+.bundle
+.config
+.yardoc
+Gemfile.lock
+InstalledFiles
+_yardoc
+coverage
+doc/
+lib/bundler/man
+pkg
+rdoc
+spec/reports
+test/tmp
+test/version_tmp
+tmp
+.idea
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/.rspec
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/.rspec b/sdks/other/ruby/.rspec
new file mode 100644
index 0000000..c99d2e7
--- /dev/null
+++ b/sdks/other/ruby/.rspec
@@ -0,0 +1 @@
+--require spec_helper

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/.rvmrc
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/.rvmrc b/sdks/other/ruby/.rvmrc
new file mode 100644
index 0000000..55148ad
--- /dev/null
+++ b/sdks/other/ruby/.rvmrc
@@ -0,0 +1,2 @@
+rvm_gemset_create_on_use_flag=1
+rvm gemset use 'usergrid_iron'

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/Gemfile
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/Gemfile b/sdks/other/ruby/Gemfile
new file mode 100644
index 0000000..9a6d84d
--- /dev/null
+++ b/sdks/other/ruby/Gemfile
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+source 'https://rubygems.org'
+
+# Specify your gem's dependencies in usergrid_iron.gemspec
+gemspec

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/LICENSE b/sdks/other/ruby/LICENSE
new file mode 100644
index 0000000..ae1e83e
--- /dev/null
+++ b/sdks/other/ruby/LICENSE
@@ -0,0 +1,14 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/README.md b/sdks/other/ruby/README.md
new file mode 100644
index 0000000..2f6c594
--- /dev/null
+++ b/sdks/other/ruby/README.md
@@ -0,0 +1,268 @@
+# Ruby SDK
+
+Usergrid_iron enables simple, low-level Ruby access to Apigee's App Services (aka Usergrid)
+REST API with minimal dependencies.
+
+## Installation
+
+### Project
+Add the gem to your project's Gemfile:
+
+    gem 'usergrid_iron'
+
+Then rebuild your bundle:
+
+    $ bundle
+
+### Stand-alone script
+Just manually install the gem:
+
+    $ gem install usergrid_iron
+
+
+## Usage
+
+### Prerequisite
+You'll want to be at least a little bit familiar with Usergrid / Apigee's App Services before you jump in here - but it easy and it's great! Start here:
+
+  App Services docs: <http://apigee.com/docs/usergrid/>
+  Open source stack: <https://github.com/apigee/usergrid-stack>
+
+Awesome. Let's go!
+
+### Getting started with the Usergrid_iron SDK is simple!
+
+#### Let's start with the basics.
+For this example, we'll assume you've already set up an organization, application, and user -
+just fill in your own values in the code below.
+
+```ruby
+require 'usergrid_iron'
+
+# fill in your values here!
+usergrid_api = 'http://localhost:8080'
+organization = ''
+application = ''
+username = ''
+password = ''
+
+# create the base application resource
+# (this is a RestClient.resource)
+application = Usergrid::Application.new "#{usergrid_api}/#{organization}/#{application}"
+
+# login (note: not required for sandbox)
+application.login username, password
+
+# create and store a new dog on the server
+# (the "response" is an enhanced RestClient.response)
+response = application.create_dog breed: 'Black Mouth Cur', name: 'Old Yeller'
+
+# the response has returned the entity data
+# response.entity wraps it in an easy-to-use object
+dog = response.entity
+
+# it's persistent now, so it has a unique id
+uuid = dog.uuid
+
+# we can retrieve the dog by UUID using Hash syntax and calling get()
+# (all dogs are stored in the "dogs" collection)
+response = application["dogs"][uuid].get
+same_dog = response.entity
+
+# we could also retrieve the dog by name
+# we could also use path ('/') syntax instead of nested Hash
+# and we can even skip get() - entity() will do it for us
+same_dog = application["dogs/#{dog.name}"].entity
+
+# is it our dog? well, he knows his name!
+# (and we can retrieve its values by dot or Hash)
+puts "My dog's name is: #{same_dog.name} and his breed is #{same_dog['breed']}"
+```
+
+Well that was really easy. More comments than code! :)
+
+#### Let's try something slightly more complex.
+Let's say you've registered for an organization, but you don't have an application yet
+(or want to create a new one to work on). No worries, just fill in your organization and
+superuser credentials below, and follow along!
+(Better yet: If you used the Usergrid launcher and let it initialize your database,
+you shouldn't need to do anything!)
+
+```ruby
+  require 'usergrid_iron'
+
+  usergrid_api = 'http://localhost:8080'
+  org_name = 'test-organization'
+  username = 'test'
+  password = 'test'
+  app_name = 'dog_sitter'
+
+  ## first, let's get that setup out of the way... ##
+
+  # get a management context & login the superuser
+  management = Usergrid::Management.new usergrid_api
+  management.login username, password
+
+  # get the organization context & create a new application
+  organization = management.organization org_name
+  new_application = organization.create_application app_name
+
+  # create an user for our application
+  new_application.create_user username: 'username', password: 'password'
+
+  # login to our new application as our new user
+  application = organization.application app_name
+  application.login 'username', 'password'
+
+
+  ## now we can play with the puppies! ##
+
+  # we can start with our dog again
+  application.create_dog breed: 'Black Mouth Cur', name: 'Old Yeller'
+
+  # but this time let's create several more dogs all at once
+  application.create_dogs [
+      { breed: 'Catalan sheepdog', name: 'Einstein' },
+      { breed: 'Cocker Spaniel', name: 'Lady' },
+      { breed: 'Mixed', name: 'Benji' }]
+
+  # retrieve all the dogs (well, the first 'page' anyway) and tell them hi!
+  # note: we're calling collection() instead of entity() because we have several
+  dogs = application['dogs'].collection
+
+  # you can iterate a collection just like an array
+  dogs.each do |dog|
+    puts "Hello, #{dog.name}!"
+  end
+
+  # Let's get Benji ("Benji, come!"), but this time we'll retrieve by query
+  response = dogs.query "select * where name = 'Benji'"
+
+  # we could call "response.collection.first"
+  # but there's a shortcut: entity() will also return the first
+  benji = response.entity
+
+  # modify Benji's attributes & save to the server
+  benji.location = 'home'                     # use attribute access
+  benji['breed'] = 'American Cocker Spaniel'  # or access attributes like a Hash
+  benji.save
+
+  # now query for the dogs that are home (should just be Benji)
+  dogs = application['dogs'].query("select * where location = 'home'").collection
+  if dogs.size == 1 && dogs.first.location == 'home'
+    puts "Benji's home!"
+  end
+
+```
+
+Whew. That's enough for now. But looking for a specific feature? Check out the [rspecs](http://github.com/scottganyo/usergrid_iron/tree/master/spec/usergrid/core),
+there are examples of nearly everything!
+
+
+## Contributing
+
+We welcome your enhancements!
+
+1. Fork it
+2. Create your feature branch (`git checkout -b my-new-feature`)
+3. Write some broken rspecs.
+4. Fix the rspecs with your new code.
+3. Commit your changes (`git commit -am 'Added some feature'`)
+4. Push your changes to the upstream branch (`git push origin my-new-feature`)
+5. Create new Pull Request
+
+We've got 100% rspec coverage and we're looking to keep it that way!
+In order to run the tests, check out the Usergrid open source project
+(https://github.com/apigee/usergrid-stack), build, and launch it locally.
+
+(Note: If you change your local Usergrid setting from the default, be sure to update
+usergrid_iron/spec/spec_settings.yaml to match.)
+
+
+## Release notes
+
+### 0.9.2
+* New features
+  1. delete_query (batch delete by query)
+
+### 0.9.1
+* New features
+  1. may now login using credentials: application.login_credentials() or organization.login_credentials()
+
+### 0.9.0
+* Backend changes
+  1. login function now uses POST instead of GET
+
+### 0.0.9
+* Backend changes
+  1. made Resource::response accessor public to support ugc
+
+### 0.0.8
+* Bug fixes
+  1. better handling of paging
+
+### 0.0.7
+* Bug fixes
+  1. multiple_entities? should check data['list']
+
+### 0.0.6
+* New features
+  1. iterators can now optionally cross page boundaries, eg. `collection.follow_cursor.each`
+  2. added facebook_login(fb_access_token) method to application
+
+### 0.0.5
+* New features
+  1. added create_* method for application
+* Backend changes
+  1. eliminated serialization of reserved attributes
+* Incompatible changes
+  1. deprecated `Application::create_user username, password, ...`, use `create_user username: 'user', password: 'password'`
+
+### 0.0.4
+* New features
+  1. empty? check for collection
+  2. update queries (batch update)
+* Backend changes
+  1. Additional data sanity checks
+  2. Additional flexibility in concat_urls
+  3. Cleanup
+
+### 0.0.3
+* New features
+  1. Support for lists returned when making parameterized queries:
+	 <pre>select username, email where\u2026</pre>
+	 or replacement queries:
+	 <pre>select { user:username, email:email } where\u2026
+* Incompatible changes
+  1. Application.create_user parameter change from:
+     <pre>create_user(username, name, email, password, invite=false)</pre>
+     to:
+     <pre>create_user(username, password, email=nil, name=nil, invite=false)</pre>
+* Backend changes
+  1. Replaced json_pure dependency with multi_json
+
+
+## Notes
+
+The following features are not currently implemented on the server:
+
+* delete organization
+* delete application
+* delete user
+
+
+## License
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+the ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/Rakefile
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/Rakefile b/sdks/other/ruby/Rakefile
new file mode 100644
index 0000000..bc86b58
--- /dev/null
+++ b/sdks/other/ruby/Rakefile
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+#!/usr/bin/env rake
+require "bundler/gem_tasks"
+
+require 'rspec/core/rake_task'
+RSpec::Core::RakeTask.new(:spec)
+
+RSpec::Core::RakeTask.new("spec:coverage")

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/bin/autospec
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/bin/autospec b/sdks/other/ruby/bin/autospec
new file mode 100755
index 0000000..64dcb9c
--- /dev/null
+++ b/sdks/other/ruby/bin/autospec
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+#
+# This file was generated by Bundler.
+#
+# The application 'autospec' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+require 'pathname'
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
+  Pathname.new(__FILE__).realpath)
+
+require 'rubygems'
+require 'bundler/setup'
+
+load Gem.bin_path('rspec-core', 'autospec')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/bin/htmldiff
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/bin/htmldiff b/sdks/other/ruby/bin/htmldiff
new file mode 100755
index 0000000..c70e238
--- /dev/null
+++ b/sdks/other/ruby/bin/htmldiff
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+#
+# This file was generated by Bundler.
+#
+# The application 'htmldiff' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+require 'pathname'
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
+  Pathname.new(__FILE__).realpath)
+
+require 'rubygems'
+require 'bundler/setup'
+
+load Gem.bin_path('diff-lcs', 'htmldiff')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/bin/ldiff
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/bin/ldiff b/sdks/other/ruby/bin/ldiff
new file mode 100755
index 0000000..8e3524a
--- /dev/null
+++ b/sdks/other/ruby/bin/ldiff
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+#
+# This file was generated by Bundler.
+#
+# The application 'ldiff' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+require 'pathname'
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
+  Pathname.new(__FILE__).realpath)
+
+require 'rubygems'
+require 'bundler/setup'
+
+load Gem.bin_path('diff-lcs', 'ldiff')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/bin/restclient
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/bin/restclient b/sdks/other/ruby/bin/restclient
new file mode 100755
index 0000000..4d7bdcf
--- /dev/null
+++ b/sdks/other/ruby/bin/restclient
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+#
+# This file was generated by Bundler.
+#
+# The application 'restclient' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+require 'pathname'
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
+  Pathname.new(__FILE__).realpath)
+
+require 'rubygems'
+require 'bundler/setup'
+
+load Gem.bin_path('rest-client', 'restclient')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/bin/rspec
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/bin/rspec b/sdks/other/ruby/bin/rspec
new file mode 100755
index 0000000..0c86b5c
--- /dev/null
+++ b/sdks/other/ruby/bin/rspec
@@ -0,0 +1,16 @@
+#!/usr/bin/env ruby
+#
+# This file was generated by Bundler.
+#
+# The application 'rspec' is installed as part of a gem, and
+# this file is here to facilitate running it.
+#
+
+require 'pathname'
+ENV['BUNDLE_GEMFILE'] ||= File.expand_path("../../Gemfile",
+  Pathname.new(__FILE__).realpath)
+
+require 'rubygems'
+require 'bundler/setup'
+
+load Gem.bin_path('rspec-core', 'rspec')

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/application.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/application.rb b/sdks/other/ruby/lib/usergrid/core/application.rb
new file mode 100644
index 0000000..9cc85c4
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/application.rb
@@ -0,0 +1,84 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+module Usergrid
+  class Application < Resource
+
+    def initialize(url, options={})
+      org_name = url.split('/')[-2]
+      api_url = url[0..url.index(org_name)-2]
+      super url, api_url, options
+    end
+
+    # note: collection_name s/b plural, but the server will change it if not
+    def create_entity(collection_name, entity_data)
+      self[collection_name].post entity_data
+    end
+    alias_method :create_entities, :create_entity
+
+    # allow create_something(hash_or_array) method
+    def method_missing(method, *args, &block)
+      method_s = method.to_s
+      if method_s.start_with? 'create_'
+        entity = method_s.split('_')[1]
+        return _create_user *args if entity == 'user' && args[0].is_a?(String) # backwards compatibility
+        create_entity entity, *args
+      elsif method_s.end_with? 's' # shortcut for retrieving collections
+        self[method].query(*args)
+      else
+        super method, args, block
+      end
+    end
+
+    def counter_names
+      self['counters'].get.data.data
+    end
+
+    # other_params: 'start_time' (ms), 'end_time' (ms), 'resolution' (minutes)
+    def counter(name, other_params={})
+      options = other_params.merge({counter: name})
+      self['counters'].get({params: options})
+    end
+
+    # login with Facebook token. matching user will be created in usergrid as needed.
+    # usergrid auth token automatically set in auth header for future requests
+    def facebook_login(access_token)
+      params = { fb_access_token: access_token }
+      response = self['auth/facebook'].get({ params: params })
+      self.auth_token = response.data['access_token']
+      user_uuid = response.data['user']['uuid']
+      @current_user = self["/users/#{user_uuid}"].get.entity
+      response
+    end
+
+    def login_credentials(client_id, client_secret)
+      response = self['token'].post grant_type: 'client_credentials', client_id: client_id, client_secret: client_secret
+      self.auth_token = response.data['access_token']
+    end
+
+    private
+
+    def _create_user(username, password, email=nil, name=nil, invite=false)
+      LOG.warn "create_user(username, password, ...) is deprecated"
+      user_hash = { username: username,
+                    password: password,
+                    email: email,
+                    name: name,
+                    invite: invite }
+      create_entity 'users', user_hash
+    end
+
+  end
+end


[21/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Application.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
new file mode 100644
index 0000000..0054a8c
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
@@ -0,0 +1,979 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'AuthPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
+        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
+        'summary' => 'Get app access token',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthPasswordPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
+        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
+        'summary' => 'Get app access token',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'postField',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthorizeGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
+        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
+        'summary' => 'Authorize app client',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'response_type' => [
+                'description' => 'Response type',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'default' => 'token'
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthorizePost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
+        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
+        'summary' => 'Authorize app client',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'response_type' => [
+                'description' => 'Response type',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'default' => 'token'
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'CredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
+        'notes' => 'Get the app client credentials.',
+        'summary' => 'Get app client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'CredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
+        'notes' => 'Generate new app client credentials',
+        'summary' => 'Generate app client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
+        'notes' => 'Create new app user',
+        'summary' => 'Create new app user.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
+        'notes' => 'Create new app user',
+        'summary' => 'Create new app user using form post parameters.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordRestGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
+        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'summary' => 'Initiate a user password reset',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
+        'notes' => 'Complete a user password reset.  Handles form POST response.',
+        'summary' => 'Complete a user password reset',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'email' => [
+                'description' => 'User Email',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_challenge_field' => [
+                'description' => 'Recaptcha Challenge Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_response_field' => [
+                'description' => 'Recaptcha Response Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'notes' => 'Returns the app user details.',
+        'summary' => 'Returns the app user details',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'notes' => 'Updates the app user details.',
+        'summary' => 'Updates the app user details',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'UserActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate',
+        'notes' => 'Activates the app user from link provided in email notification.',
+        'summary' => 'Activates the app user',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'token' => [
+                'description' => 'Activation Token (supplied via email)',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'confirm' => [
+                'description' => 'Send confirmation email',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate',
+        'notes' => 'Request app user reactivation.',
+        'summary' => 'Reactivates the app user',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed',
+        'notes' => 'Get app user activity feed.',
+        'summary' => 'Get app user activity feed',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password',
+        'notes' => 'Set app user password.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Set app user password',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Old and new password",
+            'location' => 'json'
+        ]
+    ],
+    'UserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
+        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'summary' => 'Initiate a user password reset',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserResetPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
+        'notes' => 'Complete a user password reset.  Handles form POST response.',
+        'summary' => 'Complete a user password reset',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_challenge_field' => [
+                'description' => 'Recaptcha Challenge Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_response_field' => [
+                'description' => 'Recaptcha Response Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'EntityGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'EntityJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'EntityPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update an app entity in a collection.',
+        'summary' => 'Update an app entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'EntityDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete an app entity.',
+        'summary' => 'Delete an app entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'PostEvents' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Event',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+
+
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
new file mode 100644
index 0000000..603d60f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Errors.php
@@ -0,0 +1,53 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+
+return [
+
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\BadRequestException',
+        'code' => 400,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\UnauthorizedException',
+        'code' => 401,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\RequestFailedException',
+        'code' => 402,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\NotFoundException',
+        'code' => 404,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 500,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 502,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 503,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 504,
+    ],
+
+];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Management.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
new file mode 100644
index 0000000..e59154d
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Management.php
@@ -0,0 +1,1076 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'AuthPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/token',
+        'summary' => 'Get management access token',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ]
+        ]
+    ],
+    'AuthorizeGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/authorize',
+        'summary' => 'Authorize the client.  See the OAuth2 specification.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'response_type' => [
+                'description' => 'Response type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'token',
+                'required' => true,
+                'allowableValues' => ['code', 'token']
+            ],
+            'client_id' => [
+                'description' => 'Client ID.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ]
+        ]
+
+    ],
+    'OrgJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs',
+        'summary' => 'Create new organization.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'organization' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization Name'
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}',
+        'summary' => 'Find organization by name or UUID',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/activate',
+        'summary' => 'Activates the organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'confirm' => [
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+                'description' => 'Send confirmation email'
+            ]
+
+        ]
+    ],
+    'OrgReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/reactivate',
+        'summary' => 'Reactivates the organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+        ]
+    ],
+    'OrgFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/feed',
+        'summary' => 'Get organization activity feed',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgCredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
+        'summary' => 'Get organization client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgCredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
+        'summary' => 'Generate organization client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgUsersGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Get admin users for organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgUsersJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Create new admin user for organization using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgUsersFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Create new admin user for organization using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'OrgUserPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'summary' => 'Adds existing admin users for organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin user username, email, or uuid'
+            ]
+        ]
+    ],
+    'OrgUserDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'summary' => 'Remove an admin user from organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin user username, email, or uuid'
+            ]
+        ]
+    ],
+    'OrgAppsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Get apps for organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppsJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Create new application for organization using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application Name'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgAppsFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Create new application for organization using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application Name'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'OrgAppDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}',
+        'summary' => 'Delete an application in an organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppCredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
+        'summary' => 'Get application keys.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppCredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
+        'summary' => 'Generate application keys.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgUserJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users',
+        'summary' => 'Create new admin user.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgUserFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users',
+        'summary' => 'Create new admin using form post parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+
+    ],
+    'OrgUserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/resetpw',
+        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+    ],
+    'OrgUserResetPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/resetpw',
+        'summary' => 'Complete a user password reset.  Handles form POST response.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'recaptcha_challenge_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Challenge Field'
+            ],
+            'recaptcha_response_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Response Field'
+            ],
+        ]
+    ],
+    'AdminUserGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}',
+        'summary' => 'Returns the admin user details',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+        ]
+
+    ],
+    'AdminUserJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}',
+        'summary' => 'Updates the admin user details.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+
+    ],
+    'AdminUserActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/activate',
+        'summary' => 'Activates the admin user from link provided in email notification.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'confirm' => [
+                'location' => 'uri',
+                'type' => 'boolean',
+                'required' => false,
+                'description' => 'Send confirmation email'
+            ],
+        ]
+    ],
+    'AdminUserReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/reactivate',
+        'summary' => 'Request admin user reactivation.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ]
+        ]
+    ],
+    'AdminUserFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/feed',
+        'summary' => 'Get admin user activity feed.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+        ]
+    ],
+    'AdminUserPasswordJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}/password',
+        'summary' => 'Set admin user password.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'old_password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Old and new password'
+            ],
+            'new_password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Old and new password'
+            ],
+        ]
+    ],
+    'AdminUserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
+        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ]
+        ]
+    ],
+    'AdminUserResetPasswordFormPost' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
+        'summary' => 'Complete a user password reset.  Handles form POST response.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'recaptcha_challenge_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Challenge Field'
+            ],
+            'recaptcha_response_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Response Field'
+            ]
+        ]
+    ],
+    'AdminUserOrgsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Get organizations for admin user.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ]
+    ],
+    'AdminUserOrgsJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Create new organization for admin user using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'organization' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'AdminUserOrgsFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Create new organization for admin user using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'organization' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'AdminUserOrgPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
+        'summary' => 'Add admin users to organization.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'AdminUserOrgDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
+        'summary' => 'Remove an admin user from organization.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+
+        ]
+    ]
+
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
new file mode 100644
index 0000000..0a16a62
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Manifest.php
@@ -0,0 +1,25 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'name' => 'Usergrid',
+    'apiVersion' => '1.0.0',
+    // 'baseUrl' => 'http://localhost:8080',
+    'baseUrl' => $baseURL,
+    'description' => 'Client to Usergrid application service',
+    'operations' => []
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
new file mode 100644
index 0000000..0606eb2
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.0/Notification.php
@@ -0,0 +1,154 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+    'ToGroup' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/{group}/notifications',
+        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'group' => [
+                'description' => 'group name',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+
+        ]
+    ],
+    'ToDevice' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/{device_uuid}/notifications',
+        'notes' => 'Create Notification for single Device.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'device_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'device name or uuid'
+            ],
+
+        ]
+    ],
+    'ToDevices' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/*/notifications',
+        'notes' => 'Create Notification all Devices.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'ToUser' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_name}/notifications',
+        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_name' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'User name or uuid'
+            ],
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
new file mode 100644
index 0000000..a51055f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Activities.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [],
+    'find' => [],
+    'create' => [],
+    'destroy' => [],
+    'update' => []
+];
\ No newline at end of file


[22/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Role.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Role.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Role.php
new file mode 100644
index 0000000..3e93465
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Role.php
@@ -0,0 +1,54 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Role
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Role extends BaseCollection implements ResponseClassInterface
+{
+
+    use GuzzleCommandTrait;
+
+    public function usersAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'roles',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'users'
+        ])->toArray();
+    }
+
+    public function groupsAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'roles',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'groups'
+        ])->toArray();
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/User.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/User.php b/sdks/other/php5/apache-usergrid/src/Api/Models/User.php
new file mode 100644
index 0000000..8bec6d3
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/User.php
@@ -0,0 +1,77 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class User
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class User extends BaseCollection implements ResponseClassInterface
+{
+
+    use GuzzleCommandTrait;
+
+    public function deviceAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'users',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'devices'
+        ])->toArray();
+    }
+
+    public function notificationAttribute()
+    {
+
+    }
+
+    public function groupsAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'users',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'groups'
+        ])->toArray();
+    }
+
+    public function rolesAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'users',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'roles'
+        ])->toArray();
+    }
+
+    public function connectionsAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'users',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'connections'
+        ])->toArray();
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/QueryAggregator.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/QueryAggregator.php b/sdks/other/php5/apache-usergrid/src/Api/QueryAggregator.php
new file mode 100644
index 0000000..eacfcd5
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/QueryAggregator.php
@@ -0,0 +1,61 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api;
+
+
+use Guzzle\Http\QueryAggregator\QueryAggregatorInterface;
+use Guzzle\Http\QueryString;
+
+/**
+ * Class QueryAggregator
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class QueryAggregator implements QueryAggregatorInterface
+{
+
+    /**
+     * {@inheritDoc}
+     */
+    public function aggregate($key, $value, QueryString $query)
+    {
+        $response = [];
+
+        foreach ($value as $k => $v) {
+            if (is_int($k)) {
+                return [
+                    $query->encodeValue("{$key}[]") => $value
+                ];
+            }
+
+            $k = "{$key}[{$k}]";
+
+            if (is_array($v)) {
+                $response = array_merge($response, self::aggregate($k, $v, $query));
+            } else {
+                $response[$query->encodeValue($k)] = $query->encodeValue($v);
+            }
+        }
+
+        return $response;
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/ResourceIterator.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/ResourceIterator.php b/sdks/other/php5/apache-usergrid/src/Api/ResourceIterator.php
new file mode 100644
index 0000000..7df0dd7
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/ResourceIterator.php
@@ -0,0 +1,69 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+
+namespace Apache\Usergrid\Api;
+
+use Guzzle\Service\Command\CommandInterface;
+use Guzzle\Service\Resource\ResourceIterator as BaseIterator;
+
+/**
+ * Class ResourceIterator
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ResourceIterator extends BaseIterator
+{
+    /**
+     * {@inheritDoc}
+     */
+    public function __construct(CommandInterface $command, array $data = [])
+    {
+        parent::__construct($command, $data);
+
+        $this->pageSize = 20;
+    }
+
+    /**
+     * Send a request to retrieve the next page of results. Hook for subclasses to implement.
+     *
+     * @return array Returns the newly loaded resources
+     */
+    protected function sendRequest()
+    {
+        $this->command->set('limit', $this->pageSize);
+
+        if ($this->nextToken) {
+            $this->command->set('cursor', $this->nextToken);
+        }
+
+        $result = $this->command->execute();
+
+        $data = $result['entities'];
+
+        if ($result->has('cursor')) {
+            $this->nextToken = $result['cursor'] ? $result['cursor'] : false;
+        }
+
+        return $data;
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Usergrid.php b/sdks/other/php5/apache-usergrid/src/Api/Usergrid.php
new file mode 100644
index 0000000..279f2b2
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Usergrid.php
@@ -0,0 +1,452 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api;
+
+
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
+use Guzzle\Common\Event;
+use Guzzle\Plugin\ErrorResponse\ErrorResponsePlugin;
+use Guzzle\Service\Description\ServiceDescription;
+use InvalidArgumentException;
+
+/**
+ * Class Usergrid
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Usergrid
+{
+
+    /**
+     *  Header Bearer Token
+     * @var
+     */
+    protected $token;
+
+
+    /**
+     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\GrantTypeInterface
+     */
+    protected $grantType;
+    /**
+     * The Usergrid API version.
+     *
+     * @var string
+     */
+    protected $version = '1.0.1';
+    /**
+     * The manifests path.
+     *
+     * @var string
+     */
+    protected $manifestPath;
+    /**
+     * The Base URL.
+     *
+     * @var string
+     */
+    protected $baseUrl;
+    /**
+     * Oauth2 Guzzle Plugin.
+     *
+     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin
+     */
+    protected $oauth2_plugin;
+    /**
+     * The cached manifests data.
+     *
+     * @var array
+     */
+    protected $manifests = [];
+    /**
+     * The user agent.
+     *
+     * @var string
+     */
+    protected $userAgent = 'BaaS-Usergrid/1.0.0';
+    /**
+     * The headers to be sent to the Guzzle client.
+     *
+     * @var array
+     */
+    protected $headers = [];
+    private $org_name;
+    private $app_name;
+
+    /**
+     * @param null $orgName
+     * @param null $appName
+     * @param $manifestPath
+     * @param $version
+     * @param $baseUrl
+     * @param Oauth2Plugin $oauth2_plugin
+     */
+    function __construct(
+        $orgName = null,
+        $appName = null,
+        $manifestPath,
+        $version,
+        $baseUrl,
+        Oauth2Plugin $oauth2_plugin = null
+    ) {
+        //Set Version so its added to header
+        $this->setVersion($version ?: $this->version);
+
+        $this->baseUrl = $baseUrl;
+
+        $this->org_name = $orgName;
+        $this->app_name = $appName;
+
+        //check if OAuth2 plugin is enabled
+        if ($oauth2_plugin != null) {
+            $this->oauth2_plugin = $oauth2_plugin;
+            $this->grantType = $this->oauth2_plugin->getGrantType();
+        }
+
+        // Set the manifest path
+        $this->setManifestPath($manifestPath ?: dirname(dirname(__FILE__)) . '/Manifests');
+    }
+
+    /**
+     * @return mixed
+     */
+    public function getToken()
+    {
+        return $this->token;
+    }
+
+    /**
+     * @param mixed $token
+     * @return $this
+     */
+    public function setToken($token)
+    {
+        $this->token = $token;
+
+        $this->setHeaders([
+            'Authorization' => (string)'Bearer ' . $token,
+        ]);
+
+        return $this;
+    }
+
+    /**
+     * Dynamically handle missing methods.
+     *
+     * @param  string $method
+     * @param  array $arguments
+     * @return mixed
+     */
+    public function __call($method, array $arguments = [])
+    {
+        if (substr($method, -8) === 'Iterator') {
+            return $this->handleIteratorRequest($method, $arguments);
+        } elseif ($this->isSingleRequest($method)) {
+            return $this->handleSingleRequest($method, $arguments);
+        }
+
+        return $this->handleRequest($method);
+    }
+
+    /**
+     * Handles an iterator request.
+     *
+     * @param  string $method
+     * @param  array $arguments
+     * @return \Apache\Usergrid\Api\ResourceIterator
+     * @throws \InvalidArgumentException
+     */
+    protected function handleIteratorRequest($method, array $arguments = [])
+    {
+        $client = $this->handleRequest(substr($method, 0, -8));
+
+        $command = $client->getCommand('all', array_get($arguments, 0, []));
+
+        return new ResourceIterator($command, array_get($arguments, 1, []));
+    }
+
+    /**
+     * Handles the current request.
+     *
+     * @param  string $method
+     * @throws InvalidArgumentException
+     * @return \Guzzle\Service\Client
+     */
+    protected function handleRequest($method)
+    {
+        if (!$this->manifestExists($method)) {
+            throw new InvalidArgumentException("Undefined method [{$method}] called.");
+        }
+
+        // Initialize the Guzzle client
+        $client = new GuzzleClient('',
+            ['command.params' => ['app_name_or_uuid' => $this->app_name, 'org_name_or_uuid' => $this->org_name]]);
+
+        // Set our own usergrid api client for internal
+        // usage within our api models.
+        $client->setApiClient($this);
+
+        // Set the client user agent
+        $client->setUserAgent($this->getUserAgent(), true);
+
+
+        // Set the headers
+        $client->setDefaultOption('headers', $this->getHeaders());
+
+        // Get the Guzzle event dispatcher
+        $dispatcher = $client->getEventDispatcher();
+
+        // Register the error response plugin for our custom exceptions
+        $dispatcher->addSubscriber(new ErrorResponsePlugin);
+
+        // Listen to the "command.after_prepare" event fired by Guzzle
+        $dispatcher->addListener('command.after_prepare', function (Event $event) {
+            $request = $event['command']->getRequest();
+
+            $request->getQuery()->setAggregator(new QueryAggregator());
+        });
+
+        //check if Oauth 2 plugin is a instance of Oauth2Plugin
+        if ($this->oauth2_plugin instanceof Oauth2Plugin) {
+            $dispatcher->addSubscriber($this->oauth2_plugin);
+        }
+
+
+        // Set the manifest payload into the Guzzle client
+        $client->setDescription(ServiceDescription::factory(
+            $this->buildPayload($method)
+        ));
+
+        // Return the Guzzle client
+        return $client;
+    }
+
+    /**
+     * Checks if the manifest file for the current request exists.
+     *
+     * @param  string $file
+     * @return bool
+     */
+    protected function manifestExists($file)
+    {
+        return file_exists($this->getManifestFilePath($file));
+    }
+
+    /**
+     * Returns the given request manifest file path.
+     *
+     * @param  string $file
+     * @return string
+     */
+    protected function getManifestFilePath($file)
+    {
+        return $this->getFullManifestPath() . '/' . ucwords($file) . '.php';
+    }
+
+    /**
+     * Returns the full versioned manifests path.
+     *
+     * @return string
+     */
+    protected function getFullManifestPath()
+    {
+        return $this->getManifestPath() . '/' . $this->getVersion();
+    }
+
+    /**
+     * @return string
+     */
+    public function getManifestPath()
+    {
+        return $this->manifestPath;
+    }
+
+    /**
+     * @param string $manifestPath
+     * @return $this
+     */
+    public function setManifestPath($manifestPath)
+    {
+        $this->manifestPath = $manifestPath;
+        return $this;
+    }
+
+    /**
+     * @return string
+     */
+    public function getVersion()
+    {
+        return $this->version;
+    }
+
+    /**
+     * @param string $version
+     * @return $this
+     */
+    public function setVersion($version)
+    {
+        $this->version = $version;
+
+        $this->setHeaders([
+            'Usergrid-Version' => (string)$version,
+        ]);
+        return $this;
+    }
+
+    /**
+     * @return string
+     */
+    public function getUserAgent()
+    {
+        return $this->userAgent;
+    }
+
+    /**
+     * @param string $userAgent
+     * @return $this
+     */
+    public function setUserAgent($userAgent)
+    {
+        $this->userAgent = $userAgent;
+
+        return $this;
+    }
+
+    /**
+     * Returns the Guzzle client headers.
+     *
+     * @return array
+     */
+    public function getHeaders()
+    {
+        return $this->headers;
+    }
+
+    /**
+     * Sets the Guzzle client headers.
+     *
+     * @param  array $headers
+     * @return $this
+     */
+    public function setHeaders(array $headers = [])
+    {
+        $this->headers = array_merge($this->headers, $headers);
+
+        return $this;
+    }
+
+    /**
+     * Returns the current request payload.
+     *
+     * @param  string $method
+     * @return array
+     */
+    protected function buildPayload($method)
+    {
+        $operations = $this->getRequestManifestPayload($method);
+
+        $manifest = $this->getRequestManifestPayload('manifest', false);
+
+        return array_merge($manifest, compact('operations'));
+    }
+
+    /**
+     * Returns the given file manifest data.
+     *
+     * @param  string $file
+     * @param  bool $includeErrors
+     * @return array
+     */
+    protected function getRequestManifestPayload($file, $includeErrors = true)
+    {
+        $file = ucwords($file);
+
+        /** @noinspection PhpUnusedLocalVariableInspection */
+        $baseURL = $this->baseUrl;
+
+        if (!$manifest = array_get($this->manifests, $file)) {
+            if ($includeErrors) {
+                /** @noinspection PhpUnusedLocalVariableInspection */
+                $errors = $this->getRequestManifestPayload('errors', false);
+            }
+
+            /** @noinspection PhpIncludeInspection */
+            $manifest = require_once $this->getManifestFilePath($file);
+
+            array_set($this->manifests, $file, $manifest);
+        }
+
+        return $manifest;
+    }
+
+    /**
+     * Determines if the request is a single request.
+     *
+     * @param $method
+     * @return bool
+     */
+    protected function isSingleRequest($method)
+    {
+        return (str_singular($method) === $method && $this->manifestExists(str_plural($method)));
+    }
+
+    /**
+     * Handles a single request.
+     *
+     * @param  string $method
+     * @param  array $arguments
+     * @return \Guzzle\Service\Client
+     * @throws \InvalidArgumentException
+     */
+    protected function handleSingleRequest($method, array $arguments = [])
+    {
+        // Check if we have any arguments
+        if (empty($arguments)) {
+            throw new InvalidArgumentException('Not enough arguments provided!');
+        }
+
+        // Pluralize the method name
+        $pluralMethod = str_plural($method);
+
+        // Get the request manifest payload data
+        $manifest = $this->getRequestManifestPayload($pluralMethod);
+
+        if (!$parameters = array_get($manifest, 'find')) {
+            throw new InvalidArgumentException("Undefined method [{$method}] called.");;
+        }
+
+        // Get the required parameters for the request
+        $required = array_where(array_get($parameters, 'parameters'), function ($key, $value) {
+            return $value['required'] === true;
+        });
+
+        // Prepare the arguments for the request
+        $arguments = array_combine(
+            array_keys($required),
+            count($required) === 1 ? (array)$arguments[0] : $arguments
+        );
+
+        // Execute the request
+        return $this->handleRequest($pluralMethod)->find($arguments);
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
new file mode 100755
index 0000000..b03d4a7
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
@@ -0,0 +1,77 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+use Guzzle\Common\Collection;
+use Guzzle\Http\ClientInterface;
+
+/**
+ * Authorization code grant type.
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-4.1
+ */
+class AuthorizationCode implements GrantTypeInterface
+{
+    /** @var ClientInterface The token endpoint client */
+    protected $client;
+
+    /** @var Collection Configuration settings */
+    protected $config;
+
+    public function __construct(ClientInterface $client, $config)
+    {
+        $this->client = $client;
+        $this->config = Collection::fromConfig($config, array(
+            'client_secret' => '',
+            'scope' => '',
+            'redirect_uri' => '',
+        ), array(
+            'client_id',
+            'code',
+        ));
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public function getTokenData()
+    {
+        $postBody = array(
+            'grant_type' => 'authorization_code',
+            'code' => $this->config['code'],
+        );
+        if ($this->config['scope']) {
+            $postBody['scope'] = $this->config['scope'];
+        }
+        if ($this->config['redirect_uri']) {
+            $postBody['redirect_uri'] = $this->config['redirect_uri'];
+        }
+        $request = $this->client->post(null, array(), $postBody);
+        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
+        $response = $request->send();
+        $data = $response->json();
+
+        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
+        return array_intersect_key($data, $requiredData);
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
new file mode 100755
index 0000000..729f6a5
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
@@ -0,0 +1,73 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+use Guzzle\Common\Collection;
+use Guzzle\Http\ClientInterface;
+
+/**
+ * Client credentials grant type.
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-4.4
+ */
+class ClientCredentials implements GrantTypeInterface
+{
+    /** @var ClientInterface The token endpoint client */
+    protected $client;
+
+    /** @var Collection Configuration settings */
+    protected $config;
+
+    public function __construct(ClientInterface $client, $config)
+    {
+        $this->client = $client;
+        $this->config = Collection::fromConfig($config, array(
+            'client_secret' => '',
+            'scope' => '',
+        ), array(
+            'client_id',
+        ));
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public function getTokenData()
+    {
+        $postBody = array(
+            'grant_type' => 'client_credentials',
+            'client_id' => $this->config['client_id'],
+            'client_secret' => $this->config['client_secret']
+        );
+        if ($this->config['scope']) {
+            $postBody['scope'] = $this->config['scope'];
+        }
+        $request = $this->client->post(null, array(), $postBody);
+//        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
+        $response = $request->send();
+        $data = $response->json();
+
+        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
+        return array_intersect_key($data, $requiredData);
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
new file mode 100755
index 0000000..99096c0
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
@@ -0,0 +1,41 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+
+/**
+ * Interface GrantTypeInterface
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+interface GrantTypeInterface
+{
+    /**
+     * Get the token data returned by the OAuth2 server.
+     *
+     * @return array An array with the following keys:
+     *               - access_token: The access token.
+     *               - expires_in: The access token lifetime, in seconds.
+     *               - refresh_token: The refresh token, if present.
+     */
+    public function getTokenData();
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
new file mode 100755
index 0000000..f30d593
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
@@ -0,0 +1,62 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+use HWI\Bundle\OAuthBundle\Security\Http\ResourceOwnerMap;
+use Symfony\Component\Security\Core\SecurityContextInterface;
+
+/**
+ * HWIOAuthBundle Aware Refresh token grant type.
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-6
+ */
+class HWIOAuthBundleRefreshToken implements GrantTypeInterface
+{
+    /** @var SecurityContextInterface Symfony2 security component */
+    protected $securityContext;
+
+    /** @var ResourceOwnerMap         HWIOAuthBundle OAuth2 ResourceOwnerMap */
+    protected $resourceOwnerMap;
+
+    public function __construct(ResourceOwnerMap $resourceOwnerMap, SecurityContextInterface $securityContext)
+    {
+        $this->securityContext = $securityContext;
+        $this->resourceOwnerMap = $resourceOwnerMap;
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public function getTokenData($refreshToken = null)
+    {
+        $token = $this->securityContext->getToken();
+        $resourceName = $token->getResourceOwnerName();
+        $resourceOwner = $this->resourceOwnerMap->getResourceOwnerByName($resourceName);
+
+        $data = $resourceOwner->refreshAccessToken($refreshToken);
+        $token->setRawToken($data);
+        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
+
+        return array_intersect_key($data, $requiredData);
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
new file mode 100755
index 0000000..6afc482
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
@@ -0,0 +1,75 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+use Guzzle\Common\Collection;
+use Guzzle\Http\ClientInterface;
+
+/**
+ * Resource owner password credentials grant type.
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-4.3
+ */
+class PasswordCredentials implements GrantTypeInterface
+{
+    /** @var ClientInterface The token endpoint client */
+    protected $client;
+
+    /** @var Collection Configuration settings */
+    protected $config;
+
+    public function __construct(ClientInterface $client, $config)
+    {
+        $this->client = $client;
+        $this->config = Collection::fromConfig($config, array(
+            'client_secret' => '',
+            'scope' => '',
+        ), array(
+            'client_id',
+            'username',
+            'password'
+        ));
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public function getTokenData()
+    {
+        $postBody = array(
+            'grant_type' => 'password',
+            'username' => $this->config['username'],
+            'password' => $this->config['password'],
+        );
+        if ($this->config['scope']) {
+            $postBody['scope'] = $this->config['scope'];
+        }
+        $request = $this->client->post(null, array(), $postBody);
+        //Note: Usergrid it not using Oauth2 to spec so it dose not need a Auth type set no need to client id + secret when using password
+//        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
+        $response = $request->send();
+        $data = $response->json();
+
+        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
+        return array_intersect_key($data, $requiredData);
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
new file mode 100755
index 0000000..149d570
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
@@ -0,0 +1,74 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
+
+use Guzzle\Common\Collection;
+use Guzzle\Http\ClientInterface;
+
+/**
+ * Refresh token grant type.
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749#section-6
+ */
+class RefreshToken implements GrantTypeInterface
+{
+    /** @var ClientInterface The token endpoint client */
+    protected $client;
+
+    /** @var Collection Configuration settings */
+    protected $config;
+
+    public function __construct(ClientInterface $client, $config)
+    {
+        $this->client = $client;
+        $this->config = Collection::fromConfig($config, array(
+            'client_secret' => '',
+            'refresh_token' => '',
+            'scope' => '',
+        ), array(
+            'client_id',
+        ));
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public function getTokenData($refreshToken = null)
+    {
+        $postBody = array(
+            'grant_type' => 'refresh_token',
+            // If no refresh token was provided to the method, use the one
+            // provided to the constructor.
+            'refresh_token' => $refreshToken ?: $this->config['refresh_token'],
+        );
+        if ($this->config['scope']) {
+            $postBody['scope'] = $this->config['scope'];
+        }
+        $request = $this->client->post(null, array(), $postBody);
+        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
+        $response = $request->send();
+        $data = $response->json();
+
+        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
+        return array_intersect_key($data, $requiredData);
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
new file mode 100755
index 0000000..8454309
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
@@ -0,0 +1,212 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Guzzle\Plugin\Oauth2;
+
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\GrantTypeInterface;
+use Guzzle\Common\Event;
+use Guzzle\Http\Exception\BadResponseException;
+use Symfony\Component\EventDispatcher\EventSubscriberInterface;
+
+/**
+ * OAuth2 plugin
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ *
+ * @link http://tools.ietf.org/html/rfc6749
+ */
+class Oauth2Plugin implements EventSubscriberInterface
+{
+
+    /** @var GrantTypeInterface The grant type implementation used to acquire access tokens */
+    protected $grantType;
+
+    /** @var GrantTypeInterface The grant type implementation used to refresh access tokens */
+    protected $refreshTokenGrantType;
+
+    /** @var array An array with the "access_token" and "expires" keys */
+    protected $accessToken;
+
+    /** @var string The refresh token string. * */
+    protected $refreshToken;
+
+    /**
+     * Create a new Oauth2 plugin
+     * @param GrantTypeInterface $grantType
+     * @param GrantTypeInterface $refreshTokenGrantType
+     */
+    public function __construct(GrantTypeInterface $grantType = null, GrantTypeInterface $refreshTokenGrantType = null)
+    {
+        $this->grantType = $grantType;
+        $this->refreshTokenGrantType = $refreshTokenGrantType;
+    }
+
+    /**
+     * {@inheritdoc}
+     */
+    public static function getSubscribedEvents()
+    {
+        return array(
+            'request.before_send' => 'onRequestBeforeSend',
+            'request.error' => 'onRequestError',
+        );
+    }
+
+    /**
+     * Request before-send event handler.
+     *
+     * Adds the Authorization header if an access token was found.
+     *
+     * @param Event $event Event received
+     */
+    public function onRequestBeforeSend(Event $event)
+    {
+        $accessToken = $this->getAccessToken();
+        if ($accessToken) {
+            $event['request']->setHeader('Authorization', 'Bearer ' . $accessToken['access_token']);
+        }
+    }
+
+    /**
+     * Get the access token.
+     *
+     * Handles token expiration for tokens with an "expires" timestamp.
+     * In case no valid token was found, tries to acquire a new one.
+     *
+     * @return array|null
+     */
+    public function getAccessToken()
+    {
+        if (isset($this->accessToken['expires']) && $this->accessToken['expires'] < time()) {
+            // The access token has expired.
+            $this->accessToken = null;
+        }
+        if (!$this->accessToken) {
+            // Try to acquire a new access token from the server.
+            $this->acquireAccessToken();
+        }
+
+        return $this->accessToken;
+    }
+
+    /**
+     * Set the access token.
+     *
+     * @param array|string $accessToken The access token
+     */
+    public function setAccessToken(array $accessToken)
+    {
+        $this->accessToken = $accessToken;
+    }
+
+    /**
+     * Acquire a new access token from the server.
+     *
+     * @return array|null
+     */
+    protected function acquireAccessToken()
+    {
+        if ($this->refreshTokenGrantType && $this->refreshToken) {
+            try {
+                // Get an access token using the stored refresh token.
+                $tokenData = $this->refreshTokenGrantType->getTokenData($this->refreshToken);
+            } catch (BadResponseException $e) {
+                // The refresh token has probably expired.
+                $this->refreshToken = null;
+            }
+        }
+        if ($this->grantType && !isset($tokenData)) {
+            // Get a new access token.
+            $tokenData = $this->grantType->getTokenData();
+        }
+
+        $this->accessToken = null;
+        if (isset($tokenData)) {
+            // Process the returned data. Both expired_in and refresh_token
+            // are optional parameters.
+            $this->accessToken = array(
+                'access_token' => $tokenData['access_token'],
+            );
+            if (isset($tokenData['expires_in'])) {
+                $this->accessToken['expires'] = time() + $tokenData['expires_in'];
+            }
+            if (isset($tokenData['refresh_token'])) {
+                $this->refreshToken = $tokenData['refresh_token'];
+            }
+        }
+
+        return $this->accessToken;
+    }
+
+    /**
+     * Request error event handler.
+     *
+     * Handles unauthorized errors by acquiring a new access token and
+     * retrying the request.
+     *
+     * @param Event $event Event received
+     */
+    public function onRequestError(Event $event)
+    {
+        if ($event['response']->getStatusCode() == 401) {
+            if ($event['request']->getHeader('X-Guzzle-Retry')) {
+                // We already retried once, give up.
+                return;
+            }
+
+            // Acquire a new access token, and retry the request.
+            $newAccessToken = $this->acquireAccessToken();
+            if ($newAccessToken) {
+                $newRequest = clone $event['request'];
+                $newRequest->setHeader('Authorization', 'Bearer ' . $newAccessToken['access_token']);
+                $newRequest->setHeader('X-Guzzle-Retry', '1');
+                $event['response'] = $newRequest->send();
+                $event->stopPropagation();
+            }
+        }
+    }
+
+    /**
+     * Get the refresh token.
+     *
+     * @return string
+     */
+    public function getRefreshToken()
+    {
+        return $this->refreshToken;
+    }
+
+    /**
+     * Set the refresh token.
+     *
+     * @param string $refreshToken The refresh token
+     */
+    public function setRefreshToken($refreshToken)
+    {
+        $this->refreshToken = $refreshToken;
+    }
+
+    /**
+     * @return GrantTypeInterface
+     */
+    public function getGrantType()
+    {
+        return $this->grantType;
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php b/sdks/other/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
new file mode 100644
index 0000000..57807ad
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
@@ -0,0 +1,159 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Laravel;
+
+
+use Apache\Usergrid\Api\Usergrid;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\ClientCredentials;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\PasswordCredentials;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\RefreshToken;
+use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
+use Guzzle\Http\Client;
+use Illuminate\Support\ServiceProvider;
+
+/**
+ * Class ApacheUsergridServiceProvider
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ApacheUsergridServiceProvider extends ServiceProvider
+{
+
+    protected $oauth2Plugin = null;
+
+    /**
+     *
+     */
+    public function boot()
+    {
+        $this->package('apache/usergrid', 'apache/usergrid', __DIR__ . '/..');
+    }
+
+    /**
+     * Register the service provider.
+     *
+     * @return void
+     */
+    public function register()
+    {
+        // register Usergrid
+        $this->registerUsergrid();
+
+    }
+
+    protected function registerUsergrid()
+    {
+
+        $this->app['usergrid'] = $this->app->share(function ($app) {
+
+            /** Note: I had to move this to here from the register function as the below config values would not get set and would be null
+             * unless I has this with the package namespace missing but doing that would mean that it would not find the  enable_oauth2_plugin
+             * value .. This has been driving me crazy as I tried to read the config values from a rout and they would not show up
+             * then I did . Also this would not find the config values if the boot function did not have the package method called with
+             * all 3 args
+             * $enable_oauth2_plugin = $this->app['config']->get('usergrid.enable_oauth2_plugin');
+             *
+             * //check if user managed oauth auth flow
+             * if($enable_oauth2_plugin){
+             * // Create the Oauth2 Guzzle Plugin.
+             * $this->createGuzzleOauth2Plugin();
+             * }
+             */
+            $enable_oauth2_plugin = $app['config']->get('apache/usergrid::usergrid.enable_oauth2_plugin');
+
+            //check if user managed oauth auth flow
+            if ($enable_oauth2_plugin) {
+                // Create the Oauth2 Guzzle Plugin.
+                $this->createGuzzleOauth2Plugin();
+            }
+
+            $baseUrl = $app['config']->get('apache/usergrid::usergrid.url');
+
+            $orgName = $app['config']->get('apache/usergrid::usergrid.orgName');
+
+            $appName = $app['config']->get('apache/usergrid::usergrid.appName');
+
+            $manifestPath = $app['config']->get('apache/usergrid::usergrid.manifestPath');
+
+            $version = $app['config']->get('apache/usergrid::usergrid.version');
+
+            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl, $this->oauth2Plugin);
+        });
+
+        $this->app->alias('usergrid', 'Apache\Usergrid\Api\Usergrid');
+    }
+
+
+    protected function createGuzzleOauth2Plugin()
+    {
+
+        $base_url = $this->app['config']->get('apache/usergrid::usergrid.url');
+
+        $org_name = $this->app['config']->get('apache/usergrid::usergrid.orgName');
+
+        $app_name = $this->app['config']->get('apache/usergrid::usergrid.appName');
+
+        $grant_type = $this->app['config']->get('apache/usergrid::usergrid.grant_type');
+
+        $client_id = $this->app['config']->get('apache/usergrid::usergrid.clientId');
+
+        $client_secret = $this->app['config']->get('apache/usergrid::usergrid.clientSecret');
+
+        $username = $this->app['config']->get('apache/usergrid::usergrid.username');
+
+        $password = $this->app['config']->get('apache/usergrid::usergrid.password');
+
+
+        if ($this->app['config']->get('apache/usergrid::usergrid.auth_type') == 'organization') {
+
+            $url = $base_url . '/management/token';
+
+        } elseif ($this->app['config']->get('apache/usergrid::usergrid.auth_type') == 'application') {
+            $url = $base_url . '/' . $org_name . '/' . $app_name . '/token';
+        }
+
+        $oauth2Client = new Client($url);
+
+        if ($grant_type == 'client_credentials') {
+            $config = [
+                'client_id' => $client_id,
+                'client_secret' => $client_secret,
+
+            ];
+            $grantType = new ClientCredentials($oauth2Client, $config);
+            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
+            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
+
+        } elseif ($grant_type == 'password') {
+            $config = [
+                'username' => $username,
+                'password' => $password,
+                'client_id' => $client_id,
+                'client_secret' => $client_secret
+            ];
+            $grantType = new PasswordCredentials($oauth2Client, $config);
+            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
+            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
+        }
+
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php b/sdks/other/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
new file mode 100644
index 0000000..1ea29f2
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
@@ -0,0 +1,42 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Laravel\Facades;
+
+
+use Illuminate\Support\Facades\Facade;
+
+/**
+ * Class Usergrid
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Usergrid extends Facade
+{
+    /**
+     * @return string
+     */
+    protected static function getFacadeAccessor()
+    {
+        return "usergrid";
+    }
+
+} 
\ No newline at end of file


[04/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/swagger-json/management.json
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/management.json b/sdks/php5/apache-usergrid/src/Manifests/swagger-json/management.json
deleted file mode 100644
index 8323222..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/management.json
+++ /dev/null
@@ -1,1905 +0,0 @@
-{
-    "basePath": "${basePath}",
-    "swaggerVersion": "1.1-SHAPSHOT.121026",
-    "apiVersion": "0.1",
-    "apis": [
-        {
-            "path": "/management/token",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_auth_password_get",
-                    "summary": "Get management access token",
-                    "notes": "Get the management access token.  See the OAuth2 specification for details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "grant_type",
-                            "dataType": "string",
-                            "description": "Grant type",
-                            "defaultValue": "password",
-                            "allowableValues": {
-                                "values": [
-                                    "password",
-                                    "client_credentials",
-                                    "refresh_token",
-                                    "authorization_code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_secret",
-                            "dataType": "string",
-                            "description": "Client Secret (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_auth_password_post",
-                    "summary": "Get management access token",
-                    "notes": "Get the management access token.  See the OAuth2 specification for details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "grant_type",
-                            "dataType": "string",
-                            "description": "Grant type",
-                            "defaultValue": "password",
-                            "allowableValues": {
-                                "values": [
-                                    "password",
-                                    "client_credentials",
-                                    "refresh_token",
-                                    "authorization_code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password (for grant_type=password)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "client_secret",
-                            "dataType": "string",
-                            "description": "Client Secret (for grant_type=client_credentials)",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/authorize",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_authorize_get",
-                    "summary": "Authorize client",
-                    "notes": "Authorize the client.  See the OAuth2 specification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "response_type",
-                            "dataType": "string",
-                            "description": "Response type",
-                            "defaultValue": "token",
-                            "allowableValues": {
-                                "values": [
-                                    "token",
-                                    "code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "redirect_uri",
-                            "dataType": "string",
-                            "description": "Redirect URI",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "scope",
-                            "dataType": "string",
-                            "description": "Access Token Scope",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "state",
-                            "dataType": "string",
-                            "description": "Client State",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_authorize_post",
-                    "summary": "Authorize client",
-                    "notes": "Authorize the client.  See the OAuth2 specification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "response_type",
-                            "dataType": "string",
-                            "description": "Response type",
-                            "defaultValue": "token",
-                            "allowableValues": {
-                                "values": [
-                                    "token",
-                                    "code"
-                                ],
-                                "valueType": "LIST"
-                            },
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "client_id",
-                            "dataType": "string",
-                            "description": "Client ID",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "redirect_uri",
-                            "dataType": "string",
-                            "description": "Redirect URI",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "scope",
-                            "dataType": "string",
-                            "description": "Access Token Scope",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "state",
-                            "dataType": "string",
-                            "description": "Client State",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Username",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Password",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_json_post",
-                    "summary": "Create new organization",
-                    "notes": "Create new organization.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Organization to post",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_form_post",
-                    "summary": "Create new organization",
-                    "notes": "Create new organization using form post parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "organization",
-                            "dataType": "string",
-                            "description": "Organization",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Admin Username",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "name",
-                            "dataType": "string",
-                            "description": "Admin Name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "Admin Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Admin Password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_get",
-                    "summary": "Find organization by name or UUID",
-                    "notes": "Returns the organization details",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/activate",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_activate_get",
-                    "summary": "Activates the organization",
-                    "notes": "Activates the organization from link provided in email notification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "token",
-                            "dataType": "string",
-                            "description": "Activation Token (supplied via email)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "confirm",
-                            "dataType": "boolean",
-                            "description": "Send confirmation email",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/reactivate",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_reactivate_get",
-                    "summary": "Reactivates the organization",
-                    "notes": "Request organization reactivation.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/feed",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_feed_get",
-                    "summary": "Get organization activity feed",
-                    "notes": "Get organization activity feed.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/credentials",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_credentials_get",
-                    "summary": "Get organization client credentials",
-                    "notes": "Get the organization client credentials.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_credentials_post",
-                    "summary": "Generate organization client credentials",
-                    "notes": "Generate new organization client credentials.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/users",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_users_get",
-                    "summary": "Get admin users for organization",
-                    "notes": "Get admin users for organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_users_json_post",
-                    "summary": "Create new admin user for organization",
-                    "notes": "Create new admin user for organization using JSON payload.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Admin user to create",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_users_form_post",
-                    "summary": "Create new admin user for organization",
-                    "notes": "Create new admin user for organization using form parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Admin Username",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "name",
-                            "dataType": "string",
-                            "description": "Admin Name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "Admin Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Admin Password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "mgt_org_user_put",
-                    "summary": "Add admin users to organization",
-                    "notes": "Adds existing admin users for organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin user username, email, or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "DELETE",
-                    "nickname": "mgt_org_user_delete",
-                    "summary": "Remove admin user from organization",
-                    "notes": "Remove an admin user from organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin user username, email, or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/apps",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_apps_get",
-                    "summary": "Get apps for organization",
-                    "notes": "Get apps for organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_apps_json_post",
-                    "summary": "Create new application for organization",
-                    "notes": "Create new application for organization using JSON payload.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Application to create",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_apps_form_post",
-                    "summary": "Create new application for organization",
-                    "notes": "Create new application for organization using form parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "name",
-                            "dataType": "string",
-                            "description": "Application Name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "DELETE",
-                    "nickname": "mgt_org_app_delete",
-                    "summary": "Delete an application in an organization",
-                    "notes": "Delete an application in an organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Application name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_app_credentials_get",
-                    "summary": "Get application keys",
-                    "notes": "Get application keys.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Application name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_app_credentials_post",
-                    "summary": "Generate application keys",
-                    "notes": "Generate application keys.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "app_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Application name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Application not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_user_json_post",
-                    "summary": "Create new admin user",
-                    "notes": "Create new admin user.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Admin user to post",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_user_form_post",
-                    "summary": "Create new organization",
-                    "notes": "Create new admin using form post parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "username",
-                            "dataType": "string",
-                            "description": "Admin Username",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "name",
-                            "dataType": "string",
-                            "description": "Admin Name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "Admin Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "password",
-                            "dataType": "string",
-                            "description": "Admin Password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/resetpw",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_org_user_reset_password_get",
-                    "summary": "Initiate a user password reset",
-                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_org_user_reset_password_form_post",
-                    "summary": "Complete a user password reset",
-                    "notes": "Complete a user password reset.  Handles form POST response.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "email",
-                            "dataType": "string",
-                            "description": "Admin Email",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_challenge_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Challenge Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_response_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Response Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_get",
-                    "summary": "Returns the admin user details",
-                    "notes": "Returns the admin user details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "mgt_admin_user_json_put",
-                    "summary": "Updates the admin user details",
-                    "notes": "Updates the admin user details.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Admin user details",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/activate",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_activate_get",
-                    "summary": "Activates the admin user",
-                    "notes": "Activates the admin user from link provided in email notification.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "token",
-                            "dataType": "string",
-                            "description": "Activation Token (supplied via email)",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "confirm",
-                            "dataType": "boolean",
-                            "description": "Send confirmation email",
-                            "required": false,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/reactivate",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_reactivate_get",
-                    "summary": "Reactivates the admin user",
-                    "notes": "Request admin user reactivation.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/feed",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_feed_get",
-                    "summary": "Get admin user activity feed",
-                    "notes": "Get admin user activity feed.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/password",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "mgt_admin_user_password_json_put",
-                    "summary": "Set admin user password",
-                    "notes": "Set admin user password.  See Usergrid documentation for JSON format of body.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Old and new password",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/resetpw",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_reset_password_get",
-                    "summary": "Initiate a user password reset",
-                    "notes": "Initiate a user password reset.  Returns browser-viewable HTML page.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_admin_user_reset_password_form_post",
-                    "summary": "Complete a user password reset",
-                    "notes": "Complete a user password reset.  Handles form POST response.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "recaptcha_challenge_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Challenge Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "recaptcha_response_field",
-                            "dataType": "string",
-                            "description": "Recaptcha Response Field",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "Organization not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/orgs",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "GET",
-                    "nickname": "mgt_admin_user_orgs_get",
-                    "summary": "Get organizations for admin user",
-                    "notes": "Get organizations for admin user.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_admin_user_orgs_json_post",
-                    "summary": "Create new organization for admin user",
-                    "notes": "Create new organization for admin user using JSON payload.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "json",
-                            "dataType": "string",
-                            "description": "Organization to create",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "body"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "POST",
-                    "nickname": "mgt_admin_user_orgs_form_post",
-                    "summary": "Create new organization for admin user",
-                    "notes": "Create new organization for admin user using form parameters.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin username, email or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "organization",
-                            "dataType": "string",
-                            "description": "Organization name",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "post"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        },
-        {
-            "path": "/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}",
-            "description": "Management",
-            "operations": [
-                {
-                    "httpMethod": "PUT",
-                    "nickname": "mgt_admin_user_org_put",
-                    "summary": "Add admin user to organization",
-                    "notes": "Add admin users to organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin user username, email, or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                },
-                {
-                    "httpMethod": "DELETE",
-                    "nickname": "mgt_admin_user_org_delete",
-                    "summary": "Remove admin user from organization",
-                    "notes": "Remove an admin user from organization.",
-                    "responseTypeInternal": "",
-                    "responseClass": "response",
-                    "parameters": [
-                        {
-                            "name": "access_token",
-                            "dataType": "string",
-                            "description": "The OAuth2 access token",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "query"
-                        },
-                        {
-                            "name": "user_username_email_or_uuid",
-                            "dataType": "string",
-                            "description": "Admin user username, email, or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        },
-                        {
-                            "name": "org_name_or_uuid",
-                            "dataType": "string",
-                            "description": "Organization name or uuid",
-                            "required": true,
-                            "allowMultiple": false,
-                            "paramType": "path"
-                        }
-                    ],
-                    "errorResponses": [
-                        {
-                            "reason": "Invalid ID supplied",
-                            "code": 400
-                        },
-                        {
-                            "reason": "User not found",
-                            "code": 404
-                        }
-                    ]
-                }
-            ]
-        }
-    ],
-    "models": {
-        "response": {
-            "properties": {
-                "id": {
-                    "type": "long"
-                },
-                "name": {
-                    "type": "string"
-                }
-            },
-            "id": "response"
-        }
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/resources.json b/sdks/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
deleted file mode 100644
index 8a6ffad..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/swagger-json/resources.json
+++ /dev/null
@@ -1,15 +0,0 @@
-{
-    "basePath": "${basePath}",
-    "swaggerVersion": "1.1-SHAPSHOT.121026",
-    "apiVersion": "0.1",
-    "apis": [
-        {
-            "path": "/applications.{format}",
-            "description": "Applications"
-        },
-        {
-            "path": "/management.{format}",
-            "description": "Management"
-        }
-    ]
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Native/ConfigRepository.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Native/ConfigRepository.php b/sdks/php5/apache-usergrid/src/Native/ConfigRepository.php
deleted file mode 100644
index b6febf0..0000000
--- a/sdks/php5/apache-usergrid/src/Native/ConfigRepository.php
+++ /dev/null
@@ -1,102 +0,0 @@
-<?php namespace Apache\Usergrid\Native;
-
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-use ArrayAccess;
-
-/**
- * Class ConfigRepository
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ConfigRepository implements ArrayAccess
-{
-
-    /**
-     * The config file path.
-     *
-     * @var string
-     */
-    protected $file;
-
-    /**
-     * The config data.
-     *
-     * @var array
-     */
-    protected $config = [];
-
-    /**
-     * Constructor.
-     *
-     * @param  string $file
-     * @return \Apache\Usergrid\Native\ConfigRepository
-     */
-    public function __construct($file)
-    {
-        $this->file = $file;
-
-        $this->load();
-    }
-
-    /**
-     * Load the configuration file.
-     *
-     * @return void
-     */
-    protected function load()
-    {
-        $this->config = require $this->file;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public function offsetExists($key)
-    {
-        return isset($this->config[$key]);
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public function offsetGet($key)
-    {
-        return $this->config[$key];
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public function offsetSet($key, $value)
-    {
-        $this->config[$key] = $value;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    public function offsetUnset($key)
-    {
-        unset($this->config[$key]);
-    }
-
-}


[25/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/php/README.md b/sdks/other/php/README.md
new file mode 100644
index 0000000..ec04cc9
--- /dev/null
+++ b/sdks/other/php/README.md
@@ -0,0 +1,388 @@
+##Quickstart
+Detailed instructions follow but if you just want a quick example of how to get started with this SDK, use this minimal PHP file to show you how to include & initialize the SDK, as well as how to read & write data from Usergrid with it.
+
+The file is located in this repository:
+
+	https://github.com/usergrid/usergrid/blob/master/sdks/php/examples/quick_start/index.php
+	
+
+```html
+<?php
+//include autoloader to make sure all files are included
+include '../autoloader.inc.php';
+
+//initialize the SDK
+$client = new Apache\Usergrid\Client('yourorgname','sandbox');
+
+//reading data
+$books = $client->get_collection('books');
+//do something with the data
+while ($books->has_next_entity()) {
+	$book = $books->get_next_entity();
+	$title = $book->get('title');
+	echo "Next Book's title is: " . $title . "<br>";
+}
+
+//writing data
+$data = array('title' => 'the old man and the sea', 'type' => 'books');
+$book = $books->add_entity($data);
+if ($book == FALSE) {
+	echo 'write failed';
+} else {
+	echo 'write succeeded';
+}
+?>
+```
+
+##Version
+
+Current Version: **0.0.1**
+
+See change log:
+
+<https://github.com/usergrid/usergrid/blob/master/sdks/php/changelog.md>
+
+**About this version:**
+
+This is the initial release of this SDK. It is functionally complete with some test coverage.  I plan to add additional test coverage in the near future as well as more examples.  
+
+This SDK is open source, and we welcome any contributions!  
+
+##Comments / Questions
+Please feel free to send comments or questions to the various
+community communication channels
+<http://usergrid.apache.org/community/>
+
+##Overview
+This open source SDK simplifies writing PHP applications that connect to App Services. The repo is located here:
+
+<https://github.com/usergrid/usergrid/tree/master/sdks/php>
+
+You can download the release artfacts via the Apache Mirroring newtwork.
+
+A wealth of Usergrid documentation can be found on the site
+
+<http://usergrid.apache.org/docs/>
+
+
+##About the samples
+This SDK comes with several samples to get you started.  They are located in this repo here:
+
+<https://github.com/usergrid/usergrid/tree/master/sdks/php/examples>
+
+The quick start shows how to get a basic file constructed.  The tests directory has the test code that is used to create this readme file.  **Note:** Ignore the //@han and //@solo comments - they are delimiters for the code parsing app we use to generate the readme.
+
+#Installing
+Download this repo, then add it to the root of your PHP project.
+
+#Getting started
+Once you have the the PHP SDK included in your directory tree, get started by including the SDK:
+
+	 include '../autoloader.inc.php';
+	 usergrid_autoload('Apache\\Usergrid\\Client');
+
+Then, start the client, which is the main object for connecting to the SDK.
+
+	 $client = new Apache\Usergrid\Client('1hotrod','sandbox');
+
+Once you have a client created, you will be able to use it to create Entities and Collections, the building blocks of the Usergrid API.
+
+##Entities
+This sdk provides an easy way to make new entities. Here is a simple example that shows how to create a new object of type "dogs":
+
+	 $data = array('name' => 'Dino', 'type' => 'dog');
+	 $dog = $client->create_entity($data);
+	 if ($dog) {
+	 	//once you have your entity, use the get() method to retrieve properties
+	 	$name = $dog->get('name');
+	 } else {
+	 	//there was an error creating / retrieving the entity
+	 }
+	
+**Note:** The above method will automatically get the entity if it already exists on the server.  
+
+If you only want to **get** an entity from the server: 
+
+	 $data = array('name' => 'Dino', 'type' => 'dog');
+	 $dog = $client->get_entity($data);
+	 if ($dog) {
+	 	$name = $dog->get('name');
+	 } else {
+	 	//entity doesn't exist on the server
+	 }
+	
+**Note:** The above method will return **false** if the entity does not exist, and will **not** automatically create a new entity.
+
+
+You can also refresh the object from the database if needed (in case the data has been updated by a different client or device), by calling the fetch() method:
+
+	 $dog->fetch();
+
+To set properties on the entity, use the set() method:
+
+	 $dog->set('master', 'Fred');
+	 $dog->set('breed', 'dinosaur');
+	 $dog->set('color', 'purple');
+
+These properties are now set locally, but make sure you call the save() method on the entity to save them back to the database!
+
+	 $result = $dog->save();
+	 if (!$result->get_error()) {
+	 	//all is well
+	 } else {
+	 	//there was a problem!
+	 }
+
+To get a single property from the entity, use the get method:
+
+
+
+To remove the entity from the database:
+
+	 $result = $dog->destroy();
+
+
+##The Collection object
+The Collection object models Collections in the database.  Once you start programming your app, you will likely find that this is the most useful method of interacting with the database.  
+
+**Note:** Collections are automatically created when entities are added.  So you can use the get_collection method even if there are no entities in your collection yet!
+
+Getting a collection will automatically populate the object with entities from the collection. The following example shows how to create a Collection object, then how to use entities once the Collection has been populated with entities from the server:
+
+	 $dogs = $client->get_collection('dogs');
+
+
+You can also add a new entity of the same type to the collection:
+
+	 $data = array('name' => 'Dino', 'type' => 'dogs');
+	 $dino = $dogs->add_entity($data);
+
+**Note:** this will also add the entity to the local collection object as well as creating it on the server
+
+
+##Collection iteration and paging
+The Collection object works in Pages of data.  This means that at any given time, the Collection object will have one page of data loaded.  You can iterate across all the entities in the current page of data by using the following pattern:
+
+	 while ($dogs->has_next_entity()) {
+	 	$dog = $dogs->get_next_entity();
+	 	//do something with dog
+	 	$name = $dog->get('name');
+	 }
+
+To iterate over the collection again, you must reset the entity pointer:
+
+	 $dogs->reset_entity_pointer();
+	 while ($dogs->has_next_entity()) {
+	 	$dog = $dogs->get_next_entity();
+	 	//do something with dog
+	 	$name = $dog->get('name');
+	 }
+	
+To get the next page of data:
+
+	 $dogs->get_next_page();
+	 while ($dogs->has_next_entity()) {
+	 	$dog = $dogs->get_next_entity();
+	 	$name = $dog->get('name');
+	 }
+
+You can use the same pattern to get a previous page of data:
+
+	 $dogs->get_prev_page();
+	 while ($dogs->has_next_entity()) {
+	 	$dog = $dogs->get_next_entity();
+	 	$name = $dog->get('name');
+	 }
+
+To get all the subsequent pages of data from the server and iterate across them, use the following pattern:
+
+	 while ($dogs->get_next_page()) {
+	 	while ($dogs->has_next_entity()) {
+	 		$dog = $dogs->get_next_entity();
+	 		$name = $dog->get('name');
+	 	}
+	 }
+
+
+By default, the database will return 10 entities per page.  You can change that amount by setting a limit:
+
+	 $data = array('ql'=>'select * where created > 0', 'limit'=>'40');
+	 $dogs = $client->get_collection('dogs', $data);
+
+Several other convenience methods exist to make working with pages of data easier:
+
+	* get_first_entity - gets the first entity of a page
+	* get_last_entity - gets the last entity of a page
+	* reset_entity_pointer - sets the internal pointer back to the first element of the page
+	* get_entity_by_uuid - returns the entity if it is in the current page
+
+
+
+##Modeling users with the Entity object
+There is no specific User object in this SDK.  Instead, you simply need to use the Entity object, specifying a type of "users".  Here is an example:
+
+	 $marty =  $client->signup('marty', 'mysecurepassword','marty@timetravel.com', 'Marty McFly');
+	 if ($marty) {
+	 	//user created
+	 } else {
+	 	//there was an error
+	 }
+
+If the user is modified, just call save on the user again:
+
+	 $marty->set('state', 'California');
+	 $marty->set('girlfriend', 'Jennifer');
+	 $result = $marty->save();
+
+To refresh the user's information in the database:
+
+
+
+To change the user's password:
+	
+	 $marty->set('oldpassword', 'mysecurepassword');
+	 $marty->set('newpassword', 'mynewsecurepassword');
+	 $marty->save();
+
+To log a user in:
+
+	 if ($client->login('marty', 'mysecurepassword')) {
+	 	//the login call will return an OAuth token, which is saved
+	 	//in the client. Any calls made now will use the token.
+	 	//once a user has logged in, their user object is stored
+	 	//in the client and you can access it this way:
+	 	$token = $client->get_oauth_token();
+	 } else {
+	 }
+
+To log a user out:
+
+	 $client->log_out();
+	 if ($client->is_logged_in()) {
+	 	//error - user is still logged in
+	 } else {
+	 	//success - user was logged out
+	 }
+
+If you no longer need the object, call the destroy() method and the object will be removed from database:
+
+	 $result = $marty->destroy();
+	 if ($result->get_error()) {
+	 	//there was an error deleting the user
+	 } else {
+	 	//success - user was deleted
+	 }
+	
+
+##Making generic calls
+If you find that you need to make calls to the API that fall outside of the scope of the Entity and Collection objects, you can use the following methods to make any of the REST calls (GET, POST, PUT, DELETE).
+
+GET:
+
+	 $endpoint = 'users/fred';
+	 $query_string = array();
+	 $result = $client->get($endpoint, $query_string);
+	 if ($result->get_error()){
+	 	//error - there was a problem getting the entity
+	 } else {
+	 	//success - entity retrieved
+	 }
+
+POST:
+
+	 $endpoint = 'users';
+	 $query_string = array();
+	 $body = array('username'=>'fred');
+	 $result = $client->post($endpoint, $query_string, $body);
+	 if ($result->get_error()){
+	 	//error - there was a problem creating the entity
+	 } else {
+	 	//success - entity created
+	 }
+	
+PUT:
+
+	 $endpoint = 'users/fred';
+	 $query_string = array();
+	 $body = array('dog'=>'dino');
+	 $result = $client->put($endpoint, $query_string, $body);
+	 if ($result->get_error()){
+	 	//error - there was a problem updating the entity
+	 } else {
+	 	//success - entity updated
+	 }
+	
+DELETE:
+
+	 $endpoint = 'users/idontexist';
+	 $query_string = array();
+	 try {
+	 	$result =  $client->delete($endpoint, $query_string);
+	 } catch (Exception $e) {
+	 	//entity didn't exist on the server, so UG_404_NotFound is thrown
+	 }
+	 
+	 ?>
+	 
+	 ?>
+	 $endpoint = 'users/fred';
+	 $query_string = array();
+	 $result =  $client->delete($endpoint, $query_string);
+	 if ($result->get_error()){
+	 	//error - there was a problem deleting the entity
+	 } else {
+	 	//success - entity deleted
+	 }
+
+
+You can make any call to the API using the format above.  However, in practice using the higher level Entity and Collection objects will make life easier as they take care of much of the heavy lifting.
+
+#Authentication
+By default, every App Services account comes with an app called "Sandbox".  While using the Sandbox app for testing, you will not need to worry about authentication as it has all permissions enabled for unauthenticated users.  However, when you are ready to create your own secured app, there are two authentication methods you will use: app user credentials, where your users sign in to get a token, and system level credentials (a client id / client secret combo).
+
+#App user credentials
+To get an Oauth token, users will sign into their accounts with a username and password.  See the "Modeling users with the Entity object" section above for details on how to use the login method.  Once logged in, the user's Oauth token is stored and used for all subsequent calls.
+
+The SDK uses app level credentials by default.
+
+
+#System level credentials (client id / client secret combo)
+If your app needs an elevated level of permissions, then you can use the client id / client secret combo. This is useful if you need to update permissions, do user manipulation, etc. Since the PHP sdk is running server-side, it is safe for you to use the client id / client secret combo on your API calls.  Keep in mind that if you are making API calls on behalf of your application user, say to get resources only they should have access to, such as a feed, it may be more appropriate to use the app user credentials described above.
+
+To use make calls using system level credentials, simply set the auth type and specify your client id and client secret:
+
+	 $testname = 'Use Client Auth type - ';
+	 $client->set_auth_type(AUTH_CLIENT_ID);
+	 $client->set_client_id('YXA6Us6Rg0b0EeKuRALoGsWhew');
+	 $client->set_client_secret('YXA6OYsTy6ENwwnbvjtvsbLpjw5mF40');
+
+
+## Contributing
+We welcome your enhancements!
+
+1. Fork it
+2. Create your feature branch (`git checkout -b my-new-feature`)
+3. Commit your changes (`git commit -am 'Added some feature'`)
+4. Push your changes to the upstream branch (`git push origin my-new-feature`)
+5. Create new Pull Request (make sure you describe what you did and why your mod is needed)
+
+##More information
+For more information on Usergrid, visit <http://usergrid.apache.org>.
+
+## Copyright
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/changelog.md
----------------------------------------------------------------------
diff --git a/sdks/other/php/changelog.md b/sdks/other/php/changelog.md
new file mode 100755
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/autoloader.inc.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/autoloader.inc.php b/sdks/other/php/examples/autoloader.inc.php
new file mode 100755
index 0000000..39f8bc5
--- /dev/null
+++ b/sdks/other/php/examples/autoloader.inc.php
@@ -0,0 +1,36 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+function usergrid_autoload($class) {
+
+
+  if (strpos($class, '\\') !== FALSE) {
+    $path_parts = explode('\\', $class);
+    if ($path_parts[0] == 'Apache') {
+      $lib_path = realpath(dirname(__FILE__) . '/../lib/vendor');
+      $class_path = $lib_path . '/' . join('/', $path_parts) . '.php';
+      if (file_exists($class_path)) {
+        require_once($class_path);
+      }
+    }
+  }
+}
+
+spl_autoload_register('usergrid_autoload');

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/quick_start/index.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/quick_start/index.php b/sdks/other/php/examples/quick_start/index.php
new file mode 100755
index 0000000..95dd861
--- /dev/null
+++ b/sdks/other/php/examples/quick_start/index.php
@@ -0,0 +1,45 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+//include autoloader to make sure all files are included
+include '../autoloader.inc.php';
+usergrid_autoload('Apache\\Usergrid\\Client');
+
+//initialize the SDK
+$client = new Apache\Usergrid\Client('yourorgname','sandbox');
+
+//reading data
+$books = $client->get_collection('books');
+//do something with the data
+while ($books->has_next_entity()) {
+	$book = $books->get_next_entity();
+	$title = $book->get('title');
+	echo "Next Book's title is: " . $title . "<br>";
+}
+
+//writing data
+$data = array('title' => 'the old man and the sea', 'type' => 'books');
+$book = $books->add_entity($data);
+if ($book == FALSE) {
+	echo 'write failed';
+} else {
+	echo 'write succeeded';
+}
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/Tester.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/Tester.php b/sdks/other/php/examples/tests/Tester.php
new file mode 100755
index 0000000..13f7e22
--- /dev/null
+++ b/sdks/other/php/examples/tests/Tester.php
@@ -0,0 +1,80 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Tester - a simple class for logging during a test run
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+class Tester {
+
+  public $error_count = 0;
+	public $success_count = 0;
+
+	//logging
+	public $log_success = true;
+	public $log_error = true;
+	public $log_notice = true;
+
+  public function __construct() {
+
+  }
+
+	//logging functions
+	public function success($message){
+		$this->success_count++;
+		if ($this->log_success) {
+			echo('SUCCESS: ' . $message . '<br>');
+		}
+	}
+
+	public function error($message){
+		$this->error_count++;
+		if ($this->log_error) {
+			echo('ERROR: ' . $message . '<br>');
+		}
+	}
+
+	public function notice($message){
+		if ($this->log_notice) {
+			echo('NOTICE: ' . $message . '<br>');
+		}
+	}
+
+	function printSummary(){
+		echo '<br><br><br>';
+		echo '----------       Summary       ----------- <br>';
+		if ($this->error_count > 0) {
+			echo 'ERROR: BUILD NOT STABLE <br>';
+		} else {
+			echo 'OK: BUILD STABLE <br>';
+		}
+		echo 'Error Count: ' . $this->error_count . ' <br>';
+		echo 'Success Count: ' . $this->success_count . ' <br>';
+		echo '---------- Thanks for playing! ----------- <br>';
+	}
+
+}
+
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/client_auth.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/client_auth.php b/sdks/other/php/examples/tests/client_auth.php
new file mode 100755
index 0000000..17c5b73
--- /dev/null
+++ b/sdks/other/php/examples/tests/client_auth.php
@@ -0,0 +1,101 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * @file
+ * Client Auth tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 01-Apr-2013
+ */
+
+//--------------------------------------------------------------
+// Client Auth
+//--------------------------------------------------------------
+//@han {client-auth}
+$testname = 'Use Client Auth type - ';
+$client->set_auth_type(AUTH_CLIENT_ID);
+$client->set_client_id('YXA6Us6Rg0b0EeKuRALoGsWhew');
+$client->set_client_secret('YXA6OYsTy6ENwwnbvjtvsbLpjw5mF40');
+//@solo
+
+//--------------------------------------------------------------
+// Generic Client Auth Tests
+//--------------------------------------------------------------
+$testname = 'DELETE users/fred';
+
+$endpoint = 'users/fred';
+$query_string = array();
+$result =  $client->delete($endpoint, $query_string);
+$data = $result->get_data();
+if ($data['action'] != 'delete'){
+  //error - there was a problem deleting the entity
+  $tester->error($testname);
+} else {
+  //success - entity deleted
+  $tester->success($testname);
+}
+
+if (!$result->get_error()) {
+  $tester->success($testname);
+} else {
+  $tester->error($testname);
+}
+
+$testname = 'POST users / fred';
+$endpoint = 'users';
+$query_string = array();
+$body = array('username'=>'fred');
+$result = $client->post($endpoint, $query_string, $body);
+$data = $result->get_data();
+if (isset($data['entities'][0]['username']) && $data['entities'][0]['username'] == 'fred'){
+  $tester->success($testname);
+} else {
+  $tester->error($testname);
+}
+
+
+$testname = 'PUT users/fred';
+$endpoint = 'users/fred';
+$query_string = array();
+$body = array('dog'=>'dino');
+$result = $client->put($endpoint, $query_string, $body);
+$data = $result->get_data();
+if (isset($data['entities'][0]['dog']) && $data['entities'][0]['dog'] == 'dino'){
+  $tester->success($testname);
+} else {
+  $tester->error($testname);
+}
+
+$testname = 'GET users/fred';
+$endpoint = 'users/fred';
+$query_string = array();
+$result = $client->get($endpoint, $query_string);
+$data = $result->get_data();
+if (isset($data['path']) && $data['path'] == '/users'){
+  $tester->success($testname);
+} else {
+  $tester->error($testname);
+}
+
+
+$client->set_auth_type(AUTH_APP_USER);
+$client->set_client_id(null);
+$client->set_client_secret(null);
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/collection.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/collection.php b/sdks/other/php/examples/tests/collection.php
new file mode 100755
index 0000000..1c49911
--- /dev/null
+++ b/sdks/other/php/examples/tests/collection.php
@@ -0,0 +1,154 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Collection tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// Collection tests
+//--------------------------------------------------------------
+$testname = 'Create test data - ';
+for($i=0;$i<30;$i++) {
+	$testname = 'Create dog_'.$i;
+	$data = array('name' => 'dog_'.$i, 'type' => 'dogs');
+	$entity = $client->create_entity($data);
+	if ($entity->get('name') == 'dog_'.$i && $entity->get('type') == 'dog'){
+	  $tester->success($testname);
+	} else {
+		$tester->error($testname);
+	}
+}
+
+$testname = 'Get dogs collection';
+//@han {get-collection}
+$dogs = $client->get_collection('dogs');
+//@solo
+//echo '<pre>'.$dogs->get_json().'</pre><br>';
+if ($dogs->get_type() == 'dogs') {
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+//@han {iterate-collection}
+while ($dogs->has_next_entity()) {
+	$dog = $dogs->get_next_entity();
+	//do something with dog
+	$name = $dog->get('name');
+}
+//@solo
+
+//@han {re-iterate-collection}
+$dogs->reset_entity_pointer();
+while ($dogs->has_next_entity()) {
+	$dog = $dogs->get_next_entity();
+	//do something with dog
+	$name = $dog->get('name');
+}
+//@solo
+
+//@han {get-next-page-collection}
+$dogs->get_next_page();
+while ($dogs->has_next_entity()) {
+	$dog = $dogs->get_next_entity();
+	$name = $dog->get('name');
+}
+//@solo
+
+//@han {get-prev-page-collection}
+$dogs->get_prev_page();
+while ($dogs->has_next_entity()) {
+	$dog = $dogs->get_next_entity();
+	$name = $dog->get('name');
+}
+//@solo
+
+
+$testname = 'Get next page of dogs collection';
+$testname2 = 'Verify next page of dogs collection - ';
+//@han {iterate-over-entire-collection}
+while ($dogs->get_next_page()) {
+	$tester->success($testname);
+	while ($dogs->has_next_entity()) {
+		$dog = $dogs->get_next_entity();
+		$name = $dog->get('name');
+		//@solo
+		if ($entity->get('type') == 'dog'){
+			$tester->success($testname2.$name);
+		} else {
+			$tester->error($testname2.$name);
+		}
+		//@han {iterate-over-entire-collection2}
+	}
+}
+//@solo
+
+//@han {get-previous-page-collection}
+while ($dogs->get_prev_page()) {
+	$testname = 'Get next page of dogs collection';
+	$tester->success($testname);
+	$testname = 'Verify next page of dogs collection - ';
+	while ($dogs->has_next_entity()) {
+		$dog = $dogs->get_next_entity();
+		$name = $dog->get('name');
+		if ($entity->get('type') == 'dog'){
+			$tester->success($testname.$name);
+		} else {
+			$tester->error($testname.$name);
+		}
+	}
+}
+
+$testname = 'Add new dog to collection';
+//@han {add-entity-to-collection}
+$data = array('name' => 'Dino', 'type' => 'dogs');
+$dino = $dogs->add_entity($data);
+//@solo
+if ($dino->get('name') == 'Dino') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+//@han {set-limit-collection}
+$data = array('ql'=>'select * where created > 0', 'limit'=>'40');
+$dogs = $client->get_collection('dogs', $data);
+//@solo
+
+$testname = 'Clear dogs sample data - ';
+$dogs->reset_entity_pointer();
+while ($dogs->has_next_entity()) {
+	$dog = $dogs->get_next_entity();
+	$name = $dog->get('name');
+	$result = $dog->destroy();
+	$response_data = $result->get_data();
+	if (isset($response_data['action']) && $response_data['action'] == 'delete') {
+		$tester->success($testname.$name);
+	} else {
+		$tester->error($testname.$name);
+	}
+}
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/entity.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/entity.php b/sdks/other/php/examples/tests/entity.php
new file mode 100755
index 0000000..1f564f2
--- /dev/null
+++ b/sdks/other/php/examples/tests/entity.php
@@ -0,0 +1,114 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Entity tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// Entity tests
+//--------------------------------------------------------------
+$testname = 'Create Entity';
+//@han {create-entity}
+$data = array('name' => 'Dino', 'type' => 'dog');
+$dog = $client->create_entity($data);
+if ($dog) {
+	//once you have your entity, use the get() method to retrieve properties
+	$name = $dog->get('name');
+} else {
+	//there was an error creating / retrieving the entity
+}
+//@solo
+if ($dog->get('name') == 'Dino' && $dog->get('type') == 'dog'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Get Entity';
+//@han {get-entity}
+$data = array('name' => 'Dino', 'type' => 'dog');
+$dog = $client->get_entity($data);
+if ($dog) {
+	$name = $dog->get('name');
+} else {
+	//entity doesn't exist on the server
+}
+//@solo
+if ($name == 'Dino' && $dog->get('type') == 'dog'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+//@han {refresh-entity}
+$dog->fetch();
+//@solo
+
+
+$testname = 'Set key on entity';
+//@han {set-entity}
+$dog->set('master', 'Fred');
+$dog->set('breed', 'dinosaur');
+$dog->set('color', 'purple');
+//@solo
+if ($dog->get('color') == 'purple') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Save key on entity';
+//@han {save-entity}
+$result = $dog->save();
+if (!$result->get_error()) {
+	//all is well
+	$tester->success($testname);
+} else {
+	//there was a problem!
+	$tester->error($testname);
+}
+//@solo
+
+$testname = 'Refresh entity and check key';
+$dog->set('color', 'red'); //set the value
+$result = $dog->fetch(); //refresh to overwrite
+if ($dog->get('color') == 'purple') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Delete entity';
+//@han {destroy-entity}
+$result = $dog->destroy();
+//@solo
+$data = $result->get_data();
+if (isset($data['action']) && $data['action'] == 'delete') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/exceptions.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/exceptions.php b/sdks/other/php/examples/tests/exceptions.php
new file mode 100755
index 0000000..45d44c0
--- /dev/null
+++ b/sdks/other/php/examples/tests/exceptions.php
@@ -0,0 +1,45 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * exceptions tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// Exception Tests - NOT DONE YET!!!
+//--------------------------------------------------------------
+$testname = 'DELETE users/fred';
+//@han {generic-delete}
+$endpoint = 'users/idontexist';
+$query_string = array();
+try {
+	$result =  $client->delete($endpoint, $query_string);
+} catch (Exception $e) {
+	//entity didn't exist on the server, so UG_404_NotFound is thrown
+	$tester->success($testname);
+}
+
+?>
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/generic.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/generic.php b/sdks/other/php/examples/tests/generic.php
new file mode 100755
index 0000000..11ba083
--- /dev/null
+++ b/sdks/other/php/examples/tests/generic.php
@@ -0,0 +1,122 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Generic tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// Generic Tests
+//--------------------------------------------------------------
+$testname = 'DELETE users/fred';
+//@han {generic-delete}
+$endpoint = 'users/fred';
+$query_string = array();
+$result =  $client->delete($endpoint, $query_string);
+if ($result->get_error()){
+	//error - there was a problem deleting the entity
+} else {
+	//success - entity deleted
+}
+//@solo
+$data = $result->get_data();
+if ($data['action'] != 'delete'){
+	//error - there was a problem deleting the entity
+  $tester->error($testname);
+} else {
+	//success - entity deleted
+	$tester->success($testname);
+}
+
+if (!$result->get_error()) {
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'POST users / fred';
+//@han {generic-post}
+$endpoint = 'users';
+$query_string = array();
+$body = array('username'=>'fred');
+$result = $client->post($endpoint, $query_string, $body);
+if ($result->get_error()){
+	//error - there was a problem creating the entity
+  $tester->error($testname);
+} else {
+	//success - entity created
+	$tester->success($testname);
+}
+//@solo
+$data = $result->get_data();
+$json = $result->get_json();
+//echo '<pre>'.$json.'</pre><br>';
+if (isset($data['entities'][0]['username']) && $data['entities'][0]['username'] == 'fred'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+
+$testname = 'PUT users/fred';
+//@han {generic-put}
+$endpoint = 'users/fred';
+$query_string = array();
+$body = array('dog'=>'dino');
+$result = $client->put($endpoint, $query_string, $body);
+if ($result->get_error()){
+	//error - there was a problem updating the entity
+  $tester->error($testname);
+} else {
+	//success - entity updated
+	$tester->success($testname);
+}
+//@solo
+$data = $result->get_data();
+if (isset($data['entities'][0]['dog']) && $data['entities'][0]['dog'] == 'dino'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'GET users/fred';
+//@han {generic-get}
+$endpoint = 'users/fred';
+$query_string = array();
+$result = $client->get($endpoint, $query_string);
+if ($result->get_error()){
+	//error - there was a problem getting the entity
+  $tester->error($testname);
+} else {
+	//success - entity retrieved
+	$tester->success($testname);
+}
+//@solo
+$data = $result->get_data();
+if (isset($data['path']) && $data['path'] == '/users'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/push.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/push.php b/sdks/other/php/examples/tests/push.php
new file mode 100755
index 0000000..5c7e1e0
--- /dev/null
+++ b/sdks/other/php/examples/tests/push.php
@@ -0,0 +1,71 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Push Notification tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// Push tests
+//--------------------------------------------------------------
+$testname = 'Create apple notifier';
+$apple_name = 'name_'.time();
+$environment = 'development';
+$p12Certificate_path = "@pushtest_dev.p12";
+$result =  $client->createNewNotifierApple($apple_name, $environment, $p12Certificate_path);
+echo '<pre>'.$result->get_json().'</pre><br>';
+if ($result->get_error()){
+  $tester->error($testname);
+} else {
+	$tester->success($testname);
+}
+
+$testname = 'Create google notifier';
+$google_name = 'name_'.time();
+$apiKey = 'AIzaSyCIH_7WC0mOqBGMOXyQnFgrBpOePgHvQJM';
+$result =  $client->createNewNotifierAndroid($google_name, $apiKey);
+echo '<pre>'.$result->get_json().'</pre><br>';
+if ($result->get_error()){
+  $tester->error($testname);
+} else {
+	$tester->success($testname);
+}
+
+$testname = 'Create notification';
+$notification = $client->createNotification();
+$notification->set_notifier_name($apple_name);
+$notification->set_message("Test Message");
+$notification->set_delivery_time(time());
+$notification->set_recipients_list(array(0=>'fred'));
+$notification->set_recipient_type(USERS);
+
+$result = $client->scheduleNotification($notification);
+echo '<pre>'.$result->get_json().'</pre><br>';
+if ($result->get_error()){
+  $tester->error($testname);
+} else {
+	$tester->success($testname);
+}
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/pushtest_dev.p12
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/pushtest_dev.p12 b/sdks/other/php/examples/tests/pushtest_dev.p12
new file mode 100644
index 0000000..b4373a2
Binary files /dev/null and b/sdks/other/php/examples/tests/pushtest_dev.p12 differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/test.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/test.php b/sdks/other/php/examples/tests/test.php
new file mode 100755
index 0000000..e0578d2
--- /dev/null
+++ b/sdks/other/php/examples/tests/test.php
@@ -0,0 +1,56 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * main entry point for running tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//@han {include-sdk}
+include '../autoloader.inc.php';
+usergrid_autoload('Apache\\Usergrid\\Client');
+//@solo
+
+//@han {create-new-client}
+$client = new Apache\Usergrid\Client('1hotrod','sandbox');
+//@solo
+
+include 'Tester.php';
+
+$tester = new Tester();
+
+include 'generic.php';
+include 'entity.php';
+include 'collection.php';
+include 'user.php';
+include 'client_auth.php';
+include 'push.php';
+
+
+
+//--------------------------------------------------------------
+// Summary
+//--------------------------------------------------------------
+$tester->printSummary();
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/examples/tests/user.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/examples/tests/user.php b/sdks/other/php/examples/tests/user.php
new file mode 100755
index 0000000..545ba7a
--- /dev/null
+++ b/sdks/other/php/examples/tests/user.php
@@ -0,0 +1,137 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * User tests
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+//--------------------------------------------------------------
+// User tests
+//--------------------------------------------------------------
+$testname = 'DELETE users/marty';
+$endpoint = 'users/marty';
+$query_string = array();
+$result =  $client->delete($endpoint, $query_string);
+$result_data = $result->get_data();
+if (isset($result_data)){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Signup user';
+//@han {create-user}
+$marty =  $client->signup('marty', 'mysecurepassword','marty@timetravel.com', 'Marty McFly');
+if ($marty) {
+	//user created
+} else {
+	//there was an error
+}
+//@solo
+if ($marty->get('username') == 'marty'){
+  $tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Update user';
+//@han {update-user}
+$marty->set('state', 'California');
+$marty->set('girlfriend', 'Jennifer');
+$result = $marty->save();
+//@solo
+if ($result->get_error()) {
+	$tester->error($testname);
+} else {
+	$tester->success($testname);
+}
+
+$testname = 'Log user in';
+//@han {log-user-in}
+if ($client->login('marty', 'mysecurepassword')) {
+	//the login call will return an OAuth token, which is saved
+	//in the client. Any calls made now will use the token.
+	//once a user has logged in, their user object is stored
+	//in the client and you can access it this way:
+	$token = $client->get_oauth_token();
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+//@solo
+
+$testname = 'Get logged in user';
+$marty = $client->get_logged_in_user();
+if (isset($marty) && $marty->get('username') == 'marty') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Update user password';
+//@han {update-user-password}
+$marty->set('oldpassword', 'mysecurepassword');
+$marty->set('newpassword', 'mynewsecurepassword');
+$marty->save();
+//@solo
+$result_data = $result->get_data();
+if (isset($result_data['action']) && $result_data['action'] == 'put') {
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Log user out';
+//@han {log-user-out}
+$client->log_out();
+if ($client->is_logged_in()) {
+	//error - user is still logged in
+	$tester->error($testname);
+} else {
+	//success - user was logged out
+	$tester->success($testname);
+}
+//@solo
+
+$testname = 'Log user in with new password';
+if ($client->login('marty', 'mynewsecurepassword')){
+	$tester->success($testname);
+} else {
+	$tester->error($testname);
+}
+
+$testname = 'Delete user';
+//@han {destroy-user}
+$result = $marty->destroy();
+if ($result->get_error()) {
+	//there was an error deleting the user
+	$tester->error($testname);
+} else {
+	//success - user was deleted
+	$tester->success($testname);
+}
+//@solo
+
+
+?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Client.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Client.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Client.php
new file mode 100755
index 0000000..cd0120d
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Client.php
@@ -0,0 +1,813 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Basic class for accessing Usergrid functionality.
+ *
+ * @author Daniel Johnson <dj...@apigee.com>
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 26-Apr-2013
+ */
+
+namespace Apache\Usergrid;
+
+require_once(dirname(__FILE__) . '/Exceptions.php');
+
+define('AUTH_CLIENT_ID', 'CLIENT_ID');
+define('AUTH_APP_USER', 'APP_USER');
+define('AUTH_NONE', 'NONE');
+
+class Client {
+
+  const SDK_VERSION = '0.1';
+
+  /**
+   * Usergrid endpoint
+   * @var string
+   */
+  private $url = 'http://api.usergrid.com';
+
+  /**
+   * Organization name. Find your in the Admin Portal
+   * @var string
+   */
+  private $org_name;
+
+  /**
+   * App name. Find your in the Admin Portal
+   * @var string
+   */
+  private $app_name;
+
+  /**
+   * @var bool
+   */
+  private $build_curl = FALSE;
+
+  /**
+   * @var bool
+   */
+  private $use_exceptions = FALSE;
+
+  /**
+   * @var Callable
+   */
+  private $log_callback = NULL;
+
+  /**
+   * @var int
+   */
+  private $call_timeout = 30000;
+
+  /**
+   * @var Callable
+   */
+  private $call_timeout_callback = NULL;
+
+  /**
+   * @var Callable
+   */
+  private $logout_callback = NULL;
+
+  /**
+   * @var string
+   */
+  private $oauth_token;
+
+  /**
+   * @var string
+   */
+  private $client_id;
+
+  /**
+   * @var string
+   */
+  private $client_secret;
+
+  /**
+   * @var string
+   */
+  private $auth_type = AUTH_APP_USER;
+
+  /**
+   * Object constructor
+   *
+   * @param string $org_name
+   * @param string $app_name
+   */
+  public function __construct($org_name, $app_name) {
+    $this->org_name = $org_name;
+    $this->app_name = $app_name;
+  }
+
+  /* Accessor functions */
+
+  /**
+   * Returns OAuth token if it has been set; else NULL.
+   *
+   * @return string|NULL
+   */
+  public function get_oauth_token() {
+    return $this->oauth_token;
+  }
+
+  /**
+   * Sets OAuth token.
+   *
+   * @param string $token
+   */
+  public function set_oauth_token($token) {
+    $this->oauth_token = $token;
+  }
+
+  /**
+   * Returns the authorization type in use.
+   *
+   * @return string
+   */
+  public function get_auth_type() {
+    return $this->auth_type;
+  }
+
+  /**
+   * Sets (and validates) authorization type in use. If an invalid auth_type is
+   * passed, AUTH_APP_USER is assumed.
+   *
+   * @param $auth_type
+   * @throws UGException
+   */
+  public function set_auth_type($auth_type) {
+    if ($auth_type == AUTH_APP_USER || $auth_type == AUTH_CLIENT_ID || $auth_type == AUTH_NONE) {
+      $this->auth_type = $auth_type;
+    }
+    else {
+      $this->auth_type = AUTH_APP_USER;
+      if ($this->use_exceptions) {
+        throw new UGException('Auth type is not valid');
+      }
+    }
+  }
+
+  /**
+   * Returns client_id.
+   *
+   * @return string
+   */
+  public function get_client_id() {
+    return $this->client_id;
+  }
+
+  /**
+   * Sets the client ID.
+   *
+   * @param string $id
+   */
+  public function set_client_id($id) {
+    $this->client_id = $id;
+  }
+
+  /**
+   * Gets the client secret.
+   *
+   * @return string
+   */
+  public function get_client_secret() {
+    return $this->client_secret;
+  }
+
+  /**
+   * Sets the client secret. You should have received this information when
+   * you registered your UserGrid/Apache account.
+   *
+   * @param $secret
+   */
+  public function set_client_secret($secret) {
+    $this->client_secret = $secret;
+  }
+
+  /**
+   * When set to TRUE, a curl command-line string will be generated. This may
+   * be useful when debugging.
+   *
+   * @param bool $bool
+   */
+  public function enable_build_curl($bool = TRUE) {
+    $this->build_curl = (bool) $bool;
+  }
+
+  /**
+   * Returns TRUE if curl command-line building is enabled, else FALSE.
+   *
+   * @return bool
+   */
+  public function is_build_curl_enabled() {
+    return $this->build_curl;
+  }
+
+  /**
+   * Enables/disables use of exceptions when errors are encountered.
+   *
+   * @param bool $bool
+   */
+  public function enable_exceptions($bool = TRUE) {
+    $this->use_exceptions = (bool) $bool;
+  }
+
+  /**
+   * @return bool
+   */
+  public function are_exceptions_enabled() {
+    return $this->use_exceptions;
+  }
+
+  /**
+   * Sets the callback for logging functions.
+   *
+   * @param Callable|NULL $callback
+   * @throws UGException
+   * @see write_log()
+   */
+  public function set_log_callback($callback = NULL) {
+    if (!empty($callback) && !is_callable($callback)) {
+      if ($this->use_exceptions) {
+        throw new UGException('Log Callback is not callable.');
+      }
+      $this->log_callback = NULL;
+    }
+    else {
+      $this->log_callback = (empty($callback) ? NULL : $callback);
+    }
+  }
+
+  /**
+   * Sets the timeout for HTTP calls in seconds. Internally this is stored in
+   * milliseconds.
+   *
+   * @param int|float $seconds
+   */
+  public function set_call_timeout($seconds = 30) {
+    $this->call_timeout = intval($seconds * 1000);
+  }
+
+  /**
+   * Gets timeout for HTTP calls in seconds. May return fractional parts.
+   *
+   * @return float
+   */
+  public function get_call_timeout() {
+    return $this->call_timeout / 1000;
+  }
+
+  /**
+   * Sets the callback to be invoked when an HTTP call timeout occurs.
+   *
+   * @TODO Actually use/invoke this callback. Currently not implemented.
+   *
+   * @param Callable|null $callback
+   * @throws UGException
+   */
+  public function set_call_timeout_callback($callback = NULL) {
+    if (!empty($callback) && !is_callable($callback)) {
+      if ($this->use_exceptions) {
+        throw new UGException('Call Timeout Callback is not callable.');
+      }
+      $this->call_timeout_callback = NULL;
+    }
+    else {
+      $this->call_timeout_callback = (empty($callback) ? NULL : $callback);
+    }
+  }
+
+  /**
+   * Sets the callback to be invoked upon logout.
+   *
+   * @TODO Actually use/invoke this callback. Currently not implemented.
+   *
+   * @param Callable|null $callback
+   * @throws UGException
+   */
+  public function set_logout_callback($callback = NULL) {
+    if (!empty($callback) && !is_callable($callback)) {
+      if ($this->use_exceptions) {
+        throw new UGException('Logout Callback is not callable.');
+      }
+      $this->logout_callback = NULL;
+    }
+    else {
+      $this->logout_callback = (empty($callback) ? NULL : $callback);
+    }
+  }
+
+  /* End accessor functions */
+
+  /**
+   * If a log callback has been set, invoke it to write a given message.
+   *
+   * @param $message
+   */
+  public function write_log($message) {
+    if (isset($this->log_callback)) {
+      call_user_func($this->log_callback, $message);
+    }
+  }
+
+  /**
+   * Issues a CURL request via HTTP/HTTPS and returns the response.
+   *
+   * @param Request $request
+   * @return Response
+   * @throws UG_404_NotFound
+   * @throws UG_403_Forbidden
+   * @throws UGException
+   * @throws UG_500_ServerError
+   * @throws UG_401_Unauthorized
+   * @throws UG_400_BadRequest
+   */
+  public function request(Request $request) {
+
+    $method = $request->get_method();
+    $endpoint = $request->get_endpoint();
+    $body = $request->get_body();
+    $query_string_array = $request->get_query_string_array();
+
+    if ($this->get_auth_type() == AUTH_APP_USER) {
+      if ($token = $this->get_oauth_token()) {
+        $query_string_array['access_token'] = $token;
+      }
+    } else {
+      $query_string_array['client_id'] = $this->get_client_id();
+      $query_string_array['client_secret'] = $this->get_client_secret();
+    }
+
+    foreach ($query_string_array as $key => $value) {
+      $query_string_array[$key] = urlencode($value);
+    }
+    $query_string = http_build_query($query_string_array);
+    if ($request->get_management_query()) {
+      $url = $this->url . '/' . $endpoint;
+    }
+    else {
+      $url = $this->url . '/' . $this->org_name . '/' . $this->app_name . '/' . $endpoint;
+    }
+
+    //append params to the path
+    if ($query_string) {
+      $url .= '?' . $query_string;
+    }
+    $curl = curl_init($url);
+
+    if ($method == 'POST' || $method == 'PUT' || $method == 'DELETE') {
+      curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
+    }
+    if ($method == 'POST' || $method == 'PUT') {
+      $body = json_encode($body);
+      curl_setopt($curl, CURLOPT_HTTPHEADER, array(
+        'Content-Length: ' . strlen($body),
+        'Content-Type: application/json'
+      ));
+      curl_setopt($curl, CURLOPT_POSTFIELDS, $body);
+    }
+
+
+    curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);
+    curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
+    curl_setopt($curl, CURLOPT_FOLLOWLOCATION, FALSE);
+    curl_setopt($curl, CURLOPT_MAXREDIRS, 10);
+    curl_setopt($curl, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
+
+
+    $response = curl_exec($curl);
+    $meta = curl_getinfo($curl);
+
+    curl_close($curl);
+
+
+    $response_array = @json_decode($response, TRUE);
+    $response_obj = new Response();
+    $response_obj->set_curl_meta($meta);
+    $response_obj->set_data($response_array);
+
+    $response_json = $response;
+    $response_obj->set_json($response_json);
+
+    if ($meta['http_code'] != 200)   {
+      //there was an API error
+      $error_code = $response_array['error'];
+      $description = isset($response_array['error_description'])?$response_array['error_description']:'';
+      $description = isset($response_array['exception'])?$response_array['exception']:$description;
+      $this->write_log('Error: '.$meta['http_code'].' error:'.$description);
+      $response_obj->set_error(TRUE);
+      $response_obj->set_error_code($error_code);
+      $response_obj->set_error_message($description);
+
+      if ($this->use_exceptions) {
+        switch ($meta['http_code']) {
+          case 400:
+            throw new UG_400_BadRequest($description, $meta['http_code']);
+            break;
+          case 401:
+            throw new UG_401_Unauthorized($description, $meta['http_code']);
+            break;
+          case 403:
+            throw new UG_403_Forbidden($description, $meta['http_code']);
+            break;
+          case 404:
+            throw new UG_404_NotFound($description, $meta['http_code']);
+            break;
+          case 500:
+            throw new UG_500_ServerError($description, $meta['http_code']);
+            break;
+          default:
+            throw new UGException($description, $meta['http_code']);
+            break;
+        }
+      }
+
+    }
+    else {
+      $response_obj->set_error(FALSE);
+      $response_obj->set_error_message(FALSE);
+    }
+
+    return $response_obj;
+  }
+
+  /**
+   * Performs an HTTP GET operation
+   *
+   * @param string $endpoint
+   * @param array $query_string_array
+   * @return Response
+   */
+  public function get($endpoint, $query_string_array) {
+
+    $request = new Request();
+    $request->set_method('GET');
+    $request->set_endpoint($endpoint);
+    $request->set_query_string_array($query_string_array);
+
+    $response = $this->request($request);
+
+    return $response;
+  }
+
+  /**
+   * Performs an HTTP POST operation
+   *
+   * @param string $endpoint
+   * @param array $query_string_array
+   * @param array $body
+   * @return Response
+   */
+  public function post($endpoint, $query_string_array, $body) {
+
+    $request = new Request();
+    $request->set_method('POST');
+    $request->set_endpoint($endpoint);
+    $request->set_query_string_array($query_string_array);
+    $request->set_body($body);
+
+    $response = $this->request($request);
+
+    return $response;
+  }
+
+  /**
+   * Performs an HTTP PUT operation
+   *
+   * @param string $endpoint
+   * @param array $query_string_array
+   * @param array $body
+   * @return Response
+   */
+  public function put($endpoint, $query_string_array, $body) {
+
+    $request = new Request();
+    $request->set_method('PUT');
+    $request->set_endpoint($endpoint);
+    $request->set_query_string_array($query_string_array);
+    $request->set_body($body);
+
+    $response = $this->request($request);
+
+    return $response;
+  }
+
+  /**
+   * Performs an HTTP DELETE operation
+   *
+   * @param string $endpoint
+   * @param array $query_string_array
+   * @return Response
+   */
+  public function delete($endpoint, $query_string_array) {
+    $request = new Request();
+    $request->set_method('DELETE');
+    $request->set_endpoint($endpoint);
+    $request->set_query_string_array($query_string_array);
+
+    $response = $this->request($request);
+
+    return $response;
+  }
+
+  /**
+   * Creates an entity. If no error occurred, the entity may be accessed in the
+   * returned object's ->parsed_objects['entity'] member.
+   *
+   * @param array $entity_data
+   * @return \Apache\Usergrid\Entity
+   */
+  public function create_entity($entity_data) {
+    $entity = new Entity($this, $entity_data);
+    $response = $entity->fetch();
+
+    $ok_to_save = (
+      ($response->get_error() && ('service_resource_not_found' == $response->get_error_code() || 'no_name_specified' == $response->get_error_code() || 'null_pointer' == $response->get_error_code() ))
+      ||
+      (!$response->get_error() && array_key_exists('getOnExist', $entity_data) && $entity_data['getOnExist'])
+    );
+
+    if ($ok_to_save) {
+      $entity->set($entity_data);
+      $response = $entity->save();
+      if ($response->get_error()) {
+        $this->write_log('Could not create entity.');
+        return FALSE;
+      }
+    }
+    elseif ($response->get_error() || array_key_exists('error', $response->get_data())) {
+      return FALSE;
+    }
+    return $entity;
+  }
+
+  /**
+   * Fetches and returns an entity.
+   *
+   * @param $entity_data
+   * @return \Apache\Usergrid\Entity|bool
+   */
+  public function get_entity($entity_data) {
+    $entity = new Entity($this, $entity_data);
+    $response = $entity->fetch();
+    if ($response->get_error()) {
+      $this->write_log($response->get_error_message());
+      return FALSE;
+    }
+    return $entity;
+  }
+
+  /**
+   * Fetches and returns a collection. If the collection does not yet exist,
+   * it is created.
+   *
+   * @param string $type
+   * @param array $qs
+   * @return \Apache\Usergrid\Collection
+   */
+  public function get_collection($type, $qs = array()) {
+    $collection = new Collection($this, $type, $qs);
+    return $collection;
+  }
+
+  /**
+   * Creates and returns a user-activity entity. Returns FALSE if such an
+   * entity could not be created.
+   *
+   * @param string $user_identifier
+   * @param array $user_data
+   * @return \Apache\Usergrid\Entity|bool
+   */
+  public function create_user_activity($user_identifier, $user_data) {
+    $user_data['type'] = "users/$user_identifier/activities";
+    $entity = new Entity($this, $user_data);
+    $response = $entity->save();
+    return ($response->get_error() ? FALSE : $entity);
+  }
+
+  /**
+   * Attempts a login. If successful, sets the OAuth token to be used for
+   * subsequent calls, and returns a User entity. If unsuccessful, returns
+   * FALSE.
+   *
+   * @param string $username
+   * @param string $password
+   * @return \Apache\Usergrid\Entity|bool
+   */
+  public function login($username, $password) {
+    $body = array(
+      'username' => $username,
+      'password' => $password,
+      'grant_type' => 'password'
+    );
+    $response = $this->POST('token', array(), $body);
+    if ($response->get_error()) {
+      $user = NULL;
+      $error = 'Error trying to log user in.';
+      $this->write_log($error);
+      if (!$response->get_error()) {
+        $response->set_error(TRUE);
+        $response->set_error_message($error);
+        $response->set_error_code($error);
+      }
+    }
+    else {
+      $response_data = $response->get_data();
+      $user = new Entity($this, $response_data['user']);
+      $this->set_oauth_token($response_data['access_token']);
+    }
+    return ($user && !$response->get_error() ? $user : FALSE);
+  }
+
+  /**
+   * Not yet implemented. Logs in via Facebook.
+   *
+   * @param $fb_token
+   */
+  public function login_facebook($fb_token) {
+    // TODO
+  }
+
+  /**
+   * A public facing helper method for signing up users
+   *
+   * @params string $username
+   * @params string $password
+   * @params string $email
+   * @params string $name
+   * @return \Apache\Usergrid\Entity
+   */
+  public function signup($username, $password, $email, $name) {
+    $data = array(
+      'type' => 'users',
+      'username' => $username,
+      'password' => $password,
+      'email' => $email,
+      'name' => $name
+    );
+    return $this->create_entity($data);
+  }
+
+  /**
+   * Returns current user as an entity. If no user is logged in,
+   * returns FALSE.
+   *
+   * @return Entity|bool
+   */
+  public function get_logged_in_user() {
+    $data = array('username' => 'me', 'type' => 'users');
+    return $this->get_entity($data);
+  }
+
+  /**
+   * Determines if a user is logged in.
+   *
+   * @return bool
+   */
+  public function is_logged_in() {
+    return !empty($this->oauth_token);
+  }
+
+  /**
+   * Logs current user out.
+   * @todo: Invoke logout callback.
+   */
+  public function log_out() {
+    $this->oauth_token = NULL;
+  }
+
+  /**
+   * Determines if a string is a valid UUID. Note that this function will
+   * return FALSE if the UUID is wrapped in curly-braces, Microsoft-style.
+   *
+   * @param $uuid
+   * @return bool
+   */
+  public static function is_uuid($uuid) {
+    static $regex = '/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i';
+    if (empty($uuid)) {
+      return FALSE;
+    }
+    return (bool) preg_match($regex, $uuid);
+  }
+
+  // TODO: Document the following methods
+
+  public function createNewNotifierApple($name, $environment, $p12Certificate_path) {
+
+    $endpoint = "notifiers";
+    $data = array(
+      "name" => $name,
+      "environment" => $environment,
+      "p12Certificate" => $p12Certificate_path,
+      "provider" => "apple"
+    );
+    return $this->post($endpoint, array(), $data);
+  }
+
+  public function createNewNotifierAndroid($name, $apiKey) {
+    $endpoint = "notifiers";
+    $data = array(
+      "name" => $name,
+      "apiKey" => $apiKey,
+      "provider" => "google"
+    );
+    return $this->post($endpoint, array(), $data);
+  }
+
+  public function createNotification() {
+    return new Notification();
+  }
+
+  public function scheduleNotification(Notification $notification) {
+    $notifier_name = $notification->get_notifier_name();
+    $message = $notification->get_message();
+    $delivery_time = $notification->get_delivery_time();
+    $recipients_list = $notification->get_recipients_list();
+    $recipient_type = $notification->get_recipient_type();
+
+    //we are trying to make this (where notifierName is the name of the notifier:
+    // { "payloads": { notifierName: "msg" }, "deliver":timestamp }
+    $body = array('payloads' => array($notifier_name => $message, 'deliver' => $delivery_time));
+
+    switch ($recipient_type) {
+      case GROUPS:
+        $type = 'groups/';
+        break;
+      case USERS:
+        $type = 'users/';
+        break;
+      case DEVICES:
+        $type = 'devices/';
+        break;
+      default:
+        $type = 'devices/';
+        $recipients_list = array(';ql=');
+    }
+
+    //schedule notification
+    if (count($recipients_list) > 0) {
+      foreach ($recipients_list as $recipient) {
+        $endpoint = $type . $recipient . '/notifications';
+        $result = $this->post($endpoint, array(), $body);
+        if ($result->get_error()) {
+          $notification->log_error($result->get_error());
+        }
+      }
+    }
+    return $notification;
+  }
+
+    /**
+     * Gets URL of Usergrid endpoint
+     *
+     * @return string
+     */
+    public function getUrl()
+    {
+        return $this->url;
+    }
+
+    /**
+     * Sets Usergrid endpoint URL
+     *
+     * @param string $url
+     * @return bool
+     * @throws UGException
+     */
+    public function setUrl($url)
+    {
+        if (filter_var($url, FILTER_VALIDATE_URL) !== false) {
+            $this->url = $url;
+            return true;
+        }
+        else {
+            if ($this->use_exceptions) {
+                throw new UGException('Invalid URL');
+            }
+        }
+    }
+
+}
+
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Collection.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Collection.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Collection.php
new file mode 100644
index 0000000..ee8a070
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Collection.php
@@ -0,0 +1,313 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Allows CRUD operations on Usergrid Collections.
+ *
+ * @author Daniel Johnson <dj...@apigee.com>
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 26-Apr-2013
+ */
+
+namespace Apache\Usergrid;
+require_once(dirname(__FILE__) . '/Exceptions.php');
+
+class Collection {
+
+  /**
+   * @var \Apache\Usergrid\Client
+   */
+  private $client;
+  /**
+   * @var string
+   */
+  private $type;
+  /**
+   * @var array
+   */
+  private $qs;
+  /**
+   * @var array
+   */
+  private $list;
+  /**
+   * @var int
+   */
+  private $iterator;
+  /**
+   * @var array
+   */
+  private $previous;
+  /**
+   * @var bool|int
+   */
+  private $next;
+  /**
+   * @var null|int
+   */
+  private $cursor;
+
+  /**
+   * @var string|string
+   */
+  private $json = '';
+
+  /**
+   * Object constructor.
+   *
+   * @param \Apache\Usergrid\Client $client
+   * @param string $type
+   * @param array $qs
+   */
+  public function __construct(Client $client, $type, $qs = array()) {
+    $this->client = $client;
+    $this->type = $type;
+    $this->qs = $qs;
+
+    $this->list = array();
+    $this->iterator = -1;
+
+    $this->previous = array();
+    $this->next = FALSE;
+    $this->cursor = NULL;
+
+    $this->fetch();
+  }
+
+  public function get_json() {
+    return $this->json;
+  }
+
+  public function set_json($json) {
+    $this->json = $json;
+  }
+
+  /**
+   * @return string
+   */
+  public function get_type() {
+    return $this->type;
+  }
+
+  /**
+   * @param string $type
+   */
+  public function set_type($type) {
+    $this->type = $type;
+  }
+
+  /**
+   * @return \Apache\Usergrid\Response
+   */
+  public function fetch() {
+    if ($this->cursor) {
+      $this->qs['cursor'] = $this->cursor;
+    }
+    elseif (array_key_exists('cursor', $this->qs)) {
+      unset($this->qs['cursor']);
+    }
+    $response = $this->client->get($this->type, $this->qs);
+    if ($response->get_error()) {
+      $this->client->write_log('Error getting collection.');
+    }
+    else {
+      $this->set_json($response->get_json());
+      $response_data = $response->get_data();
+      $cursor = (isset($response_data['cursor']) ? $response_data['cursor'] : NULL);
+      $this->save_cursor($cursor);
+      if (!empty($response_data['entities'])) {
+        $this->reset_entity_pointer();
+        $count = count($response_data['entities']);
+        $this->list = array();
+        for ($i = 0; $i < $count; $i++) {
+          $entity_data = $response_data['entities'][$i];
+          if (array_key_exists('uuid', $entity_data)) {
+            $entity = new Entity($this->client, $entity_data);
+            $entity->set('type', $this->type);
+
+            $this->list[] = $entity;
+          }
+        }
+      }
+    }
+    return $response;
+  }
+
+  /**
+   * @param array $entity_data
+   * @return \Apache\Usergrid\Entity
+   */
+  public function add_entity($entity_data) {
+    $entity = $this->client->create_entity($entity_data);
+    if ($entity) {
+      $this->list[] = $entity;
+    }
+    return $entity;
+  }
+
+  /**
+   * @param \Apache\Usergrid\Entity $entity
+   * @return \Apache\Usergrid\Response
+   */
+  public function destroy_entity(Entity $entity) {
+    $response = $entity->destroy();
+    if ($response->get_error()) {
+      $this->client->write_log('Could not destroy entity.');
+    }
+    else {
+      $response = $this->fetch();
+    }
+    return $response;
+  }
+
+  /**
+   * @param string $uuid
+   * @return \Apache\Usergrid\Response|bool
+   * @throws \Apache\Usergrid\UGException
+   */
+  public function get_entity_by_uuid($uuid) {
+    if (!Client::is_uuid($uuid)) {
+      if ($this->client->are_exceptions_enabled()) {
+        throw new UGException("Invalid UUID $uuid");
+      }
+      return FALSE;
+    }
+    $entity = new Entity($this->client, array('type' => $this->type, 'uuid' => $uuid));
+    return $entity->fetch();
+  }
+
+  /**
+   * @return \Apache\Usergrid\Entity|null
+   */
+  public function get_first_entity() {
+    return (count($this->list) > 0 ? $this->list[0] : NULL);
+  }
+
+  /**
+   * @return \Apache\Usergrid\Entity|null
+   */
+  public function get_last_entity() {
+    return (count($this->list) > 0 ? $this->list[count($this->list) - 1] : NULL);
+  }
+
+  /**
+   * @return bool
+   */
+  public function has_next_entity() {
+    $next = $this->iterator + 1;
+    return ($next >= 0 && $next < count($this->list));
+  }
+
+  /**
+   * @return bool
+   */
+  public function has_prev_entity() {
+    $prev = $this->iterator - 1;
+    return ($prev >= 0 && $prev < count($this->list));
+  }
+
+  /**
+   * @return \Apache\Usergrid\Entity|null
+   */
+  public function get_next_entity() {
+    if ($this->has_next_entity()) {
+      $this->iterator++;
+      return $this->list[$this->iterator];
+    }
+    return NULL;
+  }
+
+  /**
+   * @return \Apache\Usergrid\Entity|null
+   */
+  public function get_prev_entity() {
+    if ($this->has_prev_entity()) {
+      $this->iterator--;
+      return $this->list[$this->iterator];
+    }
+    return NULL;
+  }
+
+  public function reset_entity_pointer() {
+    $this->iterator = -1;
+  }
+
+  public function save_cursor($cursor) {
+    $this->next = $cursor;
+  }
+
+  public function reset_paging() {
+    $this->previous = array();
+    $this->next = FALSE;
+    $this->cursor = NULL;
+  }
+
+  public function has_next_page() {
+    return (bool) $this->next;
+  }
+
+  public function has_prev_page() {
+    return (count($this->previous) > 0);
+  }
+
+  /**
+   * @return \Apache\Usergrid\Response|bool
+   */
+  public function get_next_page() {
+    if ($this->has_next_page()) {
+      array_push($this->previous, $this->cursor);
+      $this->cursor = $this->next;
+      $this->list = array();
+      return $this->fetch();
+    }
+    return FALSE;
+  }
+
+  /**
+   * @return \Apache\Usergrid\Response|bool
+   */
+  public function get_prev_page() {
+    if ($this->has_prev_page()) {
+      $this->next = FALSE;
+      $this->cursor = array_pop($this->previous);
+      $this->list = array();
+      return $this->fetch();
+    }
+    return FALSE;
+  }
+  public function serialize(){
+    $data = array();
+    $data->type = $this->type;
+    $data->qs = $this->qs;
+    $data->iterator = $this->iterator;
+    $data->previous = $this->previous;
+    $data->next = $this->next;
+    $data->cursor = $this->cursor;
+    $data->list = array();
+    $this->reset_entity_pointer();
+    while ($this->has_next_entity()) {
+        $entity = $this->get_next_entity();
+        array_push($data->list, $entity->get_json());
+    }
+    return json_encode($data);
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Entity.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Entity.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Entity.php
new file mode 100755
index 0000000..ccb9377
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Entity.php
@@ -0,0 +1,320 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Allows CRUD operations on Usergrid Entities, including Users.
+ *
+ * @author Daniel Johnson <dj...@apigee.com>
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 26-Apr-2013
+ */
+
+namespace Apache\Usergrid;
+
+class Entity {
+
+  private $client;
+  private $data;
+  private $json;
+
+  public function __construct(Client $client, $data = array(), $json_data='') {
+    $this->client = $client;
+    $this->data = $data;
+    $this->json_data = $json_data;
+  }
+
+  public function get_json() {
+    return $this->json;
+  }
+
+  public function set_json($json) {
+    $this->json = $json;
+  }
+
+  public function get($field = NULL) {
+    if (!empty($field)) {
+      return (isset($this->data[$field]) ? $this->data[$field] : NULL);
+    }
+    return $this->data;
+  }
+
+  public function set($key, $value = NULL) {
+    if (is_array($key)) {
+      foreach ($key as $field => $value) {
+        $this->data[$field] = $value;
+      }
+    }
+    elseif (is_string($key)) {
+      if (!isset($value)) {
+        if (isset($this->data[$key])) {
+          unset($this->data[$key]);
+        }
+      }
+      else {
+        $this->data[$key] = $value;
+      }
+    }
+    else {
+      $this->data = array();
+    }
+  }
+
+  public function save() {
+    $type = $this->get('type');
+    $method = 'POST';
+    $uuid = $this->get('uuid');
+    if (isset($uuid) && Client::is_uuid($uuid)) {
+      $method = 'PUT';
+      $type .= "/$uuid";
+    }
+    $data = array();
+    $entity_data = $this->get();
+    foreach ($entity_data as $key => $val) {
+      switch ($key) {
+        case 'metadata':
+        case 'created':
+        case 'modified':
+        case 'type':
+        case 'activated':
+        case 'uuid':
+          continue;
+          break;
+        default:
+          $data[$key] = $val;
+      }
+    }
+
+    if ($method == 'PUT') {
+      $response = $this->client->put($type, array(), $data);
+    }
+    else {
+      $response = $this->client->post($type, array(), $data);
+    }
+
+    $this->set_json($response->get_json());
+
+    if ($response->get_error()) {
+      $this->client->write_log('Could not save entity.');
+    }
+    else {
+      $response_data = $response->get_data();
+      if (!empty($response_data['entities'])) {
+        $this->set($response_data['entities'][0]);
+      }
+      $need_password_change = (
+        ($this->get('type') == 'user' || $this->get('type') == 'users')
+        && !empty($entity_data['oldpassword'])
+        && !empty($entity_data['newpassword'])
+      );
+      if ($need_password_change) {
+        $pw_data = array(
+          'oldpassword' => $entity_data['oldpassword'],
+          'newpassword' => $entity_data['newpassword']
+        );
+        $response = $this->client->PUT("$type/password", array(), $pw_data);
+        if ($response->get_error()) {
+          $this->client->write_log('Could not update user\'s password.');
+        }
+        $this->set('oldpassword', NULL);
+        $this->set('newpassword', NULL);
+      }
+    }
+    return $response;
+  }
+
+  public function fetch() {
+    $response = new Response();
+    $type = $this->get('type');
+    $uuid = $this->get('uuid'); // may be NULL
+    if (!empty($uuid)) {
+      $type .= "/$uuid";
+    }
+    else {
+      if ($type == 'user' || $type == 'users') {
+        $username = $this->get('username');
+        if (!empty($username)) {
+          $type .= "/$username";
+        }
+        else {
+          $error = 'no_name_specified';
+          $this->client->write_log($error);
+          $response->set_error($error);
+          $response->set_error_code($error);
+          return $response;
+        }
+      }
+      else {
+        $name = $this->get('name');
+        if (!empty($name)) {
+          $type .= "/$name";
+        }
+        else {
+          $error = 'no_name_specified';
+          $this->client->write_log($error);
+          $response->set_error($error);
+          $response->set_error_code($error);
+          return $response;
+        }
+      }
+    }
+    $response = $this->client->get($type, array());
+    $this->set_json($response->get_json());
+    if ($response->get_error()) {
+      $this->client->write_log('Could not get entity.');
+    }
+    else {
+      $data = $response->get_data();
+      if (isset($data['user'])) {
+        $this->set($data['user']);
+      }
+      elseif (!empty($data['entities'])) {
+        $this->set($data['entities'][0]);
+      }
+    }
+    return $response;
+  }
+
+  public function destroy() {
+    $response = new Response();
+    $type = $this->get('type');
+    $uuid = $this->get('uuid');
+    if (Client::is_uuid($uuid)) {
+      $type .= "/$uuid";
+    }
+    else {
+      $error = 'Error trying to delete object: No UUID specified.';
+      $this->client->write_log($error);
+      $response->set_error($error);
+      $response->set_error_code($error);
+      return $response;
+    }
+
+    $response = $this->client->delete($type, array());
+    $this->set_json($response->get_json());
+    if ($response->get_error()) {
+      $this->client->write_log('Entity could not be deleted.');
+    }
+    else {
+      $this->set(NULL);
+    }
+    return $response;
+  }
+
+  public function connect($connection, $entity) {
+    $connectee=Entity::get_entity_id($entity);
+    $connecteeType=$entity->get("type");
+    if(!$connectee){
+      return "Error in connect. No UUID specified for connectee";
+    }
+
+    $connector=Entity::get_entity_id($this);
+    $connectorType=$this->get("type");
+    if(!$connector){
+      return "Error in connect. No UUID specified for connector";
+    }
+
+    $endpoint = $connectorType.'/'.$connector.'/'.$connection.'/'.$connecteeType.'/'.$connectee;
+    $result=$this->client->post($endpoint, array(), array());
+    $error=$result->get_error();
+    if($error){
+      return $result->get_error_message();
+    }else{
+      return $result->get_data();
+    }
+  }
+
+  public function disconnect($connection, $entity) {
+    $connectee=Entity::get_entity_id($entity);
+    $connecteeType=$entity->get("type");
+    if(!$connectee){
+      return "Error in disconnect. No UUID specified for connectee";
+    }
+
+    $connector=Entity::get_entity_id($this);
+    $connectorType=$this->get("type");
+    if(!$connector){
+      return "Error in disconnect. No UUID specified for connector";
+    }
+
+    $endpoint = $connectorType.'/'.$connector.'/'.$connection.'/'.$connecteeType.'/'.$connectee;
+
+    $result=$this->client->delete($endpoint, array(), array());
+    $error=$result->get_error();
+    if($error){
+      return $result->get_error_message();
+    }else{
+      return $result->get_data();
+    }
+  }
+
+  public static function get_entity_id($entity) {
+      $id = false;
+      if (Client::is_uuid($entity->get('uuid'))) {
+        $id = $entity->get('uuid');
+      } else {
+        if ($type == 'users') {
+          $id = $entity->get('username');
+        } else if ($entity->get('name')) {
+          $id = $entity->get('name');
+        }
+      }
+      return $id;
+  }
+
+  public function get_connections($connection) {
+    $connectorType = $this->get('type');
+    $connector = Entity::get_entity_id($this);
+    if (!$connector) {
+      return;
+    }
+
+    $endpoint = $connectorType . '/' . $connector . '/' . $connection . '/';
+    $result=$this->client->get($endpoint, array());
+
+    $connected_entities = array();
+
+    $response_data = $result->get_data();
+    $length        = count($response_data['entities']);
+    
+    for ($i = 0; $i < $length; $i++) {
+      $tmp_entity = $response_data['entities'][$i];
+      if ($tmp_entity['type'] == 'user') {
+          $connected_entities[$tmp_entity['username']] = $tmp_entity;
+      } else {
+          $connected_entities[$tmp_entity['name']]     = $tmp_entity;
+      }
+    }
+    $this->set($connection, $connected_entities);
+  }
+
+  public function get_connecting($connection) {
+    $connectorType = $this->get('type');
+    $connector = Entity::get_entity_id($this);
+    if (!$connector) {
+      return;
+    }
+
+    $endpoint = $connectorType. '/' . $connector . '/connecting/' . $connection . '/';
+    $result=$this->client->get($endpoint, array());
+    return $result->get_data();
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Exceptions.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Exceptions.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Exceptions.php
new file mode 100755
index 0000000..706e9e5
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Exceptions.php
@@ -0,0 +1,41 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+* @file
+* Request - a data structure to hold all request-related parameters
+*
+* @author Daniel Johnson <dj...@apigee.com>
+* @author Rod Simpson <ro...@apigee.com>
+* @since 26-Apr-2013
+*/
+
+
+namespace Apache\Usergrid;
+
+
+class UGException extends \Exception { }
+class UG_400_BadRequest extends UGException {}
+class UG_401_Unauthorized extends UGException {}
+class UG_403_Forbidden extends UGException {}
+class UG_404_NotFound extends UGException {}
+class UG_500_ServerError extends UGException {}
+
+?>


[19/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
new file mode 100644
index 0000000..55b1276
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
@@ -0,0 +1,486 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'find' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query Groups.',
+        'summary' => 'Query the groups collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'findById' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
+        'notes' => 'Find group by uuid.',
+        'summary' => 'Find group by uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'uuid' => [
+                'description' => 'Group UUID (entity uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'create' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new Group.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new Group entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'destroy' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete a Group entity.',
+        'summary' => 'Delete a Group entity by name or uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'update' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update a Group entity.',
+        'summary' => 'Update a Group entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'group name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'addUser' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}/users/{user_name_or_uuid}',
+        'notes' => 'Update a Group entity.',
+        'summary' => 'Update a Group entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'group name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_name_or_uuid' => [
+                'description' => 'user name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'removeUser' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}/users/{user_name_or_uuid}',
+        'notes' => 'Update a Group entity.',
+        'summary' => 'Update a Group entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'group name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_name_or_uuid' => [
+                'description' => 'user name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'groups'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Management.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
new file mode 100644
index 0000000..b471e77
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
@@ -0,0 +1,1076 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'AuthPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/token',
+        'summary' => 'Get management access token',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ]
+        ]
+    ],
+    'AuthorizeGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/authorize',
+        'summary' => 'Authorize the client.  See the OAuth2 specification.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'response_type' => [
+                'description' => 'Response type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'token',
+                'required' => true,
+                'allowableValues' => ['code', 'token']
+            ],
+            'client_id' => [
+                'description' => 'Client ID.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ]
+        ]
+
+    ],
+    'OrgJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs',
+        'summary' => 'Create new organization.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'organization' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization Name'
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}',
+        'summary' => 'Find organization by name or UUID',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/activate',
+        'summary' => 'Activates the organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'confirm' => [
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+                'description' => 'Send confirmation email'
+            ]
+
+        ]
+    ],
+    'OrgReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/reactivate',
+        'summary' => 'Reactivates the organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+        ]
+    ],
+    'OrgFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/feed',
+        'summary' => 'Get organization activity feed',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgCredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
+        'summary' => 'Get organization client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgCredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
+        'summary' => 'Generate organization client credentials',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgUsersGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Get admin users for organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgUsersJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Create new admin user for organization using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgUsersFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users',
+        'summary' => 'Create new admin user for organization using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'OrgUserPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'summary' => 'Adds existing admin users for organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin user username, email, or uuid'
+            ]
+        ]
+    ],
+    'OrgUserDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'summary' => 'Remove an admin user from organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin user username, email, or uuid'
+            ]
+        ]
+    ],
+    'OrgAppsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Get apps for organization',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppsJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Create new application for organization using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application Name'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgAppsFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
+        'summary' => 'Create new application for organization using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application Name'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'OrgAppDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}',
+        'summary' => 'Delete an application in an organization.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppCredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
+        'summary' => 'Get application keys.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgAppCredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
+        'summary' => 'Generate application keys.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'app_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Application name or uuid'
+            ]
+        ]
+    ],
+    'OrgUserJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users',
+        'summary' => 'Create new admin user.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'OrgUserFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users',
+        'summary' => 'Create new admin using form post parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+
+    ],
+    'OrgUserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/resetpw',
+        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+    ],
+    'OrgUserResetPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/resetpw',
+        'summary' => 'Complete a user password reset.  Handles form POST response.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'recaptcha_challenge_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Challenge Field'
+            ],
+            'recaptcha_response_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Response Field'
+            ],
+        ]
+    ],
+    'AdminUserGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}',
+        'summary' => 'Returns the admin user details',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+        ]
+
+    ],
+    'AdminUserJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}',
+        'summary' => 'Updates the admin user details.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+
+    ],
+    'AdminUserActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/activate',
+        'summary' => 'Activates the admin user from link provided in email notification.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'confirm' => [
+                'location' => 'uri',
+                'type' => 'boolean',
+                'required' => false,
+                'description' => 'Send confirmation email'
+            ],
+        ]
+    ],
+    'AdminUserReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/reactivate',
+        'summary' => 'Request admin user reactivation.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ]
+        ]
+    ],
+    'AdminUserFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/feed',
+        'summary' => 'Get admin user activity feed.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+        ]
+    ],
+    'AdminUserPasswordJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}/password',
+        'summary' => 'Set admin user password.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'old_password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Old and new password'
+            ],
+            'new_password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Old and new password'
+            ],
+        ]
+    ],
+    'AdminUserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
+        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ]
+        ]
+    ],
+    'AdminUserResetPasswordFormPost' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
+        'summary' => 'Complete a user password reset.  Handles form POST response.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'recaptcha_challenge_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Challenge Field'
+            ],
+            'recaptcha_response_field' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Recaptcha Response Field'
+            ]
+        ]
+    ],
+    'AdminUserOrgsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Get organizations for admin user.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ]
+    ],
+    'AdminUserOrgsJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Create new organization for admin user using JSON payload.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'organization' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'AdminUserOrgsFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
+        'summary' => 'Create new organization for admin user using form parameters.',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'organization' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'postField'
+        ]
+    ],
+    'AdminUserOrgPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
+        'summary' => 'Add admin users to organization.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'AdminUserOrgDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
+        'summary' => 'Remove an admin user from organization.',
+        'responseClass' => '',
+        'responseType' => 'object',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'description' => 'The OAuth2 access token'
+            ],
+            'user_username_email_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin username, email or uuid'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+
+        ]
+    ]
+
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
new file mode 100644
index 0000000..9499e6f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'name' => 'Usergrid',
+    'apiVersion' => '1.0.1',
+    'baseUrl' => $baseURL,
+    'description' => 'Client to Usergrid application service',
+    'operations' => []
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
new file mode 100644
index 0000000..638ad24
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
@@ -0,0 +1,19 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
new file mode 100644
index 0000000..be02717
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
@@ -0,0 +1,241 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+    'toGroup' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/{group}/notifications',
+        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'group' => [
+                'description' => 'group name',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ],
+    'toGroups' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/*/notifications',
+        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ],
+    'toDevice' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/{device_uuid}/notifications',
+        'notes' => 'Create Notification for single Device.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'device_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'device name or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ],
+    'toDevices' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/*/notifications',
+        'notes' => 'Create Notification all Devices.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ],
+    'toUser' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_name}/notifications',
+        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_name' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'User name or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ],
+    'toUsers' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/*/notifications',
+        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app notification',
+        'responseClass' => '',
+        'responseType' => 'model',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'user_name' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'User name or uuid'
+            ],
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'json'
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
new file mode 100644
index 0000000..41249a7
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
@@ -0,0 +1,166 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'createApple' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
+        'notes' => 'Create new Apple Notifier.  See Usergrid documentation for the format of body.',
+        'summary' => 'Create new Notifier entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'name' => [
+                'description' => 'notifier name (entity type)',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'provider' => [
+                'description' => 'notifier provider',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'apple'
+            ],
+            'environment' => [
+                'description' => 'notifier environment',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'p12Certificate' => [
+                'description' => 'p12Certificate',
+                'location' => 'postFile',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'users'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'postField'
+        ]
+
+    ],
+    'createGoogle' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
+        'notes' => 'Create new Notifier.  See Usergrid documentation for the format of body.',
+        'summary' => 'Create new Notifier entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'name' => [
+                'description' => 'notifier name (entity type)',
+                'location' => 'json',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'provider' => [
+                'description' => 'notifier provider',
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'google'
+            ],
+            'apiKey' => [
+                'description' => 'apiKey',
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
+        'notes' => 'Get all  Notifier.  See Usergrid documentation for the format of body.',
+        'summary' => 'Get all  Notifier entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'name' => [
+                'description' => 'notifier name (entity type)',
+                'location' => 'json',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
new file mode 100644
index 0000000..a51055f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [],
+    'find' => [],
+    'create' => [],
+    'destroy' => [],
+    'update' => []
+];
\ No newline at end of file


[12/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/README.md
----------------------------------------------------------------------
diff --git a/sdks/php/README.md b/sdks/php/README.md
deleted file mode 100644
index ec04cc9..0000000
--- a/sdks/php/README.md
+++ /dev/null
@@ -1,388 +0,0 @@
-##Quickstart
-Detailed instructions follow but if you just want a quick example of how to get started with this SDK, use this minimal PHP file to show you how to include & initialize the SDK, as well as how to read & write data from Usergrid with it.
-
-The file is located in this repository:
-
-	https://github.com/usergrid/usergrid/blob/master/sdks/php/examples/quick_start/index.php
-	
-
-```html
-<?php
-//include autoloader to make sure all files are included
-include '../autoloader.inc.php';
-
-//initialize the SDK
-$client = new Apache\Usergrid\Client('yourorgname','sandbox');
-
-//reading data
-$books = $client->get_collection('books');
-//do something with the data
-while ($books->has_next_entity()) {
-	$book = $books->get_next_entity();
-	$title = $book->get('title');
-	echo "Next Book's title is: " . $title . "<br>";
-}
-
-//writing data
-$data = array('title' => 'the old man and the sea', 'type' => 'books');
-$book = $books->add_entity($data);
-if ($book == FALSE) {
-	echo 'write failed';
-} else {
-	echo 'write succeeded';
-}
-?>
-```
-
-##Version
-
-Current Version: **0.0.1**
-
-See change log:
-
-<https://github.com/usergrid/usergrid/blob/master/sdks/php/changelog.md>
-
-**About this version:**
-
-This is the initial release of this SDK. It is functionally complete with some test coverage.  I plan to add additional test coverage in the near future as well as more examples.  
-
-This SDK is open source, and we welcome any contributions!  
-
-##Comments / Questions
-Please feel free to send comments or questions to the various
-community communication channels
-<http://usergrid.apache.org/community/>
-
-##Overview
-This open source SDK simplifies writing PHP applications that connect to App Services. The repo is located here:
-
-<https://github.com/usergrid/usergrid/tree/master/sdks/php>
-
-You can download the release artfacts via the Apache Mirroring newtwork.
-
-A wealth of Usergrid documentation can be found on the site
-
-<http://usergrid.apache.org/docs/>
-
-
-##About the samples
-This SDK comes with several samples to get you started.  They are located in this repo here:
-
-<https://github.com/usergrid/usergrid/tree/master/sdks/php/examples>
-
-The quick start shows how to get a basic file constructed.  The tests directory has the test code that is used to create this readme file.  **Note:** Ignore the //@han and //@solo comments - they are delimiters for the code parsing app we use to generate the readme.
-
-#Installing
-Download this repo, then add it to the root of your PHP project.
-
-#Getting started
-Once you have the the PHP SDK included in your directory tree, get started by including the SDK:
-
-	 include '../autoloader.inc.php';
-	 usergrid_autoload('Apache\\Usergrid\\Client');
-
-Then, start the client, which is the main object for connecting to the SDK.
-
-	 $client = new Apache\Usergrid\Client('1hotrod','sandbox');
-
-Once you have a client created, you will be able to use it to create Entities and Collections, the building blocks of the Usergrid API.
-
-##Entities
-This sdk provides an easy way to make new entities. Here is a simple example that shows how to create a new object of type "dogs":
-
-	 $data = array('name' => 'Dino', 'type' => 'dog');
-	 $dog = $client->create_entity($data);
-	 if ($dog) {
-	 	//once you have your entity, use the get() method to retrieve properties
-	 	$name = $dog->get('name');
-	 } else {
-	 	//there was an error creating / retrieving the entity
-	 }
-	
-**Note:** The above method will automatically get the entity if it already exists on the server.  
-
-If you only want to **get** an entity from the server: 
-
-	 $data = array('name' => 'Dino', 'type' => 'dog');
-	 $dog = $client->get_entity($data);
-	 if ($dog) {
-	 	$name = $dog->get('name');
-	 } else {
-	 	//entity doesn't exist on the server
-	 }
-	
-**Note:** The above method will return **false** if the entity does not exist, and will **not** automatically create a new entity.
-
-
-You can also refresh the object from the database if needed (in case the data has been updated by a different client or device), by calling the fetch() method:
-
-	 $dog->fetch();
-
-To set properties on the entity, use the set() method:
-
-	 $dog->set('master', 'Fred');
-	 $dog->set('breed', 'dinosaur');
-	 $dog->set('color', 'purple');
-
-These properties are now set locally, but make sure you call the save() method on the entity to save them back to the database!
-
-	 $result = $dog->save();
-	 if (!$result->get_error()) {
-	 	//all is well
-	 } else {
-	 	//there was a problem!
-	 }
-
-To get a single property from the entity, use the get method:
-
-
-
-To remove the entity from the database:
-
-	 $result = $dog->destroy();
-
-
-##The Collection object
-The Collection object models Collections in the database.  Once you start programming your app, you will likely find that this is the most useful method of interacting with the database.  
-
-**Note:** Collections are automatically created when entities are added.  So you can use the get_collection method even if there are no entities in your collection yet!
-
-Getting a collection will automatically populate the object with entities from the collection. The following example shows how to create a Collection object, then how to use entities once the Collection has been populated with entities from the server:
-
-	 $dogs = $client->get_collection('dogs');
-
-
-You can also add a new entity of the same type to the collection:
-
-	 $data = array('name' => 'Dino', 'type' => 'dogs');
-	 $dino = $dogs->add_entity($data);
-
-**Note:** this will also add the entity to the local collection object as well as creating it on the server
-
-
-##Collection iteration and paging
-The Collection object works in Pages of data.  This means that at any given time, the Collection object will have one page of data loaded.  You can iterate across all the entities in the current page of data by using the following pattern:
-
-	 while ($dogs->has_next_entity()) {
-	 	$dog = $dogs->get_next_entity();
-	 	//do something with dog
-	 	$name = $dog->get('name');
-	 }
-
-To iterate over the collection again, you must reset the entity pointer:
-
-	 $dogs->reset_entity_pointer();
-	 while ($dogs->has_next_entity()) {
-	 	$dog = $dogs->get_next_entity();
-	 	//do something with dog
-	 	$name = $dog->get('name');
-	 }
-	
-To get the next page of data:
-
-	 $dogs->get_next_page();
-	 while ($dogs->has_next_entity()) {
-	 	$dog = $dogs->get_next_entity();
-	 	$name = $dog->get('name');
-	 }
-
-You can use the same pattern to get a previous page of data:
-
-	 $dogs->get_prev_page();
-	 while ($dogs->has_next_entity()) {
-	 	$dog = $dogs->get_next_entity();
-	 	$name = $dog->get('name');
-	 }
-
-To get all the subsequent pages of data from the server and iterate across them, use the following pattern:
-
-	 while ($dogs->get_next_page()) {
-	 	while ($dogs->has_next_entity()) {
-	 		$dog = $dogs->get_next_entity();
-	 		$name = $dog->get('name');
-	 	}
-	 }
-
-
-By default, the database will return 10 entities per page.  You can change that amount by setting a limit:
-
-	 $data = array('ql'=>'select * where created > 0', 'limit'=>'40');
-	 $dogs = $client->get_collection('dogs', $data);
-
-Several other convenience methods exist to make working with pages of data easier:
-
-	* get_first_entity - gets the first entity of a page
-	* get_last_entity - gets the last entity of a page
-	* reset_entity_pointer - sets the internal pointer back to the first element of the page
-	* get_entity_by_uuid - returns the entity if it is in the current page
-
-
-
-##Modeling users with the Entity object
-There is no specific User object in this SDK.  Instead, you simply need to use the Entity object, specifying a type of "users".  Here is an example:
-
-	 $marty =  $client->signup('marty', 'mysecurepassword','marty@timetravel.com', 'Marty McFly');
-	 if ($marty) {
-	 	//user created
-	 } else {
-	 	//there was an error
-	 }
-
-If the user is modified, just call save on the user again:
-
-	 $marty->set('state', 'California');
-	 $marty->set('girlfriend', 'Jennifer');
-	 $result = $marty->save();
-
-To refresh the user's information in the database:
-
-
-
-To change the user's password:
-	
-	 $marty->set('oldpassword', 'mysecurepassword');
-	 $marty->set('newpassword', 'mynewsecurepassword');
-	 $marty->save();
-
-To log a user in:
-
-	 if ($client->login('marty', 'mysecurepassword')) {
-	 	//the login call will return an OAuth token, which is saved
-	 	//in the client. Any calls made now will use the token.
-	 	//once a user has logged in, their user object is stored
-	 	//in the client and you can access it this way:
-	 	$token = $client->get_oauth_token();
-	 } else {
-	 }
-
-To log a user out:
-
-	 $client->log_out();
-	 if ($client->is_logged_in()) {
-	 	//error - user is still logged in
-	 } else {
-	 	//success - user was logged out
-	 }
-
-If you no longer need the object, call the destroy() method and the object will be removed from database:
-
-	 $result = $marty->destroy();
-	 if ($result->get_error()) {
-	 	//there was an error deleting the user
-	 } else {
-	 	//success - user was deleted
-	 }
-	
-
-##Making generic calls
-If you find that you need to make calls to the API that fall outside of the scope of the Entity and Collection objects, you can use the following methods to make any of the REST calls (GET, POST, PUT, DELETE).
-
-GET:
-
-	 $endpoint = 'users/fred';
-	 $query_string = array();
-	 $result = $client->get($endpoint, $query_string);
-	 if ($result->get_error()){
-	 	//error - there was a problem getting the entity
-	 } else {
-	 	//success - entity retrieved
-	 }
-
-POST:
-
-	 $endpoint = 'users';
-	 $query_string = array();
-	 $body = array('username'=>'fred');
-	 $result = $client->post($endpoint, $query_string, $body);
-	 if ($result->get_error()){
-	 	//error - there was a problem creating the entity
-	 } else {
-	 	//success - entity created
-	 }
-	
-PUT:
-
-	 $endpoint = 'users/fred';
-	 $query_string = array();
-	 $body = array('dog'=>'dino');
-	 $result = $client->put($endpoint, $query_string, $body);
-	 if ($result->get_error()){
-	 	//error - there was a problem updating the entity
-	 } else {
-	 	//success - entity updated
-	 }
-	
-DELETE:
-
-	 $endpoint = 'users/idontexist';
-	 $query_string = array();
-	 try {
-	 	$result =  $client->delete($endpoint, $query_string);
-	 } catch (Exception $e) {
-	 	//entity didn't exist on the server, so UG_404_NotFound is thrown
-	 }
-	 
-	 ?>
-	 
-	 ?>
-	 $endpoint = 'users/fred';
-	 $query_string = array();
-	 $result =  $client->delete($endpoint, $query_string);
-	 if ($result->get_error()){
-	 	//error - there was a problem deleting the entity
-	 } else {
-	 	//success - entity deleted
-	 }
-
-
-You can make any call to the API using the format above.  However, in practice using the higher level Entity and Collection objects will make life easier as they take care of much of the heavy lifting.
-
-#Authentication
-By default, every App Services account comes with an app called "Sandbox".  While using the Sandbox app for testing, you will not need to worry about authentication as it has all permissions enabled for unauthenticated users.  However, when you are ready to create your own secured app, there are two authentication methods you will use: app user credentials, where your users sign in to get a token, and system level credentials (a client id / client secret combo).
-
-#App user credentials
-To get an Oauth token, users will sign into their accounts with a username and password.  See the "Modeling users with the Entity object" section above for details on how to use the login method.  Once logged in, the user's Oauth token is stored and used for all subsequent calls.
-
-The SDK uses app level credentials by default.
-
-
-#System level credentials (client id / client secret combo)
-If your app needs an elevated level of permissions, then you can use the client id / client secret combo. This is useful if you need to update permissions, do user manipulation, etc. Since the PHP sdk is running server-side, it is safe for you to use the client id / client secret combo on your API calls.  Keep in mind that if you are making API calls on behalf of your application user, say to get resources only they should have access to, such as a feed, it may be more appropriate to use the app user credentials described above.
-
-To use make calls using system level credentials, simply set the auth type and specify your client id and client secret:
-
-	 $testname = 'Use Client Auth type - ';
-	 $client->set_auth_type(AUTH_CLIENT_ID);
-	 $client->set_client_id('YXA6Us6Rg0b0EeKuRALoGsWhew');
-	 $client->set_client_secret('YXA6OYsTy6ENwwnbvjtvsbLpjw5mF40');
-
-
-## Contributing
-We welcome your enhancements!
-
-1. Fork it
-2. Create your feature branch (`git checkout -b my-new-feature`)
-3. Commit your changes (`git commit -am 'Added some feature'`)
-4. Push your changes to the upstream branch (`git push origin my-new-feature`)
-5. Create new Pull Request (make sure you describe what you did and why your mod is needed)
-
-##More information
-For more information on Usergrid, visit <http://usergrid.apache.org>.
-
-## Copyright
-Licensed to the Apache Software Foundation (ASF) under one or more
-contributor license agreements.  See the NOTICE file distributed with
-this work for additional information regarding copyright ownership.
-The ASF licenses this file to You under the Apache License, Version 2.0
-(the "License"); you may not use this file except in compliance with
-the License.  You may obtain a copy of the License at
-
-     http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/changelog.md
----------------------------------------------------------------------
diff --git a/sdks/php/changelog.md b/sdks/php/changelog.md
deleted file mode 100755
index e69de29..0000000

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/autoloader.inc.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/autoloader.inc.php b/sdks/php/examples/autoloader.inc.php
deleted file mode 100755
index 39f8bc5..0000000
--- a/sdks/php/examples/autoloader.inc.php
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-function usergrid_autoload($class) {
-
-
-  if (strpos($class, '\\') !== FALSE) {
-    $path_parts = explode('\\', $class);
-    if ($path_parts[0] == 'Apache') {
-      $lib_path = realpath(dirname(__FILE__) . '/../lib/vendor');
-      $class_path = $lib_path . '/' . join('/', $path_parts) . '.php';
-      if (file_exists($class_path)) {
-        require_once($class_path);
-      }
-    }
-  }
-}
-
-spl_autoload_register('usergrid_autoload');

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/quick_start/index.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/quick_start/index.php b/sdks/php/examples/quick_start/index.php
deleted file mode 100755
index 95dd861..0000000
--- a/sdks/php/examples/quick_start/index.php
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-//include autoloader to make sure all files are included
-include '../autoloader.inc.php';
-usergrid_autoload('Apache\\Usergrid\\Client');
-
-//initialize the SDK
-$client = new Apache\Usergrid\Client('yourorgname','sandbox');
-
-//reading data
-$books = $client->get_collection('books');
-//do something with the data
-while ($books->has_next_entity()) {
-	$book = $books->get_next_entity();
-	$title = $book->get('title');
-	echo "Next Book's title is: " . $title . "<br>";
-}
-
-//writing data
-$data = array('title' => 'the old man and the sea', 'type' => 'books');
-$book = $books->add_entity($data);
-if ($book == FALSE) {
-	echo 'write failed';
-} else {
-	echo 'write succeeded';
-}
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/Tester.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/Tester.php b/sdks/php/examples/tests/Tester.php
deleted file mode 100755
index 13f7e22..0000000
--- a/sdks/php/examples/tests/Tester.php
+++ /dev/null
@@ -1,80 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Tester - a simple class for logging during a test run
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-class Tester {
-
-  public $error_count = 0;
-	public $success_count = 0;
-
-	//logging
-	public $log_success = true;
-	public $log_error = true;
-	public $log_notice = true;
-
-  public function __construct() {
-
-  }
-
-	//logging functions
-	public function success($message){
-		$this->success_count++;
-		if ($this->log_success) {
-			echo('SUCCESS: ' . $message . '<br>');
-		}
-	}
-
-	public function error($message){
-		$this->error_count++;
-		if ($this->log_error) {
-			echo('ERROR: ' . $message . '<br>');
-		}
-	}
-
-	public function notice($message){
-		if ($this->log_notice) {
-			echo('NOTICE: ' . $message . '<br>');
-		}
-	}
-
-	function printSummary(){
-		echo '<br><br><br>';
-		echo '----------       Summary       ----------- <br>';
-		if ($this->error_count > 0) {
-			echo 'ERROR: BUILD NOT STABLE <br>';
-		} else {
-			echo 'OK: BUILD STABLE <br>';
-		}
-		echo 'Error Count: ' . $this->error_count . ' <br>';
-		echo 'Success Count: ' . $this->success_count . ' <br>';
-		echo '---------- Thanks for playing! ----------- <br>';
-	}
-
-}
-
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/client_auth.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/client_auth.php b/sdks/php/examples/tests/client_auth.php
deleted file mode 100755
index 17c5b73..0000000
--- a/sdks/php/examples/tests/client_auth.php
+++ /dev/null
@@ -1,101 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/**
- * @file
- * Client Auth tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 01-Apr-2013
- */
-
-//--------------------------------------------------------------
-// Client Auth
-//--------------------------------------------------------------
-//@han {client-auth}
-$testname = 'Use Client Auth type - ';
-$client->set_auth_type(AUTH_CLIENT_ID);
-$client->set_client_id('YXA6Us6Rg0b0EeKuRALoGsWhew');
-$client->set_client_secret('YXA6OYsTy6ENwwnbvjtvsbLpjw5mF40');
-//@solo
-
-//--------------------------------------------------------------
-// Generic Client Auth Tests
-//--------------------------------------------------------------
-$testname = 'DELETE users/fred';
-
-$endpoint = 'users/fred';
-$query_string = array();
-$result =  $client->delete($endpoint, $query_string);
-$data = $result->get_data();
-if ($data['action'] != 'delete'){
-  //error - there was a problem deleting the entity
-  $tester->error($testname);
-} else {
-  //success - entity deleted
-  $tester->success($testname);
-}
-
-if (!$result->get_error()) {
-  $tester->success($testname);
-} else {
-  $tester->error($testname);
-}
-
-$testname = 'POST users / fred';
-$endpoint = 'users';
-$query_string = array();
-$body = array('username'=>'fred');
-$result = $client->post($endpoint, $query_string, $body);
-$data = $result->get_data();
-if (isset($data['entities'][0]['username']) && $data['entities'][0]['username'] == 'fred'){
-  $tester->success($testname);
-} else {
-  $tester->error($testname);
-}
-
-
-$testname = 'PUT users/fred';
-$endpoint = 'users/fred';
-$query_string = array();
-$body = array('dog'=>'dino');
-$result = $client->put($endpoint, $query_string, $body);
-$data = $result->get_data();
-if (isset($data['entities'][0]['dog']) && $data['entities'][0]['dog'] == 'dino'){
-  $tester->success($testname);
-} else {
-  $tester->error($testname);
-}
-
-$testname = 'GET users/fred';
-$endpoint = 'users/fred';
-$query_string = array();
-$result = $client->get($endpoint, $query_string);
-$data = $result->get_data();
-if (isset($data['path']) && $data['path'] == '/users'){
-  $tester->success($testname);
-} else {
-  $tester->error($testname);
-}
-
-
-$client->set_auth_type(AUTH_APP_USER);
-$client->set_client_id(null);
-$client->set_client_secret(null);
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/collection.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/collection.php b/sdks/php/examples/tests/collection.php
deleted file mode 100755
index 1c49911..0000000
--- a/sdks/php/examples/tests/collection.php
+++ /dev/null
@@ -1,154 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Collection tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// Collection tests
-//--------------------------------------------------------------
-$testname = 'Create test data - ';
-for($i=0;$i<30;$i++) {
-	$testname = 'Create dog_'.$i;
-	$data = array('name' => 'dog_'.$i, 'type' => 'dogs');
-	$entity = $client->create_entity($data);
-	if ($entity->get('name') == 'dog_'.$i && $entity->get('type') == 'dog'){
-	  $tester->success($testname);
-	} else {
-		$tester->error($testname);
-	}
-}
-
-$testname = 'Get dogs collection';
-//@han {get-collection}
-$dogs = $client->get_collection('dogs');
-//@solo
-//echo '<pre>'.$dogs->get_json().'</pre><br>';
-if ($dogs->get_type() == 'dogs') {
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-//@han {iterate-collection}
-while ($dogs->has_next_entity()) {
-	$dog = $dogs->get_next_entity();
-	//do something with dog
-	$name = $dog->get('name');
-}
-//@solo
-
-//@han {re-iterate-collection}
-$dogs->reset_entity_pointer();
-while ($dogs->has_next_entity()) {
-	$dog = $dogs->get_next_entity();
-	//do something with dog
-	$name = $dog->get('name');
-}
-//@solo
-
-//@han {get-next-page-collection}
-$dogs->get_next_page();
-while ($dogs->has_next_entity()) {
-	$dog = $dogs->get_next_entity();
-	$name = $dog->get('name');
-}
-//@solo
-
-//@han {get-prev-page-collection}
-$dogs->get_prev_page();
-while ($dogs->has_next_entity()) {
-	$dog = $dogs->get_next_entity();
-	$name = $dog->get('name');
-}
-//@solo
-
-
-$testname = 'Get next page of dogs collection';
-$testname2 = 'Verify next page of dogs collection - ';
-//@han {iterate-over-entire-collection}
-while ($dogs->get_next_page()) {
-	$tester->success($testname);
-	while ($dogs->has_next_entity()) {
-		$dog = $dogs->get_next_entity();
-		$name = $dog->get('name');
-		//@solo
-		if ($entity->get('type') == 'dog'){
-			$tester->success($testname2.$name);
-		} else {
-			$tester->error($testname2.$name);
-		}
-		//@han {iterate-over-entire-collection2}
-	}
-}
-//@solo
-
-//@han {get-previous-page-collection}
-while ($dogs->get_prev_page()) {
-	$testname = 'Get next page of dogs collection';
-	$tester->success($testname);
-	$testname = 'Verify next page of dogs collection - ';
-	while ($dogs->has_next_entity()) {
-		$dog = $dogs->get_next_entity();
-		$name = $dog->get('name');
-		if ($entity->get('type') == 'dog'){
-			$tester->success($testname.$name);
-		} else {
-			$tester->error($testname.$name);
-		}
-	}
-}
-
-$testname = 'Add new dog to collection';
-//@han {add-entity-to-collection}
-$data = array('name' => 'Dino', 'type' => 'dogs');
-$dino = $dogs->add_entity($data);
-//@solo
-if ($dino->get('name') == 'Dino') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-//@han {set-limit-collection}
-$data = array('ql'=>'select * where created > 0', 'limit'=>'40');
-$dogs = $client->get_collection('dogs', $data);
-//@solo
-
-$testname = 'Clear dogs sample data - ';
-$dogs->reset_entity_pointer();
-while ($dogs->has_next_entity()) {
-	$dog = $dogs->get_next_entity();
-	$name = $dog->get('name');
-	$result = $dog->destroy();
-	$response_data = $result->get_data();
-	if (isset($response_data['action']) && $response_data['action'] == 'delete') {
-		$tester->success($testname.$name);
-	} else {
-		$tester->error($testname.$name);
-	}
-}
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/entity.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/entity.php b/sdks/php/examples/tests/entity.php
deleted file mode 100755
index 1f564f2..0000000
--- a/sdks/php/examples/tests/entity.php
+++ /dev/null
@@ -1,114 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Entity tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// Entity tests
-//--------------------------------------------------------------
-$testname = 'Create Entity';
-//@han {create-entity}
-$data = array('name' => 'Dino', 'type' => 'dog');
-$dog = $client->create_entity($data);
-if ($dog) {
-	//once you have your entity, use the get() method to retrieve properties
-	$name = $dog->get('name');
-} else {
-	//there was an error creating / retrieving the entity
-}
-//@solo
-if ($dog->get('name') == 'Dino' && $dog->get('type') == 'dog'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Get Entity';
-//@han {get-entity}
-$data = array('name' => 'Dino', 'type' => 'dog');
-$dog = $client->get_entity($data);
-if ($dog) {
-	$name = $dog->get('name');
-} else {
-	//entity doesn't exist on the server
-}
-//@solo
-if ($name == 'Dino' && $dog->get('type') == 'dog'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-//@han {refresh-entity}
-$dog->fetch();
-//@solo
-
-
-$testname = 'Set key on entity';
-//@han {set-entity}
-$dog->set('master', 'Fred');
-$dog->set('breed', 'dinosaur');
-$dog->set('color', 'purple');
-//@solo
-if ($dog->get('color') == 'purple') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Save key on entity';
-//@han {save-entity}
-$result = $dog->save();
-if (!$result->get_error()) {
-	//all is well
-	$tester->success($testname);
-} else {
-	//there was a problem!
-	$tester->error($testname);
-}
-//@solo
-
-$testname = 'Refresh entity and check key';
-$dog->set('color', 'red'); //set the value
-$result = $dog->fetch(); //refresh to overwrite
-if ($dog->get('color') == 'purple') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Delete entity';
-//@han {destroy-entity}
-$result = $dog->destroy();
-//@solo
-$data = $result->get_data();
-if (isset($data['action']) && $data['action'] == 'delete') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/exceptions.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/exceptions.php b/sdks/php/examples/tests/exceptions.php
deleted file mode 100755
index 45d44c0..0000000
--- a/sdks/php/examples/tests/exceptions.php
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * exceptions tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// Exception Tests - NOT DONE YET!!!
-//--------------------------------------------------------------
-$testname = 'DELETE users/fred';
-//@han {generic-delete}
-$endpoint = 'users/idontexist';
-$query_string = array();
-try {
-	$result =  $client->delete($endpoint, $query_string);
-} catch (Exception $e) {
-	//entity didn't exist on the server, so UG_404_NotFound is thrown
-	$tester->success($testname);
-}
-
-?>
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/generic.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/generic.php b/sdks/php/examples/tests/generic.php
deleted file mode 100755
index 11ba083..0000000
--- a/sdks/php/examples/tests/generic.php
+++ /dev/null
@@ -1,122 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Generic tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// Generic Tests
-//--------------------------------------------------------------
-$testname = 'DELETE users/fred';
-//@han {generic-delete}
-$endpoint = 'users/fred';
-$query_string = array();
-$result =  $client->delete($endpoint, $query_string);
-if ($result->get_error()){
-	//error - there was a problem deleting the entity
-} else {
-	//success - entity deleted
-}
-//@solo
-$data = $result->get_data();
-if ($data['action'] != 'delete'){
-	//error - there was a problem deleting the entity
-  $tester->error($testname);
-} else {
-	//success - entity deleted
-	$tester->success($testname);
-}
-
-if (!$result->get_error()) {
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'POST users / fred';
-//@han {generic-post}
-$endpoint = 'users';
-$query_string = array();
-$body = array('username'=>'fred');
-$result = $client->post($endpoint, $query_string, $body);
-if ($result->get_error()){
-	//error - there was a problem creating the entity
-  $tester->error($testname);
-} else {
-	//success - entity created
-	$tester->success($testname);
-}
-//@solo
-$data = $result->get_data();
-$json = $result->get_json();
-//echo '<pre>'.$json.'</pre><br>';
-if (isset($data['entities'][0]['username']) && $data['entities'][0]['username'] == 'fred'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-
-$testname = 'PUT users/fred';
-//@han {generic-put}
-$endpoint = 'users/fred';
-$query_string = array();
-$body = array('dog'=>'dino');
-$result = $client->put($endpoint, $query_string, $body);
-if ($result->get_error()){
-	//error - there was a problem updating the entity
-  $tester->error($testname);
-} else {
-	//success - entity updated
-	$tester->success($testname);
-}
-//@solo
-$data = $result->get_data();
-if (isset($data['entities'][0]['dog']) && $data['entities'][0]['dog'] == 'dino'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'GET users/fred';
-//@han {generic-get}
-$endpoint = 'users/fred';
-$query_string = array();
-$result = $client->get($endpoint, $query_string);
-if ($result->get_error()){
-	//error - there was a problem getting the entity
-  $tester->error($testname);
-} else {
-	//success - entity retrieved
-	$tester->success($testname);
-}
-//@solo
-$data = $result->get_data();
-if (isset($data['path']) && $data['path'] == '/users'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/push.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/push.php b/sdks/php/examples/tests/push.php
deleted file mode 100755
index 5c7e1e0..0000000
--- a/sdks/php/examples/tests/push.php
+++ /dev/null
@@ -1,71 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Push Notification tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// Push tests
-//--------------------------------------------------------------
-$testname = 'Create apple notifier';
-$apple_name = 'name_'.time();
-$environment = 'development';
-$p12Certificate_path = "@pushtest_dev.p12";
-$result =  $client->createNewNotifierApple($apple_name, $environment, $p12Certificate_path);
-echo '<pre>'.$result->get_json().'</pre><br>';
-if ($result->get_error()){
-  $tester->error($testname);
-} else {
-	$tester->success($testname);
-}
-
-$testname = 'Create google notifier';
-$google_name = 'name_'.time();
-$apiKey = 'AIzaSyCIH_7WC0mOqBGMOXyQnFgrBpOePgHvQJM';
-$result =  $client->createNewNotifierAndroid($google_name, $apiKey);
-echo '<pre>'.$result->get_json().'</pre><br>';
-if ($result->get_error()){
-  $tester->error($testname);
-} else {
-	$tester->success($testname);
-}
-
-$testname = 'Create notification';
-$notification = $client->createNotification();
-$notification->set_notifier_name($apple_name);
-$notification->set_message("Test Message");
-$notification->set_delivery_time(time());
-$notification->set_recipients_list(array(0=>'fred'));
-$notification->set_recipient_type(USERS);
-
-$result = $client->scheduleNotification($notification);
-echo '<pre>'.$result->get_json().'</pre><br>';
-if ($result->get_error()){
-  $tester->error($testname);
-} else {
-	$tester->success($testname);
-}
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/pushtest_dev.p12
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/pushtest_dev.p12 b/sdks/php/examples/tests/pushtest_dev.p12
deleted file mode 100644
index b4373a2..0000000
Binary files a/sdks/php/examples/tests/pushtest_dev.p12 and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/test.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/test.php b/sdks/php/examples/tests/test.php
deleted file mode 100755
index e0578d2..0000000
--- a/sdks/php/examples/tests/test.php
+++ /dev/null
@@ -1,56 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * main entry point for running tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//@han {include-sdk}
-include '../autoloader.inc.php';
-usergrid_autoload('Apache\\Usergrid\\Client');
-//@solo
-
-//@han {create-new-client}
-$client = new Apache\Usergrid\Client('1hotrod','sandbox');
-//@solo
-
-include 'Tester.php';
-
-$tester = new Tester();
-
-include 'generic.php';
-include 'entity.php';
-include 'collection.php';
-include 'user.php';
-include 'client_auth.php';
-include 'push.php';
-
-
-
-//--------------------------------------------------------------
-// Summary
-//--------------------------------------------------------------
-$tester->printSummary();
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/examples/tests/user.php
----------------------------------------------------------------------
diff --git a/sdks/php/examples/tests/user.php b/sdks/php/examples/tests/user.php
deleted file mode 100755
index 545ba7a..0000000
--- a/sdks/php/examples/tests/user.php
+++ /dev/null
@@ -1,137 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * User tests
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-//--------------------------------------------------------------
-// User tests
-//--------------------------------------------------------------
-$testname = 'DELETE users/marty';
-$endpoint = 'users/marty';
-$query_string = array();
-$result =  $client->delete($endpoint, $query_string);
-$result_data = $result->get_data();
-if (isset($result_data)){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Signup user';
-//@han {create-user}
-$marty =  $client->signup('marty', 'mysecurepassword','marty@timetravel.com', 'Marty McFly');
-if ($marty) {
-	//user created
-} else {
-	//there was an error
-}
-//@solo
-if ($marty->get('username') == 'marty'){
-  $tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Update user';
-//@han {update-user}
-$marty->set('state', 'California');
-$marty->set('girlfriend', 'Jennifer');
-$result = $marty->save();
-//@solo
-if ($result->get_error()) {
-	$tester->error($testname);
-} else {
-	$tester->success($testname);
-}
-
-$testname = 'Log user in';
-//@han {log-user-in}
-if ($client->login('marty', 'mysecurepassword')) {
-	//the login call will return an OAuth token, which is saved
-	//in the client. Any calls made now will use the token.
-	//once a user has logged in, their user object is stored
-	//in the client and you can access it this way:
-	$token = $client->get_oauth_token();
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-//@solo
-
-$testname = 'Get logged in user';
-$marty = $client->get_logged_in_user();
-if (isset($marty) && $marty->get('username') == 'marty') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Update user password';
-//@han {update-user-password}
-$marty->set('oldpassword', 'mysecurepassword');
-$marty->set('newpassword', 'mynewsecurepassword');
-$marty->save();
-//@solo
-$result_data = $result->get_data();
-if (isset($result_data['action']) && $result_data['action'] == 'put') {
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Log user out';
-//@han {log-user-out}
-$client->log_out();
-if ($client->is_logged_in()) {
-	//error - user is still logged in
-	$tester->error($testname);
-} else {
-	//success - user was logged out
-	$tester->success($testname);
-}
-//@solo
-
-$testname = 'Log user in with new password';
-if ($client->login('marty', 'mynewsecurepassword')){
-	$tester->success($testname);
-} else {
-	$tester->error($testname);
-}
-
-$testname = 'Delete user';
-//@han {destroy-user}
-$result = $marty->destroy();
-if ($result->get_error()) {
-	//there was an error deleting the user
-	$tester->error($testname);
-} else {
-	//success - user was deleted
-	$tester->success($testname);
-}
-//@solo
-
-
-?>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Client.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Client.php b/sdks/php/lib/vendor/Apache/Usergrid/Client.php
deleted file mode 100755
index cd0120d..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Client.php
+++ /dev/null
@@ -1,813 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Basic class for accessing Usergrid functionality.
- *
- * @author Daniel Johnson <dj...@apigee.com>
- * @author Rod Simpson <ro...@apigee.com>
- * @since 26-Apr-2013
- */
-
-namespace Apache\Usergrid;
-
-require_once(dirname(__FILE__) . '/Exceptions.php');
-
-define('AUTH_CLIENT_ID', 'CLIENT_ID');
-define('AUTH_APP_USER', 'APP_USER');
-define('AUTH_NONE', 'NONE');
-
-class Client {
-
-  const SDK_VERSION = '0.1';
-
-  /**
-   * Usergrid endpoint
-   * @var string
-   */
-  private $url = 'http://api.usergrid.com';
-
-  /**
-   * Organization name. Find your in the Admin Portal
-   * @var string
-   */
-  private $org_name;
-
-  /**
-   * App name. Find your in the Admin Portal
-   * @var string
-   */
-  private $app_name;
-
-  /**
-   * @var bool
-   */
-  private $build_curl = FALSE;
-
-  /**
-   * @var bool
-   */
-  private $use_exceptions = FALSE;
-
-  /**
-   * @var Callable
-   */
-  private $log_callback = NULL;
-
-  /**
-   * @var int
-   */
-  private $call_timeout = 30000;
-
-  /**
-   * @var Callable
-   */
-  private $call_timeout_callback = NULL;
-
-  /**
-   * @var Callable
-   */
-  private $logout_callback = NULL;
-
-  /**
-   * @var string
-   */
-  private $oauth_token;
-
-  /**
-   * @var string
-   */
-  private $client_id;
-
-  /**
-   * @var string
-   */
-  private $client_secret;
-
-  /**
-   * @var string
-   */
-  private $auth_type = AUTH_APP_USER;
-
-  /**
-   * Object constructor
-   *
-   * @param string $org_name
-   * @param string $app_name
-   */
-  public function __construct($org_name, $app_name) {
-    $this->org_name = $org_name;
-    $this->app_name = $app_name;
-  }
-
-  /* Accessor functions */
-
-  /**
-   * Returns OAuth token if it has been set; else NULL.
-   *
-   * @return string|NULL
-   */
-  public function get_oauth_token() {
-    return $this->oauth_token;
-  }
-
-  /**
-   * Sets OAuth token.
-   *
-   * @param string $token
-   */
-  public function set_oauth_token($token) {
-    $this->oauth_token = $token;
-  }
-
-  /**
-   * Returns the authorization type in use.
-   *
-   * @return string
-   */
-  public function get_auth_type() {
-    return $this->auth_type;
-  }
-
-  /**
-   * Sets (and validates) authorization type in use. If an invalid auth_type is
-   * passed, AUTH_APP_USER is assumed.
-   *
-   * @param $auth_type
-   * @throws UGException
-   */
-  public function set_auth_type($auth_type) {
-    if ($auth_type == AUTH_APP_USER || $auth_type == AUTH_CLIENT_ID || $auth_type == AUTH_NONE) {
-      $this->auth_type = $auth_type;
-    }
-    else {
-      $this->auth_type = AUTH_APP_USER;
-      if ($this->use_exceptions) {
-        throw new UGException('Auth type is not valid');
-      }
-    }
-  }
-
-  /**
-   * Returns client_id.
-   *
-   * @return string
-   */
-  public function get_client_id() {
-    return $this->client_id;
-  }
-
-  /**
-   * Sets the client ID.
-   *
-   * @param string $id
-   */
-  public function set_client_id($id) {
-    $this->client_id = $id;
-  }
-
-  /**
-   * Gets the client secret.
-   *
-   * @return string
-   */
-  public function get_client_secret() {
-    return $this->client_secret;
-  }
-
-  /**
-   * Sets the client secret. You should have received this information when
-   * you registered your UserGrid/Apache account.
-   *
-   * @param $secret
-   */
-  public function set_client_secret($secret) {
-    $this->client_secret = $secret;
-  }
-
-  /**
-   * When set to TRUE, a curl command-line string will be generated. This may
-   * be useful when debugging.
-   *
-   * @param bool $bool
-   */
-  public function enable_build_curl($bool = TRUE) {
-    $this->build_curl = (bool) $bool;
-  }
-
-  /**
-   * Returns TRUE if curl command-line building is enabled, else FALSE.
-   *
-   * @return bool
-   */
-  public function is_build_curl_enabled() {
-    return $this->build_curl;
-  }
-
-  /**
-   * Enables/disables use of exceptions when errors are encountered.
-   *
-   * @param bool $bool
-   */
-  public function enable_exceptions($bool = TRUE) {
-    $this->use_exceptions = (bool) $bool;
-  }
-
-  /**
-   * @return bool
-   */
-  public function are_exceptions_enabled() {
-    return $this->use_exceptions;
-  }
-
-  /**
-   * Sets the callback for logging functions.
-   *
-   * @param Callable|NULL $callback
-   * @throws UGException
-   * @see write_log()
-   */
-  public function set_log_callback($callback = NULL) {
-    if (!empty($callback) && !is_callable($callback)) {
-      if ($this->use_exceptions) {
-        throw new UGException('Log Callback is not callable.');
-      }
-      $this->log_callback = NULL;
-    }
-    else {
-      $this->log_callback = (empty($callback) ? NULL : $callback);
-    }
-  }
-
-  /**
-   * Sets the timeout for HTTP calls in seconds. Internally this is stored in
-   * milliseconds.
-   *
-   * @param int|float $seconds
-   */
-  public function set_call_timeout($seconds = 30) {
-    $this->call_timeout = intval($seconds * 1000);
-  }
-
-  /**
-   * Gets timeout for HTTP calls in seconds. May return fractional parts.
-   *
-   * @return float
-   */
-  public function get_call_timeout() {
-    return $this->call_timeout / 1000;
-  }
-
-  /**
-   * Sets the callback to be invoked when an HTTP call timeout occurs.
-   *
-   * @TODO Actually use/invoke this callback. Currently not implemented.
-   *
-   * @param Callable|null $callback
-   * @throws UGException
-   */
-  public function set_call_timeout_callback($callback = NULL) {
-    if (!empty($callback) && !is_callable($callback)) {
-      if ($this->use_exceptions) {
-        throw new UGException('Call Timeout Callback is not callable.');
-      }
-      $this->call_timeout_callback = NULL;
-    }
-    else {
-      $this->call_timeout_callback = (empty($callback) ? NULL : $callback);
-    }
-  }
-
-  /**
-   * Sets the callback to be invoked upon logout.
-   *
-   * @TODO Actually use/invoke this callback. Currently not implemented.
-   *
-   * @param Callable|null $callback
-   * @throws UGException
-   */
-  public function set_logout_callback($callback = NULL) {
-    if (!empty($callback) && !is_callable($callback)) {
-      if ($this->use_exceptions) {
-        throw new UGException('Logout Callback is not callable.');
-      }
-      $this->logout_callback = NULL;
-    }
-    else {
-      $this->logout_callback = (empty($callback) ? NULL : $callback);
-    }
-  }
-
-  /* End accessor functions */
-
-  /**
-   * If a log callback has been set, invoke it to write a given message.
-   *
-   * @param $message
-   */
-  public function write_log($message) {
-    if (isset($this->log_callback)) {
-      call_user_func($this->log_callback, $message);
-    }
-  }
-
-  /**
-   * Issues a CURL request via HTTP/HTTPS and returns the response.
-   *
-   * @param Request $request
-   * @return Response
-   * @throws UG_404_NotFound
-   * @throws UG_403_Forbidden
-   * @throws UGException
-   * @throws UG_500_ServerError
-   * @throws UG_401_Unauthorized
-   * @throws UG_400_BadRequest
-   */
-  public function request(Request $request) {
-
-    $method = $request->get_method();
-    $endpoint = $request->get_endpoint();
-    $body = $request->get_body();
-    $query_string_array = $request->get_query_string_array();
-
-    if ($this->get_auth_type() == AUTH_APP_USER) {
-      if ($token = $this->get_oauth_token()) {
-        $query_string_array['access_token'] = $token;
-      }
-    } else {
-      $query_string_array['client_id'] = $this->get_client_id();
-      $query_string_array['client_secret'] = $this->get_client_secret();
-    }
-
-    foreach ($query_string_array as $key => $value) {
-      $query_string_array[$key] = urlencode($value);
-    }
-    $query_string = http_build_query($query_string_array);
-    if ($request->get_management_query()) {
-      $url = $this->url . '/' . $endpoint;
-    }
-    else {
-      $url = $this->url . '/' . $this->org_name . '/' . $this->app_name . '/' . $endpoint;
-    }
-
-    //append params to the path
-    if ($query_string) {
-      $url .= '?' . $query_string;
-    }
-    $curl = curl_init($url);
-
-    if ($method == 'POST' || $method == 'PUT' || $method == 'DELETE') {
-      curl_setopt($curl, CURLOPT_CUSTOMREQUEST, $method);
-    }
-    if ($method == 'POST' || $method == 'PUT') {
-      $body = json_encode($body);
-      curl_setopt($curl, CURLOPT_HTTPHEADER, array(
-        'Content-Length: ' . strlen($body),
-        'Content-Type: application/json'
-      ));
-      curl_setopt($curl, CURLOPT_POSTFIELDS, $body);
-    }
-
-
-    curl_setopt($curl, CURLOPT_RETURNTRANSFER, TRUE);
-    curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
-    curl_setopt($curl, CURLOPT_FOLLOWLOCATION, FALSE);
-    curl_setopt($curl, CURLOPT_MAXREDIRS, 10);
-    curl_setopt($curl, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
-
-
-    $response = curl_exec($curl);
-    $meta = curl_getinfo($curl);
-
-    curl_close($curl);
-
-
-    $response_array = @json_decode($response, TRUE);
-    $response_obj = new Response();
-    $response_obj->set_curl_meta($meta);
-    $response_obj->set_data($response_array);
-
-    $response_json = $response;
-    $response_obj->set_json($response_json);
-
-    if ($meta['http_code'] != 200)   {
-      //there was an API error
-      $error_code = $response_array['error'];
-      $description = isset($response_array['error_description'])?$response_array['error_description']:'';
-      $description = isset($response_array['exception'])?$response_array['exception']:$description;
-      $this->write_log('Error: '.$meta['http_code'].' error:'.$description);
-      $response_obj->set_error(TRUE);
-      $response_obj->set_error_code($error_code);
-      $response_obj->set_error_message($description);
-
-      if ($this->use_exceptions) {
-        switch ($meta['http_code']) {
-          case 400:
-            throw new UG_400_BadRequest($description, $meta['http_code']);
-            break;
-          case 401:
-            throw new UG_401_Unauthorized($description, $meta['http_code']);
-            break;
-          case 403:
-            throw new UG_403_Forbidden($description, $meta['http_code']);
-            break;
-          case 404:
-            throw new UG_404_NotFound($description, $meta['http_code']);
-            break;
-          case 500:
-            throw new UG_500_ServerError($description, $meta['http_code']);
-            break;
-          default:
-            throw new UGException($description, $meta['http_code']);
-            break;
-        }
-      }
-
-    }
-    else {
-      $response_obj->set_error(FALSE);
-      $response_obj->set_error_message(FALSE);
-    }
-
-    return $response_obj;
-  }
-
-  /**
-   * Performs an HTTP GET operation
-   *
-   * @param string $endpoint
-   * @param array $query_string_array
-   * @return Response
-   */
-  public function get($endpoint, $query_string_array) {
-
-    $request = new Request();
-    $request->set_method('GET');
-    $request->set_endpoint($endpoint);
-    $request->set_query_string_array($query_string_array);
-
-    $response = $this->request($request);
-
-    return $response;
-  }
-
-  /**
-   * Performs an HTTP POST operation
-   *
-   * @param string $endpoint
-   * @param array $query_string_array
-   * @param array $body
-   * @return Response
-   */
-  public function post($endpoint, $query_string_array, $body) {
-
-    $request = new Request();
-    $request->set_method('POST');
-    $request->set_endpoint($endpoint);
-    $request->set_query_string_array($query_string_array);
-    $request->set_body($body);
-
-    $response = $this->request($request);
-
-    return $response;
-  }
-
-  /**
-   * Performs an HTTP PUT operation
-   *
-   * @param string $endpoint
-   * @param array $query_string_array
-   * @param array $body
-   * @return Response
-   */
-  public function put($endpoint, $query_string_array, $body) {
-
-    $request = new Request();
-    $request->set_method('PUT');
-    $request->set_endpoint($endpoint);
-    $request->set_query_string_array($query_string_array);
-    $request->set_body($body);
-
-    $response = $this->request($request);
-
-    return $response;
-  }
-
-  /**
-   * Performs an HTTP DELETE operation
-   *
-   * @param string $endpoint
-   * @param array $query_string_array
-   * @return Response
-   */
-  public function delete($endpoint, $query_string_array) {
-    $request = new Request();
-    $request->set_method('DELETE');
-    $request->set_endpoint($endpoint);
-    $request->set_query_string_array($query_string_array);
-
-    $response = $this->request($request);
-
-    return $response;
-  }
-
-  /**
-   * Creates an entity. If no error occurred, the entity may be accessed in the
-   * returned object's ->parsed_objects['entity'] member.
-   *
-   * @param array $entity_data
-   * @return \Apache\Usergrid\Entity
-   */
-  public function create_entity($entity_data) {
-    $entity = new Entity($this, $entity_data);
-    $response = $entity->fetch();
-
-    $ok_to_save = (
-      ($response->get_error() && ('service_resource_not_found' == $response->get_error_code() || 'no_name_specified' == $response->get_error_code() || 'null_pointer' == $response->get_error_code() ))
-      ||
-      (!$response->get_error() && array_key_exists('getOnExist', $entity_data) && $entity_data['getOnExist'])
-    );
-
-    if ($ok_to_save) {
-      $entity->set($entity_data);
-      $response = $entity->save();
-      if ($response->get_error()) {
-        $this->write_log('Could not create entity.');
-        return FALSE;
-      }
-    }
-    elseif ($response->get_error() || array_key_exists('error', $response->get_data())) {
-      return FALSE;
-    }
-    return $entity;
-  }
-
-  /**
-   * Fetches and returns an entity.
-   *
-   * @param $entity_data
-   * @return \Apache\Usergrid\Entity|bool
-   */
-  public function get_entity($entity_data) {
-    $entity = new Entity($this, $entity_data);
-    $response = $entity->fetch();
-    if ($response->get_error()) {
-      $this->write_log($response->get_error_message());
-      return FALSE;
-    }
-    return $entity;
-  }
-
-  /**
-   * Fetches and returns a collection. If the collection does not yet exist,
-   * it is created.
-   *
-   * @param string $type
-   * @param array $qs
-   * @return \Apache\Usergrid\Collection
-   */
-  public function get_collection($type, $qs = array()) {
-    $collection = new Collection($this, $type, $qs);
-    return $collection;
-  }
-
-  /**
-   * Creates and returns a user-activity entity. Returns FALSE if such an
-   * entity could not be created.
-   *
-   * @param string $user_identifier
-   * @param array $user_data
-   * @return \Apache\Usergrid\Entity|bool
-   */
-  public function create_user_activity($user_identifier, $user_data) {
-    $user_data['type'] = "users/$user_identifier/activities";
-    $entity = new Entity($this, $user_data);
-    $response = $entity->save();
-    return ($response->get_error() ? FALSE : $entity);
-  }
-
-  /**
-   * Attempts a login. If successful, sets the OAuth token to be used for
-   * subsequent calls, and returns a User entity. If unsuccessful, returns
-   * FALSE.
-   *
-   * @param string $username
-   * @param string $password
-   * @return \Apache\Usergrid\Entity|bool
-   */
-  public function login($username, $password) {
-    $body = array(
-      'username' => $username,
-      'password' => $password,
-      'grant_type' => 'password'
-    );
-    $response = $this->POST('token', array(), $body);
-    if ($response->get_error()) {
-      $user = NULL;
-      $error = 'Error trying to log user in.';
-      $this->write_log($error);
-      if (!$response->get_error()) {
-        $response->set_error(TRUE);
-        $response->set_error_message($error);
-        $response->set_error_code($error);
-      }
-    }
-    else {
-      $response_data = $response->get_data();
-      $user = new Entity($this, $response_data['user']);
-      $this->set_oauth_token($response_data['access_token']);
-    }
-    return ($user && !$response->get_error() ? $user : FALSE);
-  }
-
-  /**
-   * Not yet implemented. Logs in via Facebook.
-   *
-   * @param $fb_token
-   */
-  public function login_facebook($fb_token) {
-    // TODO
-  }
-
-  /**
-   * A public facing helper method for signing up users
-   *
-   * @params string $username
-   * @params string $password
-   * @params string $email
-   * @params string $name
-   * @return \Apache\Usergrid\Entity
-   */
-  public function signup($username, $password, $email, $name) {
-    $data = array(
-      'type' => 'users',
-      'username' => $username,
-      'password' => $password,
-      'email' => $email,
-      'name' => $name
-    );
-    return $this->create_entity($data);
-  }
-
-  /**
-   * Returns current user as an entity. If no user is logged in,
-   * returns FALSE.
-   *
-   * @return Entity|bool
-   */
-  public function get_logged_in_user() {
-    $data = array('username' => 'me', 'type' => 'users');
-    return $this->get_entity($data);
-  }
-
-  /**
-   * Determines if a user is logged in.
-   *
-   * @return bool
-   */
-  public function is_logged_in() {
-    return !empty($this->oauth_token);
-  }
-
-  /**
-   * Logs current user out.
-   * @todo: Invoke logout callback.
-   */
-  public function log_out() {
-    $this->oauth_token = NULL;
-  }
-
-  /**
-   * Determines if a string is a valid UUID. Note that this function will
-   * return FALSE if the UUID is wrapped in curly-braces, Microsoft-style.
-   *
-   * @param $uuid
-   * @return bool
-   */
-  public static function is_uuid($uuid) {
-    static $regex = '/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i';
-    if (empty($uuid)) {
-      return FALSE;
-    }
-    return (bool) preg_match($regex, $uuid);
-  }
-
-  // TODO: Document the following methods
-
-  public function createNewNotifierApple($name, $environment, $p12Certificate_path) {
-
-    $endpoint = "notifiers";
-    $data = array(
-      "name" => $name,
-      "environment" => $environment,
-      "p12Certificate" => $p12Certificate_path,
-      "provider" => "apple"
-    );
-    return $this->post($endpoint, array(), $data);
-  }
-
-  public function createNewNotifierAndroid($name, $apiKey) {
-    $endpoint = "notifiers";
-    $data = array(
-      "name" => $name,
-      "apiKey" => $apiKey,
-      "provider" => "google"
-    );
-    return $this->post($endpoint, array(), $data);
-  }
-
-  public function createNotification() {
-    return new Notification();
-  }
-
-  public function scheduleNotification(Notification $notification) {
-    $notifier_name = $notification->get_notifier_name();
-    $message = $notification->get_message();
-    $delivery_time = $notification->get_delivery_time();
-    $recipients_list = $notification->get_recipients_list();
-    $recipient_type = $notification->get_recipient_type();
-
-    //we are trying to make this (where notifierName is the name of the notifier:
-    // { "payloads": { notifierName: "msg" }, "deliver":timestamp }
-    $body = array('payloads' => array($notifier_name => $message, 'deliver' => $delivery_time));
-
-    switch ($recipient_type) {
-      case GROUPS:
-        $type = 'groups/';
-        break;
-      case USERS:
-        $type = 'users/';
-        break;
-      case DEVICES:
-        $type = 'devices/';
-        break;
-      default:
-        $type = 'devices/';
-        $recipients_list = array(';ql=');
-    }
-
-    //schedule notification
-    if (count($recipients_list) > 0) {
-      foreach ($recipients_list as $recipient) {
-        $endpoint = $type . $recipient . '/notifications';
-        $result = $this->post($endpoint, array(), $body);
-        if ($result->get_error()) {
-          $notification->log_error($result->get_error());
-        }
-      }
-    }
-    return $notification;
-  }
-
-    /**
-     * Gets URL of Usergrid endpoint
-     *
-     * @return string
-     */
-    public function getUrl()
-    {
-        return $this->url;
-    }
-
-    /**
-     * Sets Usergrid endpoint URL
-     *
-     * @param string $url
-     * @return bool
-     * @throws UGException
-     */
-    public function setUrl($url)
-    {
-        if (filter_var($url, FILTER_VALIDATE_URL) !== false) {
-            $this->url = $url;
-            return true;
-        }
-        else {
-            if ($this->use_exceptions) {
-                throw new UGException('Invalid URL');
-            }
-        }
-    }
-
-}
-
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Collection.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Collection.php b/sdks/php/lib/vendor/Apache/Usergrid/Collection.php
deleted file mode 100644
index ee8a070..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Collection.php
+++ /dev/null
@@ -1,313 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Allows CRUD operations on Usergrid Collections.
- *
- * @author Daniel Johnson <dj...@apigee.com>
- * @author Rod Simpson <ro...@apigee.com>
- * @since 26-Apr-2013
- */
-
-namespace Apache\Usergrid;
-require_once(dirname(__FILE__) . '/Exceptions.php');
-
-class Collection {
-
-  /**
-   * @var \Apache\Usergrid\Client
-   */
-  private $client;
-  /**
-   * @var string
-   */
-  private $type;
-  /**
-   * @var array
-   */
-  private $qs;
-  /**
-   * @var array
-   */
-  private $list;
-  /**
-   * @var int
-   */
-  private $iterator;
-  /**
-   * @var array
-   */
-  private $previous;
-  /**
-   * @var bool|int
-   */
-  private $next;
-  /**
-   * @var null|int
-   */
-  private $cursor;
-
-  /**
-   * @var string|string
-   */
-  private $json = '';
-
-  /**
-   * Object constructor.
-   *
-   * @param \Apache\Usergrid\Client $client
-   * @param string $type
-   * @param array $qs
-   */
-  public function __construct(Client $client, $type, $qs = array()) {
-    $this->client = $client;
-    $this->type = $type;
-    $this->qs = $qs;
-
-    $this->list = array();
-    $this->iterator = -1;
-
-    $this->previous = array();
-    $this->next = FALSE;
-    $this->cursor = NULL;
-
-    $this->fetch();
-  }
-
-  public function get_json() {
-    return $this->json;
-  }
-
-  public function set_json($json) {
-    $this->json = $json;
-  }
-
-  /**
-   * @return string
-   */
-  public function get_type() {
-    return $this->type;
-  }
-
-  /**
-   * @param string $type
-   */
-  public function set_type($type) {
-    $this->type = $type;
-  }
-
-  /**
-   * @return \Apache\Usergrid\Response
-   */
-  public function fetch() {
-    if ($this->cursor) {
-      $this->qs['cursor'] = $this->cursor;
-    }
-    elseif (array_key_exists('cursor', $this->qs)) {
-      unset($this->qs['cursor']);
-    }
-    $response = $this->client->get($this->type, $this->qs);
-    if ($response->get_error()) {
-      $this->client->write_log('Error getting collection.');
-    }
-    else {
-      $this->set_json($response->get_json());
-      $response_data = $response->get_data();
-      $cursor = (isset($response_data['cursor']) ? $response_data['cursor'] : NULL);
-      $this->save_cursor($cursor);
-      if (!empty($response_data['entities'])) {
-        $this->reset_entity_pointer();
-        $count = count($response_data['entities']);
-        $this->list = array();
-        for ($i = 0; $i < $count; $i++) {
-          $entity_data = $response_data['entities'][$i];
-          if (array_key_exists('uuid', $entity_data)) {
-            $entity = new Entity($this->client, $entity_data);
-            $entity->set('type', $this->type);
-
-            $this->list[] = $entity;
-          }
-        }
-      }
-    }
-    return $response;
-  }
-
-  /**
-   * @param array $entity_data
-   * @return \Apache\Usergrid\Entity
-   */
-  public function add_entity($entity_data) {
-    $entity = $this->client->create_entity($entity_data);
-    if ($entity) {
-      $this->list[] = $entity;
-    }
-    return $entity;
-  }
-
-  /**
-   * @param \Apache\Usergrid\Entity $entity
-   * @return \Apache\Usergrid\Response
-   */
-  public function destroy_entity(Entity $entity) {
-    $response = $entity->destroy();
-    if ($response->get_error()) {
-      $this->client->write_log('Could not destroy entity.');
-    }
-    else {
-      $response = $this->fetch();
-    }
-    return $response;
-  }
-
-  /**
-   * @param string $uuid
-   * @return \Apache\Usergrid\Response|bool
-   * @throws \Apache\Usergrid\UGException
-   */
-  public function get_entity_by_uuid($uuid) {
-    if (!Client::is_uuid($uuid)) {
-      if ($this->client->are_exceptions_enabled()) {
-        throw new UGException("Invalid UUID $uuid");
-      }
-      return FALSE;
-    }
-    $entity = new Entity($this->client, array('type' => $this->type, 'uuid' => $uuid));
-    return $entity->fetch();
-  }
-
-  /**
-   * @return \Apache\Usergrid\Entity|null
-   */
-  public function get_first_entity() {
-    return (count($this->list) > 0 ? $this->list[0] : NULL);
-  }
-
-  /**
-   * @return \Apache\Usergrid\Entity|null
-   */
-  public function get_last_entity() {
-    return (count($this->list) > 0 ? $this->list[count($this->list) - 1] : NULL);
-  }
-
-  /**
-   * @return bool
-   */
-  public function has_next_entity() {
-    $next = $this->iterator + 1;
-    return ($next >= 0 && $next < count($this->list));
-  }
-
-  /**
-   * @return bool
-   */
-  public function has_prev_entity() {
-    $prev = $this->iterator - 1;
-    return ($prev >= 0 && $prev < count($this->list));
-  }
-
-  /**
-   * @return \Apache\Usergrid\Entity|null
-   */
-  public function get_next_entity() {
-    if ($this->has_next_entity()) {
-      $this->iterator++;
-      return $this->list[$this->iterator];
-    }
-    return NULL;
-  }
-
-  /**
-   * @return \Apache\Usergrid\Entity|null
-   */
-  public function get_prev_entity() {
-    if ($this->has_prev_entity()) {
-      $this->iterator--;
-      return $this->list[$this->iterator];
-    }
-    return NULL;
-  }
-
-  public function reset_entity_pointer() {
-    $this->iterator = -1;
-  }
-
-  public function save_cursor($cursor) {
-    $this->next = $cursor;
-  }
-
-  public function reset_paging() {
-    $this->previous = array();
-    $this->next = FALSE;
-    $this->cursor = NULL;
-  }
-
-  public function has_next_page() {
-    return (bool) $this->next;
-  }
-
-  public function has_prev_page() {
-    return (count($this->previous) > 0);
-  }
-
-  /**
-   * @return \Apache\Usergrid\Response|bool
-   */
-  public function get_next_page() {
-    if ($this->has_next_page()) {
-      array_push($this->previous, $this->cursor);
-      $this->cursor = $this->next;
-      $this->list = array();
-      return $this->fetch();
-    }
-    return FALSE;
-  }
-
-  /**
-   * @return \Apache\Usergrid\Response|bool
-   */
-  public function get_prev_page() {
-    if ($this->has_prev_page()) {
-      $this->next = FALSE;
-      $this->cursor = array_pop($this->previous);
-      $this->list = array();
-      return $this->fetch();
-    }
-    return FALSE;
-  }
-  public function serialize(){
-    $data = array();
-    $data->type = $this->type;
-    $data->qs = $this->qs;
-    $data->iterator = $this->iterator;
-    $data->previous = $this->previous;
-    $data->next = $this->next;
-    $data->cursor = $this->cursor;
-    $data->list = array();
-    $this->reset_entity_pointer();
-    while ($this->has_next_entity()) {
-        $entity = $this->get_next_entity();
-        array_push($data->list, $entity->get_json());
-    }
-    return json_encode($data);
-  }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Entity.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Entity.php b/sdks/php/lib/vendor/Apache/Usergrid/Entity.php
deleted file mode 100755
index ccb9377..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Entity.php
+++ /dev/null
@@ -1,320 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Allows CRUD operations on Usergrid Entities, including Users.
- *
- * @author Daniel Johnson <dj...@apigee.com>
- * @author Rod Simpson <ro...@apigee.com>
- * @since 26-Apr-2013
- */
-
-namespace Apache\Usergrid;
-
-class Entity {
-
-  private $client;
-  private $data;
-  private $json;
-
-  public function __construct(Client $client, $data = array(), $json_data='') {
-    $this->client = $client;
-    $this->data = $data;
-    $this->json_data = $json_data;
-  }
-
-  public function get_json() {
-    return $this->json;
-  }
-
-  public function set_json($json) {
-    $this->json = $json;
-  }
-
-  public function get($field = NULL) {
-    if (!empty($field)) {
-      return (isset($this->data[$field]) ? $this->data[$field] : NULL);
-    }
-    return $this->data;
-  }
-
-  public function set($key, $value = NULL) {
-    if (is_array($key)) {
-      foreach ($key as $field => $value) {
-        $this->data[$field] = $value;
-      }
-    }
-    elseif (is_string($key)) {
-      if (!isset($value)) {
-        if (isset($this->data[$key])) {
-          unset($this->data[$key]);
-        }
-      }
-      else {
-        $this->data[$key] = $value;
-      }
-    }
-    else {
-      $this->data = array();
-    }
-  }
-
-  public function save() {
-    $type = $this->get('type');
-    $method = 'POST';
-    $uuid = $this->get('uuid');
-    if (isset($uuid) && Client::is_uuid($uuid)) {
-      $method = 'PUT';
-      $type .= "/$uuid";
-    }
-    $data = array();
-    $entity_data = $this->get();
-    foreach ($entity_data as $key => $val) {
-      switch ($key) {
-        case 'metadata':
-        case 'created':
-        case 'modified':
-        case 'type':
-        case 'activated':
-        case 'uuid':
-          continue;
-          break;
-        default:
-          $data[$key] = $val;
-      }
-    }
-
-    if ($method == 'PUT') {
-      $response = $this->client->put($type, array(), $data);
-    }
-    else {
-      $response = $this->client->post($type, array(), $data);
-    }
-
-    $this->set_json($response->get_json());
-
-    if ($response->get_error()) {
-      $this->client->write_log('Could not save entity.');
-    }
-    else {
-      $response_data = $response->get_data();
-      if (!empty($response_data['entities'])) {
-        $this->set($response_data['entities'][0]);
-      }
-      $need_password_change = (
-        ($this->get('type') == 'user' || $this->get('type') == 'users')
-        && !empty($entity_data['oldpassword'])
-        && !empty($entity_data['newpassword'])
-      );
-      if ($need_password_change) {
-        $pw_data = array(
-          'oldpassword' => $entity_data['oldpassword'],
-          'newpassword' => $entity_data['newpassword']
-        );
-        $response = $this->client->PUT("$type/password", array(), $pw_data);
-        if ($response->get_error()) {
-          $this->client->write_log('Could not update user\'s password.');
-        }
-        $this->set('oldpassword', NULL);
-        $this->set('newpassword', NULL);
-      }
-    }
-    return $response;
-  }
-
-  public function fetch() {
-    $response = new Response();
-    $type = $this->get('type');
-    $uuid = $this->get('uuid'); // may be NULL
-    if (!empty($uuid)) {
-      $type .= "/$uuid";
-    }
-    else {
-      if ($type == 'user' || $type == 'users') {
-        $username = $this->get('username');
-        if (!empty($username)) {
-          $type .= "/$username";
-        }
-        else {
-          $error = 'no_name_specified';
-          $this->client->write_log($error);
-          $response->set_error($error);
-          $response->set_error_code($error);
-          return $response;
-        }
-      }
-      else {
-        $name = $this->get('name');
-        if (!empty($name)) {
-          $type .= "/$name";
-        }
-        else {
-          $error = 'no_name_specified';
-          $this->client->write_log($error);
-          $response->set_error($error);
-          $response->set_error_code($error);
-          return $response;
-        }
-      }
-    }
-    $response = $this->client->get($type, array());
-    $this->set_json($response->get_json());
-    if ($response->get_error()) {
-      $this->client->write_log('Could not get entity.');
-    }
-    else {
-      $data = $response->get_data();
-      if (isset($data['user'])) {
-        $this->set($data['user']);
-      }
-      elseif (!empty($data['entities'])) {
-        $this->set($data['entities'][0]);
-      }
-    }
-    return $response;
-  }
-
-  public function destroy() {
-    $response = new Response();
-    $type = $this->get('type');
-    $uuid = $this->get('uuid');
-    if (Client::is_uuid($uuid)) {
-      $type .= "/$uuid";
-    }
-    else {
-      $error = 'Error trying to delete object: No UUID specified.';
-      $this->client->write_log($error);
-      $response->set_error($error);
-      $response->set_error_code($error);
-      return $response;
-    }
-
-    $response = $this->client->delete($type, array());
-    $this->set_json($response->get_json());
-    if ($response->get_error()) {
-      $this->client->write_log('Entity could not be deleted.');
-    }
-    else {
-      $this->set(NULL);
-    }
-    return $response;
-  }
-
-  public function connect($connection, $entity) {
-    $connectee=Entity::get_entity_id($entity);
-    $connecteeType=$entity->get("type");
-    if(!$connectee){
-      return "Error in connect. No UUID specified for connectee";
-    }
-
-    $connector=Entity::get_entity_id($this);
-    $connectorType=$this->get("type");
-    if(!$connector){
-      return "Error in connect. No UUID specified for connector";
-    }
-
-    $endpoint = $connectorType.'/'.$connector.'/'.$connection.'/'.$connecteeType.'/'.$connectee;
-    $result=$this->client->post($endpoint, array(), array());
-    $error=$result->get_error();
-    if($error){
-      return $result->get_error_message();
-    }else{
-      return $result->get_data();
-    }
-  }
-
-  public function disconnect($connection, $entity) {
-    $connectee=Entity::get_entity_id($entity);
-    $connecteeType=$entity->get("type");
-    if(!$connectee){
-      return "Error in disconnect. No UUID specified for connectee";
-    }
-
-    $connector=Entity::get_entity_id($this);
-    $connectorType=$this->get("type");
-    if(!$connector){
-      return "Error in disconnect. No UUID specified for connector";
-    }
-
-    $endpoint = $connectorType.'/'.$connector.'/'.$connection.'/'.$connecteeType.'/'.$connectee;
-
-    $result=$this->client->delete($endpoint, array(), array());
-    $error=$result->get_error();
-    if($error){
-      return $result->get_error_message();
-    }else{
-      return $result->get_data();
-    }
-  }
-
-  public static function get_entity_id($entity) {
-      $id = false;
-      if (Client::is_uuid($entity->get('uuid'))) {
-        $id = $entity->get('uuid');
-      } else {
-        if ($type == 'users') {
-          $id = $entity->get('username');
-        } else if ($entity->get('name')) {
-          $id = $entity->get('name');
-        }
-      }
-      return $id;
-  }
-
-  public function get_connections($connection) {
-    $connectorType = $this->get('type');
-    $connector = Entity::get_entity_id($this);
-    if (!$connector) {
-      return;
-    }
-
-    $endpoint = $connectorType . '/' . $connector . '/' . $connection . '/';
-    $result=$this->client->get($endpoint, array());
-
-    $connected_entities = array();
-
-    $response_data = $result->get_data();
-    $length        = count($response_data['entities']);
-    
-    for ($i = 0; $i < $length; $i++) {
-      $tmp_entity = $response_data['entities'][$i];
-      if ($tmp_entity['type'] == 'user') {
-          $connected_entities[$tmp_entity['username']] = $tmp_entity;
-      } else {
-          $connected_entities[$tmp_entity['name']]     = $tmp_entity;
-      }
-    }
-    $this->set($connection, $connected_entities);
-  }
-
-  public function get_connecting($connection) {
-    $connectorType = $this->get('type');
-    $connector = Entity::get_entity_id($this);
-    if (!$connector) {
-      return;
-    }
-
-    $endpoint = $connectorType. '/' . $connector . '/connecting/' . $connection . '/';
-    $result=$this->client->get($endpoint, array());
-    return $result->get_data();
-  }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Exceptions.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Exceptions.php b/sdks/php/lib/vendor/Apache/Usergrid/Exceptions.php
deleted file mode 100755
index 706e9e5..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Exceptions.php
+++ /dev/null
@@ -1,41 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
-* @file
-* Request - a data structure to hold all request-related parameters
-*
-* @author Daniel Johnson <dj...@apigee.com>
-* @author Rod Simpson <ro...@apigee.com>
-* @since 26-Apr-2013
-*/
-
-
-namespace Apache\Usergrid;
-
-
-class UGException extends \Exception { }
-class UG_400_BadRequest extends UGException {}
-class UG_401_Unauthorized extends UGException {}
-class UG_403_Forbidden extends UGException {}
-class UG_404_NotFound extends UGException {}
-class UG_500_ServerError extends UGException {}
-
-?>


[14/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/collection.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/collection.rb b/sdks/other/ruby/lib/usergrid/core/collection.rb
new file mode 100644
index 0000000..02ac9fd
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/collection.rb
@@ -0,0 +1,121 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+module Usergrid
+  class Collection < Entity
+    include Enumerable
+
+    attr_accessor :iterator_follows_cursor
+
+    def initialize(url, api_url, options={}, response=nil)
+      super url, api_url, options, response
+      @iterator_follows_cursor = false
+    end
+
+    def collection
+      self
+    end
+
+    def entities
+      get unless response
+      response.entities
+    end
+
+    def [](k)
+      entities[k]
+    end
+
+    def []=(k,v)
+      raise "unsupported operation"
+    end
+
+    # does not save entities! just fields (eg. 'name')
+    def save
+      super save
+    end
+
+    def each(&block)
+      entities.each &block
+      while cursor
+        next_page
+        entities.each &block
+      end if iterator_follows_cursor
+    end
+
+    # use in conjunction with each() like: collection.follow_cursor.each {|e| }
+    def follow_cursor
+      my_clone = self.clone
+      my_clone.iterator_follows_cursor = true
+      my_clone
+    end
+
+    def create_entity(data)
+      self.post data
+    end
+    alias_method :create_entities, :create_entity
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def update_query(updates, query=nil, options={})
+      options = options.symbolize_keys
+      query_params = query ? options.merge({ql: query}) : options
+      self.put(updates, {params: query_params })
+      self
+    end
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def delete_query(query=nil, options={})
+      options = options.symbolize_keys
+      query_params = query ? options.merge({ql: query}) : options
+      self.delete({params: query_params })
+      self
+    end
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def query(query=nil, options={})
+      options = options.symbolize_keys
+      query_params = query ? options.merge({ql: query}) : options
+      self.get({params: query_params })
+      self
+    end
+
+    def size
+      entities.size
+    end
+
+    def empty?
+      entities.empty?
+    end
+
+    def cursor
+      response.data['cursor']
+    end
+
+    def next_page
+      query(nil, query_params.merge({cursor: cursor}))
+    end
+
+    protected
+
+    def query_params
+      params = {}
+      if response.data['params']
+        response.data['params'].each do |k,v|
+          params[k] = v[0]
+        end
+      end
+      params
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/entity.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/entity.rb b/sdks/other/ruby/lib/usergrid/core/entity.rb
new file mode 100644
index 0000000..1539b58
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/entity.rb
@@ -0,0 +1,80 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+# also allows hash or dot notation for entity properties
+module Usergrid
+  class Entity < Resource
+
+    def initialize(url, api_url, options={}, response=nil, index=nil)
+      super url, api_url, options, response
+      @index = index
+    end
+
+    def data
+      get unless response
+      @index ? response.entities_data[@index] : response.entity_data
+    end
+
+    def data?
+      !!response
+    end
+
+    def resource
+      Resource.new url, api_url, options
+    end
+
+    def [](k)
+      data[k]
+    end
+
+    def []=(k,v)
+      data[k] = v
+    end
+
+    def collection
+      Collection.new url[0..url[0..-2].rindex('/')-1], api_url, options
+    end
+
+    def save
+      self.put data
+    end
+
+    def to_s
+      "resource: #{url}\ndata: #{data}"
+    end
+
+    def to_json(*args)
+      data.except(RESERVED).to_json *args
+    end
+    alias :encode :to_json
+    alias :dump :to_json
+
+    private
+
+    def method_missing(method, *args, &block)
+      if data.respond_to?(method)
+        data.send(method, *args, &block)
+      elsif method[-1] == '=' && args.size == 1
+        data[method[0..-2]] = args[0]
+      else
+        super method, args, block
+      end
+    end
+
+    def respond_to?(method)
+      super.respond_to?(method) || data.respond_to?(method)
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/management.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/management.rb b/sdks/other/ruby/lib/usergrid/core/management.rb
new file mode 100644
index 0000000..b8f3e06
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/management.rb
@@ -0,0 +1,57 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+module Usergrid
+  class Management < Resource
+
+    def initialize(url, options={})
+      management = url.split('/')[-1]
+      if management == 'management'
+        api_url = url[0..url.index(management)-2]
+      else
+        api_url = url
+        url = concat_urls(api_url, 'management')
+      end
+      super url, api_url, options
+    end
+
+    def create_organization(organization, username, name, email, password)
+      data = { organization: organization,
+               username: username,
+               name: name,
+               email: email,
+               password: password }
+      self['organizations'].post data
+    end
+
+    def organizations
+      self[__method__].get
+    end
+
+    def organization(organization)
+      url = self["organizations/#{organization}"].url
+      Organization.new url, options
+    end
+
+    def users
+      self['users'].get
+    end
+
+    def user(name_or_uuid)
+      self["users/#{name_or_uuid}"].get
+    end
+
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/organization.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/organization.rb b/sdks/other/ruby/lib/usergrid/core/organization.rb
new file mode 100644
index 0000000..9df485a
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/organization.rb
@@ -0,0 +1,74 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'uri'
+module Usergrid
+  class Organization < Resource
+
+    def initialize(url, options={})
+      org_name = url.split('/')[-1]
+      api_url = url[0..url.index('management')-2]
+      super url, api_url, options
+    end
+
+    def name
+      URI(url).path.split('/').last
+    end
+
+    def create_application(name)
+      self['applications'].post({ name: name })
+      application name
+    end
+
+    def applications(query=nil)
+      resource = self[__method__]
+      response = query ? resource.query(query) : resource.get
+      response.data['data'].collect do |k|
+        application concat_urls(api_url, k)
+      end
+    end
+
+    def application(name_or_uuid)
+      Usergrid::Application.new concat_urls(api_url, "#{name}/#{name_or_uuid}"), options
+    end
+
+    def users(query=nil)
+      self[__method__].query(query)
+    end
+
+    def user(user)
+      management.user(user)
+    end
+
+    def feed(query=nil)
+      self[__method__].query(query)
+    end
+
+    def credentials
+      self[__method__].get
+    end
+
+    def generate_credentials
+      self['credentials'].post nil
+    end
+
+    def login_credentials(client_id, client_secret)
+      resource = api_resource 'management'
+      response = resource['token'].post grant_type: 'client_credentials', client_id: client_id, client_secret: client_secret
+      self.auth_token = response.data['access_token']
+    end
+
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/core/resource.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/core/resource.rb b/sdks/other/ruby/lib/usergrid/core/resource.rb
new file mode 100644
index 0000000..1f96f90
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/core/resource.rb
@@ -0,0 +1,157 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'rest_client'
+
+module Usergrid
+  class Resource < RestClient::Resource
+
+    RESERVED = %w( created modified metadata uri )
+    DEFAULT_API_URL = 'https://api.usergrid.com'
+    TYPE_HEADERS = { content_type: :json, accept: :json }
+
+    attr_reader :current_user, :api_url, :response
+
+    def initialize(resource_url=DEFAULT_API_URL, api_url=nil, options={}, response=nil)
+      options[:headers] = TYPE_HEADERS.merge options[:headers] || {}
+      @api_url = api_url || resource_url
+      self.response = response
+      super resource_url, options, &method(:handle_response)
+    end
+
+    # gets user token and automatically set auth header for future requests
+    # precondition: resource must already be set to the correct context (application or management)
+    def login(username, password)
+      response = self['token'].post grant_type: 'password', username: username, password: password
+      self.auth_token = response.data['access_token']
+      user_uuid = response.data['user']['uuid']
+      @current_user = self["/users/#{user_uuid}"].get.entity
+      response
+    end
+
+    # remove auth header for future requests
+    # only affects self and derivative resources
+    def logout
+      self.auth_token = nil
+      @current_user = nil
+    end
+
+    def logged_in?
+      !!auth_token
+    end
+
+    def management
+      Usergrid::Management.new api_url, options
+    end
+
+    # application defaults to sandbox if none provided
+    def application(organization, application='sandbox')
+      Usergrid::Application.new concat_urls(api_url, "#{organization}/#{application}"), options
+    end
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def query(query=nil, options={})
+      options = options.merge({ql: query}) if query
+      get({params: options})
+    end
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def update_query(updates, query=nil, options={})
+      options = options.merge({ql: query}) if query
+      put(updates, {params: options})
+    end
+
+    # options: 'reversed', 'start', 'cursor', 'limit', 'permission'
+    def delete_query(query=nil, options={})
+      options = options.merge({ql: query}) if query
+      delete({params: options})
+    end
+
+    def entity
+      get unless response
+      response.entity
+    end
+
+    def entities
+      get unless response
+      response.entities
+    end
+
+    def collection
+      get unless response
+      Collection.new url, api_url, options, response
+    end
+
+    # overridden to ensure sub resources are instances of this class
+    def [](suburl, &new_block)
+      case
+        when block_given? then Resource.new(concat_urls(url, suburl), api_url, options, &new_block)
+        when block        then Resource.new(concat_urls(url, suburl), api_url, options, &block)
+        else
+          Resource.new(concat_urls(url, suburl), api_url, options)
+      end
+    end
+
+    def api_resource(suburl)
+      Resource.new(concat_urls(api_url, suburl), api_url, options)
+    end
+
+    def get(additional_headers={}, &block)
+      self.response = super additional_headers, &block
+    end
+
+    def post(payload, additional_headers={}, &block)
+      payload = MultiJson.dump(payload) unless payload.is_a? String
+      self.response = super payload, additional_headers, &block
+    end
+
+    def put(payload, additional_headers={}, &block)
+      payload = MultiJson.dump(payload) unless payload.is_a? String
+      self.response = super payload, additional_headers, &block
+    end
+
+    def auth_token=(auth_token)
+      if auth_token
+        @options[:headers].merge!({ Authorization: "Bearer #{auth_token}" })
+      else
+        @options[:headers].delete :Authorization if @options
+      end
+    end
+
+    def auth_token
+      begin
+        @options[:headers][:Authorization].gsub 'Bearer ', ''
+      rescue
+        nil
+      end
+    end
+
+    protected
+
+    def response=(response)
+      @response = response
+    end
+
+    # add verbose debugging of response body
+    def handle_response(response, request, result, &block)
+      LOG.debug "response.body = #{response}"
+      response = response.return!(request, result, &block)
+      response.resource = self
+      self.response = response
+      response
+    end
+
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/extensions/hash.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/extensions/hash.rb b/sdks/other/ruby/lib/usergrid/extensions/hash.rb
new file mode 100644
index 0000000..5a1cd30
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/extensions/hash.rb
@@ -0,0 +1,45 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+class Hash
+
+  # not recursive
+  def symbolize_keys
+    inject({}) do |options, (key, value)|
+      options[(key.to_sym rescue key) || key] = value
+      options
+    end
+  end
+
+  def except(*keys)
+    dup.except! *keys
+  end
+
+  def except!(*keys)
+    keys.each { |key| key.is_a?(Array) ? except!(*key) : delete(key) }
+    self
+  end
+
+  # recursive
+  def add_dot_notation!(_hash=self)
+    _hash.each do |k,v|
+      getter = k.to_sym; setter = "#{k}=".to_sym
+      _hash.define_singleton_method getter, lambda { _hash[k] } unless _hash.respond_to? getter
+      _hash.define_singleton_method setter, lambda { |v| _hash[k] = v } unless _hash.respond_to? setter
+      add_dot_notation!(v) if v.is_a? Hash
+      v.each { |e| add_dot_notation!(e) if e.is_a? Hash } if v.is_a? Array
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/extensions/response.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/extensions/response.rb b/sdks/other/ruby/lib/usergrid/extensions/response.rb
new file mode 100644
index 0000000..ee2ffbf
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/extensions/response.rb
@@ -0,0 +1,96 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+module RestClient
+  module Response
+
+    def resource=(resource)
+      @resource = resource
+    end
+
+    def resource
+      @resource
+    end
+
+    def data
+      @data = MultiJson.load(self).add_dot_notation! unless @data
+      @data
+    end
+
+    def collection
+      resource.collection
+    end
+
+    def multiple_entities?
+      entities_data = data['entities'] || data['data'] || data['messages'] || data['list']
+      entities_data.is_a? Array
+    end
+
+    def entities_data
+      return @entities_data if @entities_data
+      entities_data = data['entities'] || data['data'] || data['messages'] || data['list']
+      raise "unable to determine entities from: #{data}" unless entities_data.is_a?(Array)
+      entities_data.each do |e|
+        e['uri'] = concat_urls(data['uri'], e['uuid']) if e.is_a?(Hash) && e['uuid']
+      end
+      @entities_data = entities_data
+    end
+
+    def entities
+      return @entities if @entities
+      index = -1
+      @entities = entities_data.collect do |e|
+        if e.is_a? Array
+          e
+        else
+          Usergrid::Entity.new e['uri'], resource.api_url, resource.options, self, index+=1
+        end
+      end
+    end
+
+    def entity_data
+      if multiple_entities?
+        entities_data.first
+      elsif data['data']
+        d = data['data']
+        d['uri'] = @resource.url
+        d
+      elsif data['organization']
+        d = data['organization']
+        d['uri'] = @resource.url
+        d
+      else
+        entities_data.first
+      end
+    end
+
+    def entity
+      Usergrid::Entity.new(entity_data['uri'], resource.api_url, resource.options, self) if entity_data
+    end
+
+    protected
+
+    def concat_urls(url, suburl) # :nodoc:
+      url = url.to_s
+      suburl = suburl.to_s
+      if url.slice(-1, 1) == '/' or suburl.slice(0, 1) == '/'
+        url + suburl
+      else
+        "#{url}/#{suburl}"
+      end
+    end
+
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid/version.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid/version.rb b/sdks/other/ruby/lib/usergrid/version.rb
new file mode 100644
index 0000000..951b017
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid/version.rb
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+module Usergrid
+  VERSION = '0.9.2'
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/lib/usergrid_iron.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/lib/usergrid_iron.rb b/sdks/other/ruby/lib/usergrid_iron.rb
new file mode 100644
index 0000000..7bd209c
--- /dev/null
+++ b/sdks/other/ruby/lib/usergrid_iron.rb
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'logger'
+require 'multi_json'
+
+
+module Usergrid
+
+  LOG = Logger.new(STDOUT)
+
+  USERGRID_PATH = File.join File.dirname(__FILE__), 'usergrid'
+
+  def self.usergrid_path *path
+    File.join USERGRID_PATH, *path
+  end
+
+  require usergrid_path('version')
+
+  require usergrid_path('extensions', 'hash')
+  require usergrid_path('extensions', 'response')
+
+  require usergrid_path('core', 'resource')
+  require usergrid_path('core', 'management')
+  require usergrid_path('core', 'organization')
+  require usergrid_path('core', 'application')
+  require usergrid_path('core', 'entity')
+  require usergrid_path('core', 'collection')
+
+  #autoload :Management, usergrid_path('core', 'management')
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/spec_helper.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/spec_helper.rb b/sdks/other/ruby/spec/spec_helper.rb
new file mode 100644
index 0000000..88f5b43
--- /dev/null
+++ b/sdks/other/ruby/spec/spec_helper.rb
@@ -0,0 +1,89 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require 'simplecov'
+
+require 'rspec'
+require 'yaml'
+require 'securerandom'
+require_relative '../lib/usergrid_iron'
+
+LOG = Logger.new(STDOUT)
+RestClient.log=LOG
+
+SimpleCov.at_exit do
+  SimpleCov.result.format!
+  #index = File.join(SimpleCov.coverage_path, 'index.html')
+  #`open #{index}` if File.exists?(index)
+end
+SimpleCov.start
+
+SPEC_SETTINGS = YAML::load_file(File.join File.dirname(__FILE__), 'spec_settings.yaml')
+
+def login_management
+  management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
+  management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
+  management
+end
+
+# ensure we are correctly setup (management login & organization)
+management = login_management
+
+begin
+  management.create_organization(SPEC_SETTINGS[:organization][:name],
+                                 SPEC_SETTINGS[:organization][:username],
+                                 SPEC_SETTINGS[:organization][:username],
+                                 "#{SPEC_SETTINGS[:organization][:username]}@email.com",
+                                 SPEC_SETTINGS[:organization][:password])
+  LOG.info "created organization with user #{SPEC_SETTINGS[:organization][:username]}@email.com"
+rescue
+  if MultiJson.load($!.response)['error'] == "duplicate_unique_property_exists"
+    LOG.debug "test organization exists"
+  else
+    raise $!
+  end
+end
+
+def create_random_application
+  management = login_management
+  organization = management.organization SPEC_SETTINGS[:organization][:name]
+
+  app_name = "_test_app_#{SecureRandom.hex}"
+  organization.create_application app_name
+  management.application SPEC_SETTINGS[:organization][:name], app_name
+end
+
+def delete_application(application)
+  management = login_management
+  application.auth_token = management.auth_token
+  # application.delete rescue nil  # not implemented on server yet
+end
+
+def create_random_user(application, login=false)
+  random = SecureRandom.hex
+  user_hash = {username: "username_#{random}",
+               password: random,
+               email:    "#{random}@email.com",
+               name:     "#{random} name" }
+  entity = application['users'].post(user_hash).entity
+  application.login user_hash[:username], user_hash[:password] if login
+  entity
+end
+
+RSpec.configure do |config|
+  config.filter_run focus: true
+  config.run_all_when_everything_filtered = true
+  config.treat_symbols_as_metadata_keys_with_true_values = true
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/spec_settings.yaml
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/spec_settings.yaml b/sdks/other/ruby/spec/spec_settings.yaml
new file mode 100644
index 0000000..7f82f40
--- /dev/null
+++ b/sdks/other/ruby/spec/spec_settings.yaml
@@ -0,0 +1,27 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+:api_url: http://localhost:8080
+:management:
+  :username: test
+  :password: test
+:organization:
+  :name: test-organization
+  :username: test
+  :password: test
+:application:
+  :name: test-app
+  :username: test-app-user
+  :password: test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/application_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/application_spec.rb b/sdks/other/ruby/spec/usergrid/core/application_spec.rb
new file mode 100644
index 0000000..f2b479e
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/application_spec.rb
@@ -0,0 +1,342 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Application do
+
+  before :all do
+    @application = create_random_application
+    @user = create_random_user @application, true
+  end
+
+  after :all do
+    @user.delete
+    delete_application @application
+  end
+
+  it "should be able to create a user using deprecated syntax" do
+    random = SecureRandom.hex
+    response = @application.create_user "username_#{random}", 'password'
+    response.entity.uuid.should_not be_nil
+  end
+
+  it "should be able to create, login, and delete a user" do
+    random = SecureRandom.hex
+    application = Usergrid::Application.new @application.url # create application resource that's not logged in
+    response = application.create_user username: "username_#{random}", password: 'password'
+    entity = response.entity
+    application.login "username_#{random}", 'password'
+    begin
+      response.code.should eq 200
+      response.entities.size.should eq 1
+      entity.uuid.should_not be_nil
+      response = application["users/#{entity.uuid}"].get
+      response.code.should eq 200
+    ensure
+      entity.delete
+      # deleted user shouldn't be able to access anything now
+      expect { application["users/#{entity.uuid}"].get }.to raise_error(RestClient::Unauthorized)
+      # use original application - logged in under existing user
+      expect { @application["users/#{entity.uuid}"].get }.to raise_error(RestClient::ResourceNotFound)
+    end
+  end
+
+  it "should be able to retrieve users" do
+    entity1 = create_random_user @application
+    entity2 = create_random_user @application
+    begin
+      response = @application.users
+      response.entities.size.should be >= 2
+      match1 = match2 = false
+      response.entities.each do |e|
+        match1 ||= e.username == entity1.username
+        match2 ||= e.username == entity2.username
+      end
+      match1.should be_true
+      match2.should be_true
+    ensure
+      entity1.delete
+      entity2.delete
+    end
+    response = @application.users
+    response.code.should eq 200
+    response.entities.should be_an Array
+  end
+
+  it "should be able to query users" do
+    entity1 = create_random_user @application
+    entity2 = create_random_user @application
+    begin
+      response = @application.users "select * where username = \'#{entity1.username}\'"
+      response.entities.size.should eq 1
+      response.entity.username.should eq entity1.username
+    ensure
+      entity1.delete
+      entity2.delete
+    end
+  end
+
+  it "should be able to update a user" do
+    entity = create_random_user @application
+    begin
+      updates = { email: 'testuser6@email.com', city: 'santa clarita' }
+      response = @application.put updates
+      updates.each {|k,v| response.entity[k.to_s].should eq v }
+    ensure
+      entity.delete
+    end
+  end
+
+  it "should be able to retrieve the logged in user" do
+    user = @application.current_user
+    user.uuid.should_not be_nil
+  end
+
+  it "should be able to add and retrieve activities" do
+    user = @application.current_user
+    activity = {
+        verb: "post",
+        content: "testy, testy",
+        actor: {
+          uuid: user.uuid,
+          email: user.email,
+          username: user.username,
+          displayName: user.username,
+          image: {
+            height: 80,
+            width: 80,
+            url: user.picture
+          }}}
+    response = @application['activities'].post activity
+    activity_path = response.entity['metadata']['path']
+    response.code.should eq 200
+
+    begin
+      entity = @application.activities.entity
+      activity.add_dot_notation!
+      entity.verb.should eq activity.verb
+      entity.content.should eq activity.content
+      entity.actor.uuid.should eq activity.actor.uuid
+    ensure
+      @application[activity_path].delete
+    end
+  end
+
+  it "should be able to retrieve a user's feed" do
+    response = @application.current_user.resource['feed'].get
+    response.code.should eq 200
+    response.entities.should be_an Array
+  end
+
+  it "should be able to follow a user" do
+    follower = create_random_user @application
+    begin
+      me = @application.current_user
+      @application["users/#{follower.uuid}/following/users/#{me.uuid}"].post "{}"
+
+      response = @application["users/#{follower.uuid}/following"].get
+      response.entities.size.should == 1
+      response.entity.uuid.should eq me.uuid
+
+      response = @application.current_user.resource['followers'].get
+      response.entities.size.should be > 0
+    ensure
+      follower.delete
+    end
+  end
+
+  it "should be able to create and retrieve groups" do
+    response = @application.groups
+    size = response.entities.size
+    random = SecureRandom.hex
+    @application.create_entity :groups, path: "test-#{random}"
+    response = @application.groups
+    response.entities.size.should eq size+1
+  end
+
+  it "should be able to create and retrieve devices" do
+    response = @application.devices
+    size = response.entities.size
+    random = SecureRandom.hex
+    @application.create_entity :devices, path: "test-#{random}"
+    response = @application.devices
+    response.entities.size.should eq size+1
+  end
+
+  it "should be able to create and retrieve assets" do
+    response = @application.assets
+    size = response.entities.size
+    random = SecureRandom.hex
+    @application.create_entity :assets, path: "test-#{random}", owner: @application.current_user.uuid
+    response = @application.assets
+    response.entities.size.should eq size+1
+  end
+
+  it "should be able to create and retrieve folders" do
+    response = @application.folders
+    size = response.entities.size
+    random = SecureRandom.hex
+    @application.create_entity :folders, path: "test-#{random}", owner: @application.current_user.uuid
+    response = @application.folders
+    response.entities.size.should eq size+1
+  end
+
+  # can't reliably test this - counters are batched on server
+  #it "should be able to create and retrieve events and retrieve counters" do
+  #  # clear events
+  #  {} while @application.events.entities.size > 0
+  #
+  #  events_in = []
+  #  events_in  << {timestamp: 0, category: 'test', counters: { test: 1 }}
+  #  events_in  << {timestamp: 0, category: 'testme', counters: { testme: 1 }}
+  #  events_in  << {timestamp: 0, counters: { test: 1 }}
+  #  events_in.each {|e| @application.create_entity :events, e }
+  #
+  #  events_out = []
+  #  events_out << @application.events.entity
+  #  events_out << @application.events.entity
+  #  events_out << @application.events.entity
+  #
+  #  (0..2).each do |i|
+  #    events_in[i][:category].should eq events_out[i]['category']
+  #  end
+  #
+  #  response = @application.events
+  #  response.entities.size.should eq 0
+  #
+  #  # get and test counters
+  #  counter_names = @application.counter_names
+  #  counter_names.should include 'test'
+  #  counter_names.should include 'testme'
+  #
+  #  response = @application.counter 'test'
+  #  counter = response.data.counters.first
+  #  counter.name.should eq 'test'
+  #  counter.values.last.first.value.should be > 0
+  #end
+
+  it "should be able to create, retrieve, and delete roles" do
+    size = @application.roles.collection.size
+
+    role_name = "test-#{SecureRandom.hex}"
+    @application.create_entity :role, name: role_name, title: 'title', inactivity: 0
+    roles = @application.roles.collection
+    roles.size.should eq size+1
+    role = roles.detect {|r| r.name == role_name }
+    role.should_not be_nil
+
+    role.delete
+    @application.roles.collection.size.should eq size
+  end
+
+  it "should be able to add/remove permissions from a user" do
+    user = create_random_user @application
+    permission = 'post:/users/*'
+    user.resource['permissions'].post permission: permission
+
+    permissions = user.resource['permissions'].get.data.data
+    permissions.size.should eq 1
+    permissions.first.should eq permission
+
+    user.resource['permissions'].delete({params: { permission: permission }})
+
+    permissions = user.resource['permissions'].get.collection.entities
+    permissions.size.should eq 0
+  end
+
+  it "should be able to add/remove a user from a roles" do
+    user = create_random_user @application
+
+    roles = user.resource['roles'].get.entities
+    size = roles.size
+
+    @application["roles/admin/users/#{user.uuid}"].post nil
+
+    roles = user.resource['roles'].get.entities
+    roles.size.should == size+1
+
+    @application["roles/admin/users/#{user.uuid}"].delete
+
+    roles = user.resource['roles'].get.entities
+    roles.size.should == size
+  end
+
+  it "should be able to create a new collection and access it" do
+    entities = (1..4).collect { |i| { name: "test_#{i}" } }
+    @application.create_entities 'tests', entities
+    response = @application['tests'].get
+    collection = response.collection
+    collection.size.should eq 4
+  end
+
+  it "should be able to create a new collection via create_ method and access it" do
+    entities = (1..4).collect { |i| { name: "test_#{i}" } }
+    @application.create_moretests entities
+    response = @application['tests'].get
+    collection = response.collection
+    collection.size.should eq 4
+  end
+
+  it "should be able to access a collection without calling get" do
+    entities = (1..4).collect { |i| { name: "test_#{i}" } }
+    @application.create_entities 'tests', entities
+    collection = @application['tests'].collection
+    collection.size.should eq 4
+  end
+
+  it "should be able to access entities without calling get" do
+    entities = (1..4).collect { |i| { name: "test_#{i}" } }
+    @application.create_entities 'tests', entities
+    entities = @application['tests'].entities
+    entities.size.should eq 4
+  end
+
+  it "should be able to query using dot notation" do
+    entities = (1..4).collect { |i| { name: "test_#{i}" } }
+    @application.create_btests entities
+    entities = @application.btests("name = 'test_1'").entities
+    entities.size.should eq 1
+  end
+
+  describe "grant_type: client_credentials" do
+
+    before(:each) do
+      @app = create_random_application
+    end
+
+    context "invalid credentials" do
+      it "should not be able to get access token with invalid credentials" do
+        expect { @app.login_credentials "invalid_client_id", "invalid_client_secret" }.to raise_exception RestClient::BadRequest
+      end
+
+      it "should not be able to get access token with empty credentials" do
+        expect { @app.login_credentials "", "" }.to raise_exception RestClient::BadRequest
+      end
+    end
+
+    context "valid credentials" do
+      it "should be able to get access token with valid credentials" do
+        app_info = JSON.parse @app.get
+
+        management = login_management
+        app = management.application app_info["organization"], app_info["applicationName"]
+        app_credentials = JSON.parse app.credentials
+        app.login_credentials app_credentials["credentials"]["client_id"], app_credentials["credentials"]["client_secret"]
+
+        expect(app.auth_token).to_not be_empty
+        expect(app.auth_token).to be_instance_of String
+      end
+    end
+  end
+end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/collection_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/collection_spec.rb b/sdks/other/ruby/spec/usergrid/core/collection_spec.rb
new file mode 100644
index 0000000..9ab07c3
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/collection_spec.rb
@@ -0,0 +1,125 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Collection do
+
+  before :all do
+    @application = create_random_application
+    @user = create_random_user @application, true
+
+    @collection = @application['tests'].collection
+    @entity_data = (1..25).collect do |i|
+      { name: "name_#{i}", value: "value_#{i+1}" }
+    end
+    (1..3).each {|i| @entity_data[i]['three'] = 3}
+    @collection.create_entities @entity_data
+  end
+
+  after :all do
+    @user.delete
+    delete_application @application
+  end
+
+  it "should be able to do a simple query" do
+    @collection.query "select * where name = \'#{@entity_data[0][:name]}\'"
+    @collection.size.should eq 1
+  end
+
+  it "should be able to select data elements" do
+    @collection.query "select name, value where name = \'#{@entity_data[0][:name]}\'"
+    @collection.size.should eq 1
+    # note: not Usergrid::Entity objects: it is an Array for this kind of query
+    values = @collection.entities.first
+    values[0].should eq @entity_data[0][:name]
+    values[1].should eq @entity_data[0][:value]
+  end
+
+  it "should be able to select redefined data elements" do
+    @collection.query "select { test1: name, test2 : value } where name = \'#{@entity_data[0][:name]}\'"
+    @collection.size.should eq 1
+    # note: not Usergrid::Entity objects: it is a Hash for this kind of query
+    values = @collection.entities.first
+    values.test1.should eq @entity_data[0][:name]
+    values.test2.should eq @entity_data[0][:value]
+  end
+
+  it "should be able to find an entity" do
+    @collection.query
+    entity = @collection.detect { |e| e.name == @entity_data[5][:name] }
+    entity.should_not be_nil
+    entity.name.should eq @entity_data[5][:name]
+  end
+
+  it "should be able to respect query reversal and limits" do
+    @collection.query nil, reversed: true, start: 5, cursor: nil, limit: 2, permission: nil
+    @collection.size.should eq 2
+    @collection[0].name.should eq @entity_data[@entity_data.size-1][:name]
+    @collection[1].name.should eq @entity_data[@entity_data.size-2][:name]
+  end
+
+  it "should be able to select the start by uuid" do
+    @collection.query
+    uuid = @collection[4].uuid
+    @collection.query nil, reversed: false, start: uuid, cursor: nil, limit: 3, permission: nil
+    @collection.size.should eq 3
+    @collection.first.uuid.should eq uuid
+    @collection[2].name.should eq @entity_data[6][:name]
+  end
+
+  it "should be able to page forward by cursor" do
+    @collection.query 'select * where three = 3', limit: 2
+    @collection.next_page
+    @collection.size.should eq 1
+    @collection[0].name.should eq @entity_data[3][:name]
+  end
+
+  it "should be able to update based on a query" do
+    @collection.update_query({new_field: 'new_value'}, "select * where name = \'#{@entity_data[4][:name]}\'")
+    @collection.query
+    entity = @collection.detect { |e| e['new_field'] == 'new_value' }
+    entity.should_not be_nil
+    entity.name.should eq @entity_data[4][:name]
+  end
+
+  it "should be able to delete based on a query" do
+    @collection.delete_query "select * where name = \'#{@entity_data[5][:name]}\'"
+    @collection.query
+    entity = @collection.detect { |e| e['name'] == "#{@entity_data[5][:name]}" }
+    entity.should be_nil
+    @entity_data.delete @entity_data[5]
+  end
+
+  it "should be able to iterate within the page" do
+    @collection.query
+    @collection.cursor.should_not be_nil
+    count = 0
+    page_size = @collection.count
+    @collection.each {|e| count += 1 }
+    count.should eq page_size
+  end
+
+  it "should be able to iterate over pages" do
+    @collection.query
+    @collection.cursor.should_not be_nil
+    count = 0
+    seen = Set.new
+    @collection.follow_cursor.each do |e|
+      seen.add?(e.uuid).should_not be_nil
+      count += 1
+    end
+    count.should eq @entity_data.size
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/entity_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/entity_spec.rb b/sdks/other/ruby/spec/usergrid/core/entity_spec.rb
new file mode 100644
index 0000000..887fa91
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/entity_spec.rb
@@ -0,0 +1,91 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Entity do
+
+  before :all do
+    @application = create_random_application
+    @user = create_random_user @application, true
+  end
+
+  after :all do
+    @user.delete
+    delete_application @application
+  end
+
+  it "should be able to retrieve its collection" do
+    collection = @user.collection
+    collection.should_not be_nil
+    u = collection.detect {|u| u.uuid == @user.uuid }
+    u.uuid.should eq @user.uuid
+  end
+
+  it "should be able to reload its data" do
+    old_name = @user.name
+    @user.name = 'new name'
+    @user.name.should eq 'new name'
+    @user.get
+    @user.name.should eq old_name
+  end
+
+  it "should be able to save" do
+    @user.name = 'new name'
+    @user.save
+    @user.name.should eq 'new name'
+  end
+
+  it "should be able to print itself" do
+    p = @user.to_s
+    p.start_with?('resource').should be_true
+  end
+
+  it "should know if it has data" do
+    @user.data?.should be_true
+    empty = Usergrid::Entity.new 'url', 'url'
+    empty.data?.should be_false
+  end
+
+  it "should return nil if empty result" do
+    @application['foobars'].get.entity.should be_nil
+  end
+
+  it "should not serialize reserved attributes" do
+    dump = MultiJson.dump @user
+    hash = MultiJson.load dump
+    Usergrid::Resource::RESERVED.each { |a| hash.should_not have_key(a) }
+  end
+
+  it "should be able to delete itself" do
+    user = create_random_user @application
+    name = user.name
+    user.delete
+    u = @application['users'].entities.detect {|e| e.name == "#{name}"}
+    u.should be_nil
+  end
+
+  it "should be able to update and delete by query" do
+    dog = (@application.create_dog name: 'Vex').entity
+
+    @application['dogs'].update_query({foo: 'bar'}, "select * where name = \'#{dog.name}\'")
+    dog.get
+    dog.foo.should eq('bar')
+
+    @application['dogs'].delete_query "select * where name = \'#{dog.name}\'"
+
+    dog = @application['dogs'].entities.detect {|e| e.name == "#{dog.name}"}
+    dog.should be_nil
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/management_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/management_spec.rb b/sdks/other/ruby/spec/usergrid/core/management_spec.rb
new file mode 100644
index 0000000..f53d572
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/management_spec.rb
@@ -0,0 +1,51 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Management do
+
+  before :all do
+    @base_resource = Usergrid::Resource.new(SPEC_SETTINGS[:api_url])
+    @management = @base_resource.management
+    @management.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
+  end
+
+  it "should be able to create an organization" do
+    # can't delete an org or a user, so we create new random ones and leave them
+    random = SecureRandom.hex
+    org_name = "test_org_#{random}"
+    user_name = "test_admin_#{random}"
+    response = @management.create_organization("#{org_name}",
+                                               "#{user_name}",
+                                               "#{user_name}",
+                                               "#{user_name}@email.com",
+                                               "#{random}")
+    response.code.should eq 200
+    #@base_resource["users/#{user_name}"].delete
+  end
+
+  # this is broken on the server
+  #it "should be able to get organizations" do
+  #  response = @management.organizations
+  #end
+
+  it "should be able to get an organization" do
+    organization = @management.organization SPEC_SETTINGS[:organization][:name]
+    organization.should be_a Usergrid::Organization
+    org_ent = organization.get.entity
+    org_ent.uuid.should_not be_nil
+    org_ent.name.should eq SPEC_SETTINGS[:organization][:name]
+  end
+
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/organization_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/organization_spec.rb b/sdks/other/ruby/spec/usergrid/core/organization_spec.rb
new file mode 100644
index 0000000..93092fc
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/organization_spec.rb
@@ -0,0 +1,113 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Organization do
+
+  before :each do
+    @management = Usergrid::Resource.new(SPEC_SETTINGS[:api_url]).management
+    @management.login SPEC_SETTINGS[:organization][:username], SPEC_SETTINGS[:organization][:password]
+    @organization = @management.organization SPEC_SETTINGS[:organization][:name]
+  end
+
+  it "should be able to create (and delete) an application" do
+    app_name = "test_app_#{SecureRandom.hex}"
+    app = @organization.create_application app_name
+    app.should be_an Usergrid::Application
+
+    response = @organization["applications/#{app_name}"].delete
+    response.code.should eq 200
+  end
+
+  it "should be able to get applications" do
+    response = @organization.applications
+    response.should be_an Array
+    if response.size > 0
+      app = response.first
+      app.should be_an Usergrid::Application
+    end
+  end
+
+  it "should be able to get users" do
+    response = @organization.users
+    response.code.should eq 200
+    response.entities.should be_an Array
+    response.entities[0].uuid.should_not be_nil
+  end
+
+  it "should be able to get a user" do
+    response = @organization.user(SPEC_SETTINGS[:organization][:username])
+    response.code.should eq 200
+    response.entity.uuid.should_not be_nil
+  end
+
+  it "should be able to get an application" do
+    app_name = "test_app_#{SecureRandom.hex}"
+    @organization.create_application app_name
+    begin
+      app = @organization.application app_name
+      app.should be_an Usergrid::Application
+    ensure
+      @organization["applications/#{app_name}"].delete
+    end
+  end
+
+  it "should be able to get feed" do
+    response = @organization.feed
+    entities = response.entities
+    entities.size.should be > 0
+    entities.first.uuid.should_not be_nil
+  end
+
+  it "should be able to get credentials" do
+    response = @organization.credentials
+    response.code.should eq 200
+    response.data.credentials.client_id.should_not be_nil
+    response.data.credentials.client_secret.should_not be_nil
+  end
+
+  it "should be able to generate credentials" do
+    response = @organization.generate_credentials
+    response.code.should eq 200
+    response.data.credentials.client_id.should_not be_nil
+    response.data.credentials.client_secret.should_not be_nil
+  end
+
+  describe "grant_type: client_credentials" do
+    context "invalid credentials" do
+      before :each do
+        @organization.logout
+      end
+
+      it "should not be able to get access token with invalid credentials" do
+        expect { @organization.login_credentials "invalid_client_id", "invalid_client_secret" }.to raise_exception RestClient::BadRequest
+      end
+
+      it "should not be able to get access token with empty credentials" do
+        expect { @organization.login_credentials "", "" }.to raise_exception RestClient::BadRequest
+      end
+    end
+
+    context "valid crendentials" do
+      it "should be able to get access token with valid credentials" do
+        org_credentials = JSON.parse @organization.credentials
+        @organization.logout
+        @organization.login_credentials org_credentials["credentials"]["client_id"], org_credentials["credentials"]["client_secret"]
+
+        expect(@organization.auth_token).to_not be_empty
+        expect(@organization.auth_token).to be_instance_of String
+      end
+    end
+  end
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/core/resource_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/core/resource_spec.rb b/sdks/other/ruby/spec/usergrid/core/resource_spec.rb
new file mode 100644
index 0000000..82a1ace
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/core/resource_spec.rb
@@ -0,0 +1,63 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+describe Usergrid::Resource do
+
+  before :all do
+    @resource = Usergrid::Resource.new SPEC_SETTINGS[:api_url]
+  end
+
+  it "should succeed on status check" do
+    response = @resource['/status'].get
+
+    response.code.should eq 200
+    response.data.should be_a Hash
+  end
+
+  it "should fail with a 400 when no auth given" do
+    expect { @resource['management'].get }.to raise_error(RestClient::BadRequest) { |exception|
+      exception.response.code.should eq 400
+    }
+  end
+
+  it "should fail with a 401 when lacking auth" do
+    app_endpoint = "#{SPEC_SETTINGS[:organization][:name]}/#{SPEC_SETTINGS[:application][:name]}"
+    expect { @resource[app_endpoint].get }.to raise_error(RestClient::Unauthorized) { |exception|
+      exception.response.code.should eq 401
+    }
+  end
+
+  it "should be able to login" do
+    resource = @resource['management']
+    response = resource.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
+
+    response.code.should eq 200
+    resource.auth_token.should_not be_nil
+    response.data['access_token'].should eq resource.auth_token
+    resource.options[:headers][:Authorization].should eq "Bearer #{resource.auth_token}"
+    resource.logged_in?.should be_true
+  end
+
+  it "should be able to log out" do
+    resource = @resource['management']
+    resource.login SPEC_SETTINGS[:management][:username], SPEC_SETTINGS[:management][:password]
+    resource.logged_in?.should be_true
+
+    resource.logout
+    resource.options[:headers][:Authorization].should be_nil
+    resource.logged_in?.should be_false
+  end
+
+end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/spec/usergrid/extensions/hash_spec.rb
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/spec/usergrid/extensions/hash_spec.rb b/sdks/other/ruby/spec/usergrid/extensions/hash_spec.rb
new file mode 100644
index 0000000..9dbecdb
--- /dev/null
+++ b/sdks/other/ruby/spec/usergrid/extensions/hash_spec.rb
@@ -0,0 +1,40 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+require_relative '../../../lib/usergrid/extensions/hash'
+
+describe Hash do
+
+  it "should add dot notation recursively" do
+    h = { test1: 'test1', test2: { test2a: 'test2a' }, test3: [ { test3a: 'test3a' }] }
+    expect { h.test1 }.to raise_error
+    h.add_dot_notation!
+    h.test1.should eq 'test1'
+    h.test2.test2a.should eq 'test2a'
+    h.test3.first.test3a.should eq 'test3a'
+    h.test1 = 'testx'
+    h.test1.should eq 'testx'
+  end
+
+  it "should symbolize keys at top level" do
+    h = { 'test1' => 'test1', 'test2' => { 'test2a' => 'test2a' }, 'test3' => [ { 'test3a' => 'test3a' }] }
+    h['test1'].should eq 'test1'
+    h = h.symbolize_keys
+    h['test1'].should be_nil
+    h[:test1].should eq 'test1'
+    h[:test2][:test2a].should be_nil
+    h[:test3].first['test3a'].should eq 'test3a'
+  end
+end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ruby/usergrid_iron.gemspec
----------------------------------------------------------------------
diff --git a/sdks/other/ruby/usergrid_iron.gemspec b/sdks/other/ruby/usergrid_iron.gemspec
new file mode 100644
index 0000000..f9bc46e
--- /dev/null
+++ b/sdks/other/ruby/usergrid_iron.gemspec
@@ -0,0 +1,41 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+# -*- encoding: utf-8 -*-
+require File.expand_path('../lib/usergrid/version', __FILE__)
+
+Gem::Specification.new do |gem|
+  gem.authors       = ["Scott Ganyo"]
+  gem.email         = ["scott@ganyo.com"]
+  gem.description   = %q{Low-level gem to access Usergrid / Apigee App Services}
+  gem.summary       = %q{Usergrid_iron enables simple, low-level Ruby access to Apigee's App Services
+                        (aka Usergrid) REST API with minimal dependencies.}
+  gem.homepage      = "https://github.com/scottganyo/usergrid_iron"
+
+  gem.files         = `git ls-files`.split($\)
+  gem.executables   = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
+  gem.test_files    = gem.files.grep(%r{^(spec|spec|features)/})
+  gem.name          = "usergrid_iron"
+  gem.require_paths = ["lib"]
+  gem.version       = Usergrid::VERSION
+
+  gem.add_dependency 'rest-client'
+  gem.add_dependency 'multi_json'
+
+  gem.add_development_dependency 'rake'
+  gem.add_development_dependency 'rspec'
+  gem.add_development_dependency 'simplecov'
+end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/Build.PL
----------------------------------------------------------------------
diff --git a/sdks/perl/Build.PL b/sdks/perl/Build.PL
deleted file mode 100644
index 71bcf10..0000000
--- a/sdks/perl/Build.PL
+++ /dev/null
@@ -1,46 +0,0 @@
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use 5.006;
-use strict;
-use warnings FATAL => 'all';
-use Module::Build;
-
-my $builder = Module::Build->new(
-    module_name         => 'Usergrid::Client',
-    license             => 'Apache_2_0',
-    abstract            => 'Client API for Apache Usergrid',
-    dist_author         => 'Anuradha Weeraman <an...@cpan.org>',
-    dist_version_from   => 'lib/Usergrid/Client.pm',
-    release_status      => 'stable',
-    configure_requires  => {
-        'Module::Build' => 0,
-    },
-    build_requires => {
-        'Test::More'    => 0,
-    },
-    requires => {
-        'Moose'                => 0,
-        'JSON'                 => 0,
-        'REST::Client'         => 0,
-        'URI::Template'        => 0,
-        'Log::Log4perl'        => 0,
-        'namespace::autoclean' => 0
-    },
-    add_to_cleanup      => [ 'Usergrid-Client-*' ]
-);
-
-$builder->create_build_script();

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/perl/LICENSE b/sdks/perl/LICENSE
deleted file mode 100644
index e06d208..0000000
--- a/sdks/perl/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets "{}"
-      replaced with your own identifying information. (Don't include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same "printed page" as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright {yyyy} {name of copyright owner}
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/MANIFEST
----------------------------------------------------------------------
diff --git a/sdks/perl/MANIFEST b/sdks/perl/MANIFEST
deleted file mode 100644
index 4169300..0000000
--- a/sdks/perl/MANIFEST
+++ /dev/null
@@ -1,23 +0,0 @@
-.travis.yml
-Build.PL
-examples/books.pl
-lib/Usergrid/Client.pm
-lib/Usergrid/Collection.pm
-lib/Usergrid/Entity.pm
-lib/Usergrid/Request.pm
-LICENSE
-Makefile.PL
-MANIFEST			This list of files
-META.json
-META.yml
-README.md
-t/01_init.t
-t/02_login.t
-t/03_update.t
-t/04_collection.t
-t/05_query.t
-t/06_batch_update.t
-t/07_batch_delete.t
-t/08_connections.t
-t/09_paging.t
-t/10_auto_paging.t

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/perl/Makefile.PL
----------------------------------------------------------------------
diff --git a/sdks/perl/Makefile.PL b/sdks/perl/Makefile.PL
deleted file mode 100644
index 6ab9874..0000000
--- a/sdks/perl/Makefile.PL
+++ /dev/null
@@ -1,41 +0,0 @@
-
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-use strict;
-use warnings;
-
-use 5.008;
-
-use ExtUtils::MakeMaker;
-
-WriteMakefile(
-  LICENSE           => 'apache',
-  AUTHOR            => 'Anuradha Weeraman <anuradha@cpan.org',
-  ABSTRACT          => 'Client API for Apache Usergrid',
-  NAME              => 'Usergrid::Client',
-  VERSION_FROM      => 'lib/Usergrid/Client.pm',
-  PREREQ_PM => {
-    'Moose'                => 0,
-    'JSON'                 => 0,
-    'REST::Client'         => 0,
-    'URI::Template'        => 0,
-    'Log::Log4perl'        => 0,
-    'namespace::autoclean' => 0
-  },
-  BUILD_REQUIRES    => {
-    'Test::More'    => '0.98'
-  }
-);


[40/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp.xcodeproj/project.pbxproj b/sdks/ios/UGAPIApp.xcodeproj/project.pbxproj
deleted file mode 100644
index 029a356..0000000
--- a/sdks/ios/UGAPIApp.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,653 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 46;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		22CA67241732087600C03C70 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22CA67231732087600C03C70 /* Default-568h@2x.png */; };
-		22D61E75171CBBF100E9CD17 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E6E171CBBF100E9CD17 /* UGConnection.m */; };
-		22D61E76171CBBF100E9CD17 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */; };
-		22D61E77171CBBF100E9CD17 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */; };
-		22D61E78171CBBF100E9CD17 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */; };
-		C96E782F1782349C004DD244 /* SSKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = C96E782E1782349C004DD244 /* SSKeychain.m */; };
-		C96E783717824711004DD244 /* Security.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C96E783617824711004DD244 /* Security.framework */; };
-		E89D6CA1150E5B2E005F5FB9 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */; };
-		E89D6CA3150E5B2E005F5FB9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */; };
-		E89D6CA5150E5B2E005F5FB9 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */; };
-		E89D6CAB150E5B2E005F5FB9 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */; };
-		E89D6CAD150E5B2E005F5FB9 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CAC150E5B2E005F5FB9 /* main.m */; };
-		E89D6CB1150E5B2E005F5FB9 /* UGAppAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */; };
-		E89D6CB4150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */; };
-		E89D6CB7150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */; };
-		E89D6CBA150E5B2E005F5FB9 /* UGAppViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */; };
-		E89D6CC2150E5B2E005F5FB9 /* SenTestingKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */; };
-		E89D6CC3150E5B2E005F5FB9 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */; };
-		E89D6CC4150E5B2E005F5FB9 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */; };
-		E89D6CCC150E5B2E005F5FB9 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */; };
-		E89D6CCF150E5B2E005F5FB9 /* UGAPIAppTests.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */; };
-		E89D6D05150E5B99005F5FB9 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */; };
-		E89D6D06150E5B99005F5FB9 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */; };
-		E89D6D07150E5B99005F5FB9 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */; };
-		E89D6D08150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */; };
-		E89D6D09150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */; };
-		E89D6D0A150E5B99005F5FB9 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */; };
-		E89D6D0B150E5B99005F5FB9 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */; };
-		E89D6D0C150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */; };
-		E89D6D0D150E5B99005F5FB9 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */; };
-		E89D6D0E150E5B99005F5FB9 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */; };
-		E89D6D0F150E5B99005F5FB9 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */; };
-		E89D6D10150E5B99005F5FB9 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */; };
-		E89D6D11150E5B99005F5FB9 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CF8150E5B99005F5FB9 /* UGActivity.m */; };
-		E89D6D12150E5B99005F5FB9 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFA150E5B99005F5FB9 /* UGClient.m */; };
-		E89D6D13150E5B99005F5FB9 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */; };
-		E89D6D14150E5B99005F5FB9 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */; };
-		E89D6D15150E5B99005F5FB9 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */; };
-		E89D6D16150E5B99005F5FB9 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D02150E5B99005F5FB9 /* UGQuery.m */; };
-		E89D6D17150E5B99005F5FB9 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = E89D6D04150E5B99005F5FB9 /* UGUser.m */; };
-		E89D6D19150E5C54005F5FB9 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXContainerItemProxy section */
-		E89D6CC5150E5B2E005F5FB9 /* PBXContainerItemProxy */ = {
-			isa = PBXContainerItemProxy;
-			containerPortal = E89D6C93150E5B2E005F5FB9 /* Project object */;
-			proxyType = 1;
-			remoteGlobalIDString = E89D6C9B150E5B2E005F5FB9;
-			remoteInfo = UGAPIApp;
-		};
-/* End PBXContainerItemProxy section */
-
-/* Begin PBXFileReference section */
-		22CA67231732087600C03C70 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
-		22D61E6D171CBBF100E9CD17 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
-		22D61E6E171CBBF100E9CD17 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
-		22D61E6F171CBBF100E9CD17 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
-		22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
-		22D61E71171CBBF100E9CD17 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
-		22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
-		22D61E73171CBBF100E9CD17 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
-		22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
-		638F675816EF875F002BD513 /* UGClientDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
-		C96E782D1782349C004DD244 /* SSKeychain.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SSKeychain.h; sourceTree = "<group>"; };
-		C96E782E1782349C004DD244 /* SSKeychain.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SSKeychain.m; sourceTree = "<group>"; };
-		C96E783617824711004DD244 /* Security.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Security.framework; path = System/Library/Frameworks/Security.framework; sourceTree = SDKROOT; };
-		E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = UGAPIApp.app; sourceTree = BUILT_PRODUCTS_DIR; };
-		E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
-		E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
-		E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
-		E89D6CA8150E5B2E005F5FB9 /* UGAPIApp-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "UGAPIApp-Info.plist"; sourceTree = "<group>"; };
-		E89D6CAA150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		E89D6CAC150E5B2E005F5FB9 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
-		E89D6CAE150E5B2E005F5FB9 /* UGAPIApp-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "UGAPIApp-Prefix.pch"; sourceTree = "<group>"; };
-		E89D6CAF150E5B2E005F5FB9 /* UGAppAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAppAppDelegate.h; sourceTree = "<group>"; };
-		E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAppAppDelegate.m; sourceTree = "<group>"; };
-		E89D6CB3150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPhone.storyboard; sourceTree = "<group>"; };
-		E89D6CB6150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPad.storyboard; sourceTree = "<group>"; };
-		E89D6CB8150E5B2E005F5FB9 /* UGAppViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAppViewController.h; sourceTree = "<group>"; };
-		E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAppViewController.m; sourceTree = "<group>"; };
-		E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = UGAPIAppTests.octest; sourceTree = BUILT_PRODUCTS_DIR; };
-		E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SenTestingKit.framework; path = Library/Frameworks/SenTestingKit.framework; sourceTree = DEVELOPER_DIR; };
-		E89D6CC9150E5B2E005F5FB9 /* UGAPIAppTests-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "UGAPIAppTests-Info.plist"; sourceTree = "<group>"; };
-		E89D6CCB150E5B2E005F5FB9 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		E89D6CCD150E5B2E005F5FB9 /* UGAPIAppTests.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = UGAPIAppTests.h; sourceTree = "<group>"; };
-		E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = UGAPIAppTests.m; sourceTree = "<group>"; };
-		E89D6CDE150E5B99005F5FB9 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
-		E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
-		E89D6CE0150E5B99005F5FB9 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
-		E89D6CE1150E5B99005F5FB9 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
-		E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
-		E89D6CE3150E5B99005F5FB9 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
-		E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
-		E89D6CE5150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
-		E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
-		E89D6CE7150E5B99005F5FB9 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
-		E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
-		E89D6CE9150E5B99005F5FB9 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
-		E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
-		E89D6CEB150E5B99005F5FB9 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
-		E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
-		E89D6CED150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
-		E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
-		E89D6CEF150E5B99005F5FB9 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
-		E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
-		E89D6CF1150E5B99005F5FB9 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
-		E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
-		E89D6CF3150E5B99005F5FB9 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
-		E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
-		E89D6CF5150E5B99005F5FB9 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
-		E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
-		E89D6CF7150E5B99005F5FB9 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
-		E89D6CF8150E5B99005F5FB9 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
-		E89D6CF9150E5B99005F5FB9 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
-		E89D6CFA150E5B99005F5FB9 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
-		E89D6CFB150E5B99005F5FB9 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
-		E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
-		E89D6CFD150E5B99005F5FB9 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
-		E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
-		E89D6CFF150E5B99005F5FB9 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
-		E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
-		E89D6D01150E5B99005F5FB9 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
-		E89D6D02150E5B99005F5FB9 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
-		E89D6D03150E5B99005F5FB9 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
-		E89D6D04150E5B99005F5FB9 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
-		E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		E89D6C99150E5B2E005F5FB9 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				C96E783717824711004DD244 /* Security.framework in Frameworks */,
-				E89D6D19150E5C54005F5FB9 /* CoreLocation.framework in Frameworks */,
-				E89D6CA1150E5B2E005F5FB9 /* UIKit.framework in Frameworks */,
-				E89D6CA3150E5B2E005F5FB9 /* Foundation.framework in Frameworks */,
-				E89D6CA5150E5B2E005F5FB9 /* CoreGraphics.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		E89D6CBC150E5B2E005F5FB9 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				E89D6CC2150E5B2E005F5FB9 /* SenTestingKit.framework in Frameworks */,
-				E89D6CC3150E5B2E005F5FB9 /* UIKit.framework in Frameworks */,
-				E89D6CC4150E5B2E005F5FB9 /* Foundation.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		22D61E6C171CBBF100E9CD17 /* v2 */ = {
-			isa = PBXGroup;
-			children = (
-				22D61E6D171CBBF100E9CD17 /* UGConnection.h */,
-				22D61E6E171CBBF100E9CD17 /* UGConnection.m */,
-				22D61E6F171CBBF100E9CD17 /* UGHTTPClient.h */,
-				22D61E70171CBBF100E9CD17 /* UGHTTPClient.m */,
-				22D61E71171CBBF100E9CD17 /* UGHTTPHelpers.h */,
-				22D61E72171CBBF100E9CD17 /* UGHTTPHelpers.m */,
-				22D61E73171CBBF100E9CD17 /* UGHTTPResult.h */,
-				22D61E74171CBBF100E9CD17 /* UGHTTPResult.m */,
-			);
-			path = v2;
-			sourceTree = "<group>";
-		};
-		C96E782917821C9D004DD244 /* SSKeychain */ = {
-			isa = PBXGroup;
-			children = (
-				C96E782D1782349C004DD244 /* SSKeychain.h */,
-				C96E782E1782349C004DD244 /* SSKeychain.m */,
-			);
-			name = SSKeychain;
-			sourceTree = "<group>";
-		};
-		E89D6C91150E5B2E005F5FB9 = {
-			isa = PBXGroup;
-			children = (
-				C96E783617824711004DD244 /* Security.framework */,
-				22CA67231732087600C03C70 /* Default-568h@2x.png */,
-				E89D6D18150E5C54005F5FB9 /* CoreLocation.framework */,
-				E89D6CDC150E5B99005F5FB9 /* UGAPI */,
-				E89D6CA6150E5B2E005F5FB9 /* UGAPIApp */,
-				E89D6CC7150E5B2E005F5FB9 /* UGAPIAppTests */,
-				E89D6C9F150E5B2E005F5FB9 /* Frameworks */,
-				E89D6C9D150E5B2E005F5FB9 /* Products */,
-			);
-			sourceTree = "<group>";
-		};
-		E89D6C9D150E5B2E005F5FB9 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */,
-				E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		E89D6C9F150E5B2E005F5FB9 /* Frameworks */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CA0150E5B2E005F5FB9 /* UIKit.framework */,
-				E89D6CA2150E5B2E005F5FB9 /* Foundation.framework */,
-				E89D6CA4150E5B2E005F5FB9 /* CoreGraphics.framework */,
-				E89D6CC1150E5B2E005F5FB9 /* SenTestingKit.framework */,
-			);
-			name = Frameworks;
-			sourceTree = "<group>";
-		};
-		E89D6CA6150E5B2E005F5FB9 /* UGAPIApp */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CAF150E5B2E005F5FB9 /* UGAppAppDelegate.h */,
-				E89D6CB0150E5B2E005F5FB9 /* UGAppAppDelegate.m */,
-				E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */,
-				E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */,
-				E89D6CB8150E5B2E005F5FB9 /* UGAppViewController.h */,
-				E89D6CB9150E5B2E005F5FB9 /* UGAppViewController.m */,
-				E89D6CA7150E5B2E005F5FB9 /* Supporting Files */,
-			);
-			path = UGAPIApp;
-			sourceTree = "<group>";
-		};
-		E89D6CA7150E5B2E005F5FB9 /* Supporting Files */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CA8150E5B2E005F5FB9 /* UGAPIApp-Info.plist */,
-				E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */,
-				E89D6CAC150E5B2E005F5FB9 /* main.m */,
-				E89D6CAE150E5B2E005F5FB9 /* UGAPIApp-Prefix.pch */,
-			);
-			name = "Supporting Files";
-			sourceTree = "<group>";
-		};
-		E89D6CC7150E5B2E005F5FB9 /* UGAPIAppTests */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CCD150E5B2E005F5FB9 /* UGAPIAppTests.h */,
-				E89D6CCE150E5B2E005F5FB9 /* UGAPIAppTests.m */,
-				E89D6CC8150E5B2E005F5FB9 /* Supporting Files */,
-			);
-			path = UGAPIAppTests;
-			sourceTree = "<group>";
-		};
-		E89D6CC8150E5B2E005F5FB9 /* Supporting Files */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CC9150E5B2E005F5FB9 /* UGAPIAppTests-Info.plist */,
-				E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */,
-			);
-			name = "Supporting Files";
-			sourceTree = "<group>";
-		};
-		E89D6CDC150E5B99005F5FB9 /* UGAPI */ = {
-			isa = PBXGroup;
-			children = (
-				C96E782917821C9D004DD244 /* SSKeychain */,
-				22D61E6C171CBBF100E9CD17 /* v2 */,
-				E89D6CDD150E5B99005F5FB9 /* SBJson */,
-				E89D6CF7150E5B99005F5FB9 /* UGActivity.h */,
-				E89D6CF8150E5B99005F5FB9 /* UGActivity.m */,
-				E89D6CF9150E5B99005F5FB9 /* UGClient.h */,
-				E89D6CFA150E5B99005F5FB9 /* UGClient.m */,
-				E89D6CFB150E5B99005F5FB9 /* UGClientResponse.h */,
-				E89D6CFC150E5B99005F5FB9 /* UGClientResponse.m */,
-				E89D6CFD150E5B99005F5FB9 /* UGHTTPManager.h */,
-				E89D6CFE150E5B99005F5FB9 /* UGHTTPManager.m */,
-				E89D6CFF150E5B99005F5FB9 /* UGMultiStepAction.h */,
-				E89D6D00150E5B99005F5FB9 /* UGMultiStepAction.m */,
-				E89D6D01150E5B99005F5FB9 /* UGQuery.h */,
-				E89D6D02150E5B99005F5FB9 /* UGQuery.m */,
-				E89D6D03150E5B99005F5FB9 /* UGUser.h */,
-				E89D6D04150E5B99005F5FB9 /* UGUser.m */,
-				638F675816EF875F002BD513 /* UGClientDelegate.h */,
-			);
-			path = UGAPI;
-			sourceTree = "<group>";
-		};
-		E89D6CDD150E5B99005F5FB9 /* SBJson */ = {
-			isa = PBXGroup;
-			children = (
-				E89D6CDE150E5B99005F5FB9 /* NSObject+SBJson.h */,
-				E89D6CDF150E5B99005F5FB9 /* NSObject+SBJson.m */,
-				E89D6CE0150E5B99005F5FB9 /* SBJson.h */,
-				E89D6CE1150E5B99005F5FB9 /* SBJsonParser.h */,
-				E89D6CE2150E5B99005F5FB9 /* SBJsonParser.m */,
-				E89D6CE3150E5B99005F5FB9 /* SBJsonStreamParser.h */,
-				E89D6CE4150E5B99005F5FB9 /* SBJsonStreamParser.m */,
-				E89D6CE5150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.h */,
-				E89D6CE6150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m */,
-				E89D6CE7150E5B99005F5FB9 /* SBJsonStreamParserAdapter.h */,
-				E89D6CE8150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m */,
-				E89D6CE9150E5B99005F5FB9 /* SBJsonStreamParserState.h */,
-				E89D6CEA150E5B99005F5FB9 /* SBJsonStreamParserState.m */,
-				E89D6CEB150E5B99005F5FB9 /* SBJsonStreamWriter.h */,
-				E89D6CEC150E5B99005F5FB9 /* SBJsonStreamWriter.m */,
-				E89D6CED150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.h */,
-				E89D6CEE150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m */,
-				E89D6CEF150E5B99005F5FB9 /* SBJsonStreamWriterState.h */,
-				E89D6CF0150E5B99005F5FB9 /* SBJsonStreamWriterState.m */,
-				E89D6CF1150E5B99005F5FB9 /* SBJsonTokeniser.h */,
-				E89D6CF2150E5B99005F5FB9 /* SBJsonTokeniser.m */,
-				E89D6CF3150E5B99005F5FB9 /* SBJsonUTF8Stream.h */,
-				E89D6CF4150E5B99005F5FB9 /* SBJsonUTF8Stream.m */,
-				E89D6CF5150E5B99005F5FB9 /* SBJsonWriter.h */,
-				E89D6CF6150E5B99005F5FB9 /* SBJsonWriter.m */,
-			);
-			path = SBJson;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = E89D6CD2150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIApp" */;
-			buildPhases = (
-				E89D6C98150E5B2E005F5FB9 /* Sources */,
-				E89D6C99150E5B2E005F5FB9 /* Frameworks */,
-				E89D6C9A150E5B2E005F5FB9 /* Resources */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = UGAPIApp;
-			productName = UGAPIApp;
-			productReference = E89D6C9C150E5B2E005F5FB9 /* UGAPIApp.app */;
-			productType = "com.apple.product-type.application";
-		};
-		E89D6CBF150E5B2E005F5FB9 /* UGAPIAppTests */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = E89D6CD5150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIAppTests" */;
-			buildPhases = (
-				E89D6CBB150E5B2E005F5FB9 /* Sources */,
-				E89D6CBC150E5B2E005F5FB9 /* Frameworks */,
-				E89D6CBD150E5B2E005F5FB9 /* Resources */,
-				E89D6CBE150E5B2E005F5FB9 /* ShellScript */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-				E89D6CC6150E5B2E005F5FB9 /* PBXTargetDependency */,
-			);
-			name = UGAPIAppTests;
-			productName = UGAPIAppTests;
-			productReference = E89D6CC0150E5B2E005F5FB9 /* UGAPIAppTests.octest */;
-			productType = "com.apple.product-type.bundle";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		E89D6C93150E5B2E005F5FB9 /* Project object */ = {
-			isa = PBXProject;
-			attributes = {
-				CLASSPREFIX = UGApp;
-				LastUpgradeCheck = 0430;
-			};
-			buildConfigurationList = E89D6C96150E5B2E005F5FB9 /* Build configuration list for PBXProject "UGAPIApp" */;
-			compatibilityVersion = "Xcode 3.2";
-			developmentRegion = English;
-			hasScannedForEncodings = 0;
-			knownRegions = (
-				en,
-			);
-			mainGroup = E89D6C91150E5B2E005F5FB9;
-			productRefGroup = E89D6C9D150E5B2E005F5FB9 /* Products */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */,
-				E89D6CBF150E5B2E005F5FB9 /* UGAPIAppTests */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
-		E89D6C9A150E5B2E005F5FB9 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				E89D6CAB150E5B2E005F5FB9 /* InfoPlist.strings in Resources */,
-				E89D6CB4150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard in Resources */,
-				E89D6CB7150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard in Resources */,
-				22CA67241732087600C03C70 /* Default-568h@2x.png in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		E89D6CBD150E5B2E005F5FB9 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				E89D6CCC150E5B2E005F5FB9 /* InfoPlist.strings in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXShellScriptBuildPhase section */
-		E89D6CBE150E5B2E005F5FB9 /* ShellScript */ = {
-			isa = PBXShellScriptBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-			);
-			inputPaths = (
-			);
-			outputPaths = (
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-			shellPath = /bin/sh;
-			shellScript = "# Run the unit tests in this test bundle.\n\"${SYSTEM_DEVELOPER_DIR}/Tools/RunUnitTests\"\n";
-		};
-/* End PBXShellScriptBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		E89D6C98150E5B2E005F5FB9 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				E89D6CAD150E5B2E005F5FB9 /* main.m in Sources */,
-				E89D6CB1150E5B2E005F5FB9 /* UGAppAppDelegate.m in Sources */,
-				E89D6CBA150E5B2E005F5FB9 /* UGAppViewController.m in Sources */,
-				E89D6D05150E5B99005F5FB9 /* NSObject+SBJson.m in Sources */,
-				E89D6D06150E5B99005F5FB9 /* SBJsonParser.m in Sources */,
-				E89D6D07150E5B99005F5FB9 /* SBJsonStreamParser.m in Sources */,
-				E89D6D08150E5B99005F5FB9 /* SBJsonStreamParserAccumulator.m in Sources */,
-				E89D6D09150E5B99005F5FB9 /* SBJsonStreamParserAdapter.m in Sources */,
-				E89D6D0A150E5B99005F5FB9 /* SBJsonStreamParserState.m in Sources */,
-				E89D6D0B150E5B99005F5FB9 /* SBJsonStreamWriter.m in Sources */,
-				E89D6D0C150E5B99005F5FB9 /* SBJsonStreamWriterAccumulator.m in Sources */,
-				E89D6D0D150E5B99005F5FB9 /* SBJsonStreamWriterState.m in Sources */,
-				E89D6D0E150E5B99005F5FB9 /* SBJsonTokeniser.m in Sources */,
-				E89D6D0F150E5B99005F5FB9 /* SBJsonUTF8Stream.m in Sources */,
-				E89D6D10150E5B99005F5FB9 /* SBJsonWriter.m in Sources */,
-				E89D6D11150E5B99005F5FB9 /* UGActivity.m in Sources */,
-				E89D6D12150E5B99005F5FB9 /* UGClient.m in Sources */,
-				E89D6D13150E5B99005F5FB9 /* UGClientResponse.m in Sources */,
-				E89D6D14150E5B99005F5FB9 /* UGHTTPManager.m in Sources */,
-				E89D6D15150E5B99005F5FB9 /* UGMultiStepAction.m in Sources */,
-				E89D6D16150E5B99005F5FB9 /* UGQuery.m in Sources */,
-				E89D6D17150E5B99005F5FB9 /* UGUser.m in Sources */,
-				22D61E75171CBBF100E9CD17 /* UGConnection.m in Sources */,
-				22D61E76171CBBF100E9CD17 /* UGHTTPClient.m in Sources */,
-				22D61E77171CBBF100E9CD17 /* UGHTTPHelpers.m in Sources */,
-				22D61E78171CBBF100E9CD17 /* UGHTTPResult.m in Sources */,
-				C96E782F1782349C004DD244 /* SSKeychain.m in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		E89D6CBB150E5B2E005F5FB9 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				E89D6CCF150E5B2E005F5FB9 /* UGAPIAppTests.m in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXTargetDependency section */
-		E89D6CC6150E5B2E005F5FB9 /* PBXTargetDependency */ = {
-			isa = PBXTargetDependency;
-			target = E89D6C9B150E5B2E005F5FB9 /* UGAPIApp */;
-			targetProxy = E89D6CC5150E5B2E005F5FB9 /* PBXContainerItemProxy */;
-		};
-/* End PBXTargetDependency section */
-
-/* Begin PBXVariantGroup section */
-		E89D6CA9150E5B2E005F5FB9 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				E89D6CAA150E5B2E005F5FB9 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-		E89D6CB2150E5B2E005F5FB9 /* MainStoryboard_iPhone.storyboard */ = {
-			isa = PBXVariantGroup;
-			children = (
-				E89D6CB3150E5B2E005F5FB9 /* en */,
-			);
-			name = MainStoryboard_iPhone.storyboard;
-			sourceTree = "<group>";
-		};
-		E89D6CB5150E5B2E005F5FB9 /* MainStoryboard_iPad.storyboard */ = {
-			isa = PBXVariantGroup;
-			children = (
-				E89D6CB6150E5B2E005F5FB9 /* en */,
-			);
-			name = MainStoryboard_iPad.storyboard;
-			sourceTree = "<group>";
-		};
-		E89D6CCA150E5B2E005F5FB9 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				E89D6CCB150E5B2E005F5FB9 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		E89D6CD0150E5B2E005F5FB9 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = NO;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					"DEBUG=1",
-					"$(inherited)",
-				);
-				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
-				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-			};
-			name = Debug;
-		};
-		E89D6CD1150E5B2E005F5FB9 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				ARCHS = "$(ARCHS_STANDARD_32_BIT)";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = YES;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 5.0;
-				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-				VALIDATE_PRODUCT = YES;
-			};
-			name = Release;
-		};
-		E89D6CD3150E5B2E005F5FB9 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
-				INFOPLIST_FILE = "UGAPIApp/UGAPIApp-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Debug;
-		};
-		E89D6CD4150E5B2E005F5FB9 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
-				INFOPLIST_FILE = "UGAPIApp/UGAPIApp-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Release;
-		};
-		E89D6CD6150E5B2E005F5FB9 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/UGAPIApp.app/UGAPIApp";
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(SDKROOT)/Developer/Library/Frameworks",
-					"$(DEVELOPER_LIBRARY_DIR)/Frameworks",
-				);
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
-				INFOPLIST_FILE = "UGAPIAppTests/UGAPIAppTests-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				TEST_HOST = "$(BUNDLE_LOADER)";
-				WRAPPER_EXTENSION = octest;
-			};
-			name = Debug;
-		};
-		E89D6CD7150E5B2E005F5FB9 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/UGAPIApp.app/UGAPIApp";
-				FRAMEWORK_SEARCH_PATHS = (
-					"$(SDKROOT)/Developer/Library/Frameworks",
-					"$(DEVELOPER_LIBRARY_DIR)/Frameworks",
-				);
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "UGAPIApp/UGAPIApp-Prefix.pch";
-				INFOPLIST_FILE = "UGAPIAppTests/UGAPIAppTests-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				TEST_HOST = "$(BUNDLE_LOADER)";
-				WRAPPER_EXTENSION = octest;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		E89D6C96150E5B2E005F5FB9 /* Build configuration list for PBXProject "UGAPIApp" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				E89D6CD0150E5B2E005F5FB9 /* Debug */,
-				E89D6CD1150E5B2E005F5FB9 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		E89D6CD2150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIApp" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				E89D6CD3150E5B2E005F5FB9 /* Debug */,
-				E89D6CD4150E5B2E005F5FB9 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		E89D6CD5150E5B2E005F5FB9 /* Build configuration list for PBXNativeTarget "UGAPIAppTests" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				E89D6CD6150E5B2E005F5FB9 /* Debug */,
-				E89D6CD7150E5B2E005F5FB9 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = E89D6C93150E5B2E005F5FB9 /* Project object */;
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/sdks/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
deleted file mode 100644
index 3092016..0000000
--- a/sdks/ios/UGAPIApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<Workspace
-   version = "1.0">
-   <FileRef
-      location = "self:UGAPIApp.xcodeproj">
-   </FileRef>
-</Workspace>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAPIApp-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAPIApp-Info.plist b/sdks/ios/UGAPIApp/UGAPIApp-Info.plist
deleted file mode 100644
index 45143c7..0000000
--- a/sdks/ios/UGAPIApp/UGAPIApp-Info.plist
+++ /dev/null
@@ -1,49 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>en</string>
-	<key>CFBundleDisplayName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apigee.usergrid.${PRODUCT_NAME:rfc1034identifier}</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleShortVersionString</key>
-	<string>1.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>LSRequiresIPhoneOS</key>
-	<true/>
-	<key>UIMainStoryboardFile</key>
-	<string>MainStoryboard_iPhone</string>
-	<key>UIMainStoryboardFile~ipad</key>
-	<string>MainStoryboard_iPad</string>
-	<key>UIRequiredDeviceCapabilities</key>
-	<array>
-		<string>armv7</string>
-	</array>
-	<key>UISupportedInterfaceOrientations</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-	<key>UISupportedInterfaceOrientations~ipad</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationPortraitUpsideDown</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-</dict>
-</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAPIApp-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAPIApp-Prefix.pch b/sdks/ios/UGAPIApp/UGAPIApp-Prefix.pch
deleted file mode 100644
index b497ab1..0000000
--- a/sdks/ios/UGAPIApp/UGAPIApp-Prefix.pch
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-//
-// Prefix header for all source files of the 'UGAPIApp' target in the 'UGAPIApp' project
-//
-
-#import <Availability.h>
-
-#ifndef __IPHONE_5_0
-#warning "This project uses features only available in iOS SDK 5.0 and later."
-#endif
-
-#ifdef __OBJC__
-    #import <UIKit/UIKit.h>
-    #import <Foundation/Foundation.h>
-#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAppAppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAppAppDelegate.h b/sdks/ios/UGAPIApp/UGAppAppDelegate.h
deleted file mode 100644
index 15c3ced..0000000
--- a/sdks/ios/UGAPIApp/UGAppAppDelegate.h
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <UIKit/UIKit.h>
-@class UGHTTPManager;
-
-@interface UGAppAppDelegate : UIResponder <UIApplicationDelegate>
-
-@property (strong, nonatomic) UIWindow *window;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAppAppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAppAppDelegate.m b/sdks/ios/UGAPIApp/UGAppAppDelegate.m
deleted file mode 100644
index 2e7d6de..0000000
--- a/sdks/ios/UGAPIApp/UGAppAppDelegate.m
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGAppAppDelegate.h"
-#import "UGHTTPManager.h"
-#import "SBJson.h"
-#import "UGClient.h"
-#import "UGClientResponse.h"
-
-UGClient *g_client = nil;
-int g_taps = 0;
-
-@implementation UGAppAppDelegate
-
-@synthesize window = _window;
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
-    // Override point for customization after application launch.
-    return YES;
-}
-							
-- (void)applicationWillResignActive:(UIApplication *)application
-{
-    // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
-    // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
-}
-
-- (void)applicationDidEnterBackground:(UIApplication *)application
-{
-    // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 
-    // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
-}
-
-- (void)applicationWillEnterForeground:(UIApplication *)application
-{
-    // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
-}
-
-- (void)applicationDidBecomeActive:(UIApplication *)application
-{
-    // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
-}
-
-- (void)applicationWillTerminate:(UIApplication *)application
-{
-    // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
-}
-
--(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
-{
-    // called when there's a touch.
-    [self testUGClient];
-}
-
--(void)testUGClient
-{
-    // creation and init
-    if ( !g_client )
-    {
-        g_client =[[UGClient alloc] initWithOrganizationId:@"1hotrod" withApplicationID:@"fred" ];
-    }
-    
-    UGClientResponse *response = nil;
-    response = [g_client logInUser:@"alice" password:@"test1test"];
-    if ( [response transactionState] == kUGClientResponseFailure )
-    {
-        [self outputResponse:response title:@"LOG IN ERROR"];
-        return;
-    }
-    
-    CLLocation *fakeLocation = [[CLLocation alloc] initWithLatitude:37.776753 longitude:-122.407846];
-    
-    UGQuery *query = [UGQuery new];
-    [query addRequiredWithinLocation:@"location" location:fakeLocation distance:2000];
-    
-    response = [g_client getUsers:query];
-    [self outputResponse:response title:@"getUsers Response"];
-}
-
--(void)ugClientResponse:(UGClientResponse *)response
-{
-    // note the results
-    [self outputResponse:response title:@"Asynch Response"];
-}
-
--(void)outputResponse:(UGClientResponse *)response title:(NSString *)title
-{
-    NSLog(@"-----%@-----", title);
-    if ( !response )
-    {
-        NSLog(@"Response is nil");
-        NSLog(@"------------------");
-        return;
-    }
-    
-    
-    if ( [response transactionState] == kUGClientResponseSuccess )
-    {
-        NSLog(@"state: SUCCESS");
-        NSLog(@"id: %d", [response transactionID]);
-        NSLog(@"raw:\n%@", [response rawResponse]);
-    }
-    else if ( [response transactionState] == kUGClientResponsePending )
-    {
-        NSLog(@"state: PENDING");
-        NSLog(@"id: %d", [response transactionID]);
-    }
-    else if ( [response transactionState] == kUGClientResponseFailure )
-    {
-        NSLog(@"state: FAILURE");
-        NSLog(@"id: %d", [response transactionID]);
-        NSLog(@"reason: '%@'", [response response]);
-        NSLog(@"raw:\n%@", [response rawResponse]);
-    }
-    else 
-    {
-        NSLog(@"Object is mangled or invalid.");
-    }
-    NSLog(@"------------------");
-}
-
-
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAppViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAppViewController.h b/sdks/ios/UGAPIApp/UGAppViewController.h
deleted file mode 100644
index 9846c31..0000000
--- a/sdks/ios/UGAPIApp/UGAppViewController.h
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <UIKit/UIKit.h>
-
-@interface UGAppViewController : UIViewController
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/UGAppViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/UGAppViewController.m b/sdks/ios/UGAPIApp/UGAppViewController.m
deleted file mode 100644
index b7c5424..0000000
--- a/sdks/ios/UGAPIApp/UGAppViewController.m
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGAppViewController.h"
-
-@interface UGAppViewController ()
-
-@end
-
-@implementation UGAppViewController
-
-- (void)viewDidLoad
-{
-    [super viewDidLoad];
-	// Do any additional setup after loading the view, typically from a nib.
-}
-
-- (void)viewDidUnload
-{
-    [super viewDidUnload];
-    // Release any retained subviews of the main view.
-}
-
-- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
-{
-    if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
-        return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
-    } else {
-        return YES;
-    }
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/en.lproj/InfoPlist.strings b/sdks/ios/UGAPIApp/en.lproj/InfoPlist.strings
deleted file mode 100644
index 477b28f..0000000
--- a/sdks/ios/UGAPIApp/en.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,2 +0,0 @@
-/* Localized versions of Info.plist keys */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard b/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
deleted file mode 100644
index 447df68..0000000
--- a/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPad.storyboard
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="1.0" toolsVersion="1906" systemVersion="11A511" targetRuntime="iOS.CocoaTouch.iPad" nextObjectID="6" propertyAccessControl="none" initialViewController="2">
-    <dependencies>
-        <development defaultVersion="4200" identifier="xcode"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="902"/>
-    </dependencies>
-    <scenes>
-        <scene sceneID="4">
-            <objects>
-                <placeholder placeholderIdentifier="IBFirstResponder" id="3" sceneMemberID="firstResponder"/>
-                <viewController id="2" customClass="UGAppViewController" sceneMemberID="viewController">
-                    <view key="view" contentMode="scaleToFill" id="5">
-                        <rect key="frame" x="0.0" y="20" width="768" height="1004"/>
-                        <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
-                        <subviews/>
-                        <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
-                    </view>
-                </viewController>
-            </objects>
-        </scene>
-    </scenes>
-    <simulatedMetricsContainer key="defaultSimulatedMetrics">
-        <simulatedStatusBarMetrics key="statusBar" statusBarStyle="blackTranslucent"/>
-        <simulatedOrientationMetrics key="orientation"/>
-        <simulatedScreenMetrics key="destination"/>
-    </simulatedMetricsContainer>
-</document>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard b/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
deleted file mode 100644
index 92b0831..0000000
--- a/sdks/ios/UGAPIApp/en.lproj/MainStoryboard_iPhone.storyboard
+++ /dev/null
@@ -1,27 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="1.0" toolsVersion="1906" systemVersion="11A511" targetRuntime="iOS.CocoaTouch" nextObjectID="6" propertyAccessControl="none" initialViewController="2">
-    <dependencies>
-        <development defaultVersion="4200" identifier="xcode"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="902"/>
-    </dependencies>
-    <scenes>
-        <scene sceneID="5">
-            <objects>
-                <placeholder placeholderIdentifier="IBFirstResponder" id="4" sceneMemberID="firstResponder"/>
-                <viewController id="2" customClass="UGAppViewController" sceneMemberID="viewController">
-                    <view key="view" contentMode="scaleToFill" id="3">
-                        <rect key="frame" x="0.0" y="20" width="320" height="460"/>
-                        <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
-                        <subviews/>
-                        <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
-                    </view>
-                </viewController>
-            </objects>
-        </scene>
-    </scenes>
-    <simulatedMetricsContainer key="defaultSimulatedMetrics">
-        <simulatedStatusBarMetrics key="statusBar"/>
-        <simulatedOrientationMetrics key="orientation"/>
-        <simulatedScreenMetrics key="destination"/>
-    </simulatedMetricsContainer>
-</document>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIApp/main.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIApp/main.m b/sdks/ios/UGAPIApp/main.m
deleted file mode 100644
index f547811..0000000
--- a/sdks/ios/UGAPIApp/main.m
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <UIKit/UIKit.h>
-
-#import "UGAppAppDelegate.h"
-
-int main(int argc, char *argv[])
-{
-    @autoreleasepool {
-        return UIApplicationMain(argc, argv, nil, NSStringFromClass([UGAppAppDelegate class]));
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIAppTests/UGAPIAppTests-Info.plist b/sdks/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
deleted file mode 100644
index 94b9921..0000000
--- a/sdks/ios/UGAPIAppTests/UGAPIAppTests-Info.plist
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>en</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apigee.usergrid.${PRODUCT_NAME:rfc1034identifier}</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundlePackageType</key>
-	<string>BNDL</string>
-	<key>CFBundleShortVersionString</key>
-	<string>1.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1</string>
-</dict>
-</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIAppTests/UGAPIAppTests.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIAppTests/UGAPIAppTests.h b/sdks/ios/UGAPIAppTests/UGAPIAppTests.h
deleted file mode 100644
index abaf125..0000000
--- a/sdks/ios/UGAPIAppTests/UGAPIAppTests.h
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <SenTestingKit/SenTestingKit.h>
-
-@interface UGAPIAppTests : SenTestCase
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIAppTests/UGAPIAppTests.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIAppTests/UGAPIAppTests.m b/sdks/ios/UGAPIAppTests/UGAPIAppTests.m
deleted file mode 100644
index 0cda4c0..0000000
--- a/sdks/ios/UGAPIAppTests/UGAPIAppTests.m
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGAPIAppTests.h"
-
-@implementation UGAPIAppTests
-
-- (void)setUp
-{
-    [super setUp];
-    
-    // Set-up code here.
-}
-
-- (void)tearDown
-{
-    // Tear-down code here.
-    
-    [super tearDown];
-}
-
-- (void)testExample
-{
-    STFail(@"Unit tests are not implemented yet in UGAPIAppTests");
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPIAppTests/en.lproj/InfoPlist.strings b/sdks/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
deleted file mode 100644
index 477b28f..0000000
--- a/sdks/ios/UGAPIAppTests/en.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,2 +0,0 @@
-/* Localized versions of Info.plist keys */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/changelog.md
----------------------------------------------------------------------
diff --git a/sdks/ios/changelog.md b/sdks/ios/changelog.md
deleted file mode 100644
index 88d0b1f..0000000
--- a/sdks/ios/changelog.md
+++ /dev/null
@@ -1,11 +0,0 @@
-##Change log
-
-
-###0.9.2
-
-- Added Facebook login
-
-
-###0.9.1
-
-- Fixed several bugs
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books.xcodeproj/project.pbxproj b/sdks/ios/samples/Books/books.xcodeproj/project.pbxproj
deleted file mode 100644
index 3db9841..0000000
--- a/sdks/ios/samples/Books/books.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,342 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 46;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		224EA246170F6F63002B136A /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA23F170F6F63002B136A /* UGConnection.m */; };
-		224EA247170F6F63002B136A /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA241170F6F63002B136A /* UGHTTPClient.m */; };
-		224EA248170F6F63002B136A /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA243170F6F63002B136A /* UGHTTPHelpers.m */; };
-		224EA249170F6F63002B136A /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 224EA245170F6F63002B136A /* UGHTTPResult.m */; };
-		227AE09F170DF424004F6E20 /* UGSignInViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 227AE09E170DF424004F6E20 /* UGSignInViewController.m */; };
-		227AE0A2170E01CF004F6E20 /* AddBookViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 227AE0A1170E01CF004F6E20 /* AddBookViewController.m */; };
-		228ADD73170DE2ED0030F962 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD72170DE2ED0030F962 /* UIKit.framework */; };
-		228ADD75170DE2ED0030F962 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD74170DE2ED0030F962 /* Foundation.framework */; };
-		228ADD77170DE2ED0030F962 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 228ADD76170DE2ED0030F962 /* CoreGraphics.framework */; };
-		228ADD7D170DE2ED0030F962 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD7B170DE2ED0030F962 /* InfoPlist.strings */; };
-		228ADD7F170DE2ED0030F962 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD7E170DE2ED0030F962 /* main.m */; };
-		228ADD83170DE2ED0030F962 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD82170DE2ED0030F962 /* AppDelegate.m */; };
-		228ADD85170DE2ED0030F962 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD84170DE2ED0030F962 /* Default.png */; };
-		228ADD87170DE2ED0030F962 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD86170DE2ED0030F962 /* Default@2x.png */; };
-		228ADD89170DE2ED0030F962 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 228ADD88170DE2ED0030F962 /* Default-568h@2x.png */; };
-		228ADD91170DE3170030F962 /* BooksViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 228ADD90170DE3170030F962 /* BooksViewController.m */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		224EA23E170F6F63002B136A /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
-		224EA23F170F6F63002B136A /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
-		224EA240170F6F63002B136A /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
-		224EA241170F6F63002B136A /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
-		224EA242170F6F63002B136A /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
-		224EA243170F6F63002B136A /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
-		224EA244170F6F63002B136A /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
-		224EA245170F6F63002B136A /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
-		227AE09D170DF424004F6E20 /* UGSignInViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGSignInViewController.h; sourceTree = "<group>"; };
-		227AE09E170DF424004F6E20 /* UGSignInViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGSignInViewController.m; sourceTree = "<group>"; };
-		227AE0A0170E01CF004F6E20 /* AddBookViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AddBookViewController.h; sourceTree = "<group>"; };
-		227AE0A1170E01CF004F6E20 /* AddBookViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AddBookViewController.m; sourceTree = "<group>"; };
-		228ADD6F170DE2ED0030F962 /* books.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = books.app; sourceTree = BUILT_PRODUCTS_DIR; };
-		228ADD72170DE2ED0030F962 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
-		228ADD74170DE2ED0030F962 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
-		228ADD76170DE2ED0030F962 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
-		228ADD7A170DE2ED0030F962 /* books-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "books-Info.plist"; sourceTree = "<group>"; };
-		228ADD7C170DE2ED0030F962 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		228ADD7E170DE2ED0030F962 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
-		228ADD80170DE2ED0030F962 /* books-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "books-Prefix.pch"; sourceTree = "<group>"; };
-		228ADD81170DE2ED0030F962 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
-		228ADD82170DE2ED0030F962 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
-		228ADD84170DE2ED0030F962 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
-		228ADD86170DE2ED0030F962 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
-		228ADD88170DE2ED0030F962 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
-		228ADD8F170DE3170030F962 /* BooksViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BooksViewController.h; sourceTree = "<group>"; };
-		228ADD90170DE3170030F962 /* BooksViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BooksViewController.m; sourceTree = "<group>"; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		228ADD6C170DE2ED0030F962 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				228ADD73170DE2ED0030F962 /* UIKit.framework in Frameworks */,
-				228ADD75170DE2ED0030F962 /* Foundation.framework in Frameworks */,
-				228ADD77170DE2ED0030F962 /* CoreGraphics.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		224EA23D170F6F63002B136A /* UGAPI */ = {
-			isa = PBXGroup;
-			children = (
-				224EA23E170F6F63002B136A /* UGConnection.h */,
-				224EA23F170F6F63002B136A /* UGConnection.m */,
-				224EA240170F6F63002B136A /* UGHTTPClient.h */,
-				224EA241170F6F63002B136A /* UGHTTPClient.m */,
-				224EA242170F6F63002B136A /* UGHTTPHelpers.h */,
-				224EA243170F6F63002B136A /* UGHTTPHelpers.m */,
-				224EA244170F6F63002B136A /* UGHTTPResult.h */,
-				224EA245170F6F63002B136A /* UGHTTPResult.m */,
-			);
-			name = UGAPI;
-			path = ../../UGAPI/v2;
-			sourceTree = "<group>";
-		};
-		228ADD66170DE2ED0030F962 = {
-			isa = PBXGroup;
-			children = (
-				224EA23D170F6F63002B136A /* UGAPI */,
-				228ADD78170DE2ED0030F962 /* books */,
-				228ADD79170DE2ED0030F962 /* Supporting Files */,
-				228ADD71170DE2ED0030F962 /* Frameworks */,
-				228ADD70170DE2ED0030F962 /* Products */,
-			);
-			sourceTree = "<group>";
-		};
-		228ADD70170DE2ED0030F962 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				228ADD6F170DE2ED0030F962 /* books.app */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		228ADD71170DE2ED0030F962 /* Frameworks */ = {
-			isa = PBXGroup;
-			children = (
-				228ADD72170DE2ED0030F962 /* UIKit.framework */,
-				228ADD74170DE2ED0030F962 /* Foundation.framework */,
-				228ADD76170DE2ED0030F962 /* CoreGraphics.framework */,
-			);
-			name = Frameworks;
-			sourceTree = "<group>";
-		};
-		228ADD78170DE2ED0030F962 /* books */ = {
-			isa = PBXGroup;
-			children = (
-				228ADD81170DE2ED0030F962 /* AppDelegate.h */,
-				228ADD82170DE2ED0030F962 /* AppDelegate.m */,
-				228ADD8F170DE3170030F962 /* BooksViewController.h */,
-				228ADD90170DE3170030F962 /* BooksViewController.m */,
-				227AE09D170DF424004F6E20 /* UGSignInViewController.h */,
-				227AE09E170DF424004F6E20 /* UGSignInViewController.m */,
-				227AE0A0170E01CF004F6E20 /* AddBookViewController.h */,
-				227AE0A1170E01CF004F6E20 /* AddBookViewController.m */,
-			);
-			path = books;
-			sourceTree = "<group>";
-		};
-		228ADD79170DE2ED0030F962 /* Supporting Files */ = {
-			isa = PBXGroup;
-			children = (
-				228ADD7A170DE2ED0030F962 /* books-Info.plist */,
-				228ADD7B170DE2ED0030F962 /* InfoPlist.strings */,
-				228ADD7E170DE2ED0030F962 /* main.m */,
-				228ADD80170DE2ED0030F962 /* books-Prefix.pch */,
-				228ADD84170DE2ED0030F962 /* Default.png */,
-				228ADD86170DE2ED0030F962 /* Default@2x.png */,
-				228ADD88170DE2ED0030F962 /* Default-568h@2x.png */,
-			);
-			name = "Supporting Files";
-			path = books;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		228ADD6E170DE2ED0030F962 /* books */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 228ADD8C170DE2ED0030F962 /* Build configuration list for PBXNativeTarget "books" */;
-			buildPhases = (
-				228ADD6B170DE2ED0030F962 /* Sources */,
-				228ADD6C170DE2ED0030F962 /* Frameworks */,
-				228ADD6D170DE2ED0030F962 /* Resources */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = books;
-			productName = books;
-			productReference = 228ADD6F170DE2ED0030F962 /* books.app */;
-			productType = "com.apple.product-type.application";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		228ADD67170DE2ED0030F962 /* Project object */ = {
-			isa = PBXProject;
-			attributes = {
-				LastUpgradeCheck = 0460;
-				ORGANIZATIONNAME = Radtastical;
-			};
-			buildConfigurationList = 228ADD6A170DE2ED0030F962 /* Build configuration list for PBXProject "books" */;
-			compatibilityVersion = "Xcode 3.2";
-			developmentRegion = English;
-			hasScannedForEncodings = 0;
-			knownRegions = (
-				en,
-			);
-			mainGroup = 228ADD66170DE2ED0030F962;
-			productRefGroup = 228ADD70170DE2ED0030F962 /* Products */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				228ADD6E170DE2ED0030F962 /* books */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
-		228ADD6D170DE2ED0030F962 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				228ADD7D170DE2ED0030F962 /* InfoPlist.strings in Resources */,
-				228ADD85170DE2ED0030F962 /* Default.png in Resources */,
-				228ADD87170DE2ED0030F962 /* Default@2x.png in Resources */,
-				228ADD89170DE2ED0030F962 /* Default-568h@2x.png in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		228ADD6B170DE2ED0030F962 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				228ADD7F170DE2ED0030F962 /* main.m in Sources */,
-				228ADD83170DE2ED0030F962 /* AppDelegate.m in Sources */,
-				228ADD91170DE3170030F962 /* BooksViewController.m in Sources */,
-				227AE09F170DF424004F6E20 /* UGSignInViewController.m in Sources */,
-				227AE0A2170E01CF004F6E20 /* AddBookViewController.m in Sources */,
-				224EA246170F6F63002B136A /* UGConnection.m in Sources */,
-				224EA247170F6F63002B136A /* UGHTTPClient.m in Sources */,
-				224EA248170F6F63002B136A /* UGHTTPHelpers.m in Sources */,
-				224EA249170F6F63002B136A /* UGHTTPResult.m in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXVariantGroup section */
-		228ADD7B170DE2ED0030F962 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				228ADD7C170DE2ED0030F962 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		228ADD8A170DE2ED0030F962 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = NO;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					"DEBUG=1",
-					"$(inherited)",
-				);
-				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				ONLY_ACTIVE_ARCH = YES;
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-			};
-			name = Debug;
-		};
-		228ADD8B170DE2ED0030F962 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = YES;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-				VALIDATE_PRODUCT = YES;
-			};
-			name = Release;
-		};
-		228ADD8D170DE2ED0030F962 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "books/books-Prefix.pch";
-				INFOPLIST_FILE = "books/books-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Debug;
-		};
-		228ADD8E170DE2ED0030F962 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "books/books-Prefix.pch";
-				INFOPLIST_FILE = "books/books-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		228ADD6A170DE2ED0030F962 /* Build configuration list for PBXProject "books" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				228ADD8A170DE2ED0030F962 /* Debug */,
-				228ADD8B170DE2ED0030F962 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		228ADD8C170DE2ED0030F962 /* Build configuration list for PBXNativeTarget "books" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				228ADD8D170DE2ED0030F962 /* Debug */,
-				228ADD8E170DE2ED0030F962 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 228ADD67170DE2ED0030F962 /* Project object */;
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/Books/books/AddBookViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/Books/books/AddBookViewController.h b/sdks/ios/samples/Books/books/AddBookViewController.h
deleted file mode 100644
index d9aaeb7..0000000
--- a/sdks/ios/samples/Books/books/AddBookViewController.h
+++ /dev/null
@@ -1,41 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  AddBookViewController.h
-//  books
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface AddBookViewController : UITableViewController
-
-@end


[11/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Notification.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Notification.php b/sdks/php/lib/vendor/Apache/Usergrid/Notification.php
deleted file mode 100755
index 53bc506..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Notification.php
+++ /dev/null
@@ -1,103 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Notification - a data structure to hold all notification-related parameters
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 09-Mar-2013
- */
-
-namespace Apache\Usergrid;
-
-define('DEVICES', 'DEVICES');
-define('GROUPS', 'GROUPS');
-define('USERS', 'USERS');
-
-class Notification extends Response {
-  private $message = '';
-  private $notifier_name;
-  private $delivery_time = 0;
-  private $recipients_list = array();
-  private $recipient_type = DEVICES;
-  private $errors = array();
-
-  public function __construct($message = '', $notifier_name = '', $delivery_time = 0, $recipients_list = array(), $recipient_type = DEVICES) {
-    $this->message = $message;
-    $this->notifier_name = $notifier_name;
-    $this->delivery_time = $delivery_time;
-    $this->recipients_list = $recipients_list;
-    $this->recipient_type = $recipient_type;
-  }
-
-  public function set_message($in) {
-    $this->message = $in;
-  }
-
-  public function get_message() {
-    return $this->message;
-  }
-
-  public function set_notifier_name($in) {
-    $this->notifier_name = $in;
-  }
-
-  public function get_notifier_name() {
-    return $this->notifier_name;
-  }
-
-  public function set_delivery_time($in) {
-    $this->delivery_time = $in;
-  }
-
-  public function get_delivery_time() {
-    return $this->delivery_time;
-  }
-
-  public function set_recipients_list($in) {
-    $this->recipients_list = $in;
-  }
-
-  public function get_recipients_list() {
-    return $this->recipients_list;
-  }
-
-  public function set_recipient_type($in) {
-    $this->recipient_type = $in;
-  }
-
-  public function get_recipient_type() {
-    return $this->recipient_type;
-  }
-
-  public function log_error($in) {
-    $this->errors[] = $in;
-  }
-
-  public function errors() {
-    return (count($this->errors) > 0);
-  }
-
-  public function get_error_array() {
-    return $this->errors;
-  }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Request.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Request.php b/sdks/php/lib/vendor/Apache/Usergrid/Request.php
deleted file mode 100755
index 85890e6..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Request.php
+++ /dev/null
@@ -1,174 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
-* @file
-* Request - a data structure to hold all request-related parameters
-*
-* @author Rod Simpson <ro...@apigee.com>
-* @since 26-Apr-2013
-*/
-
-namespace Apache\Usergrid;
-
-require_once (dirname(__FILE__) . '/Exceptions.php');
-
-
-class Request {
-  /**
-   * @var string
-   */
-  private $method;
-  /**
-   * @var string
-   */
-  private $endpoint;
-  /**
-   * @var array
-   */
-  private $query_string_array; //an array of key value pairs to be appended as the query string
-  /**
-   * @var array
-   */
-  private $body;
-  /**
-   * @var bool
-   */
-  private $management_query;
-
-  /**
-   * Constructor for Request object
-   *
-   * @param string $method
-   * @param string $endpoint
-   * @param array $query_string_array
-   * @param array $body
-   * @param bool $management_query
-   */
-  public function __construct($method = 'GET', $endpoint = '', $query_string_array = array(), $body = array(), $management_query=FALSE) {
-		$this->method = $method;
-		$this->endpoint = $endpoint;
-		$this->query_string_array = $query_string_array;
-		$this->body = $body;
-		$this->management_query = $management_query;
-  }
-
-  /**
-   * Sets (and validates) the HTTP method.
-   *
-   * @param string $http_method
-   * @throws UGException
-   */
-  public function set_method($http_method){
-    if ($http_method !== 'GET' && $http_method !== 'POST' && $http_method !== 'PUT' && $http_method !== 'DELETE') {
-      throw new UGException("Unknown HTTP method type $http_method");
-    }
-    $this->method = $http_method;
-  }
-
-  /**
-   * Gets the HTTP method (GET, POST, PUT or DELETE)
-   *
-   * @return string
-   */
-  public function get_method(){
-    return $this->method;
-  }
-
-  /**
-   * Sets the endpoint base URL.
-   *
-   * @param $endpoint
-   */
-  public function set_endpoint($endpoint){
-    $this->endpoint = $endpoint;
-  }
-  /**
-   * Returns the endpoint base URL.
-   *
-   * @return string
-   */
-  public function get_endpoint(){
-    return $this->endpoint;
-  }
-
-  /**
-   * Sets the query-string array. This should be an associative key-value hash.
-   *
-   * @param array $in
-   */
-  public function set_query_string_array($key_value_pairs) {
-    if (!is_array($key_value_pairs)) {
-      throw new UGException('Request->query_string_array must be an array.');
-    }
-    $this->query_string_array = $key_value_pairs;
-  }
-  /**
-   * Returns the key-value associative array of query string values.
-   *
-   * @return array
-   */
-  public function get_query_string_array(){
-    return $this->query_string_array;
-  }
-
-  /**
-   * Sets the body array. This should be an array structure representing
-   * parameters sent via PUT/POST.
-   *
-   * @param array $body
-   */
-  public function set_body($body){
-    if (!is_array($body)) {
-      throw new UGException('Request->body must be an array.');
-    }
-    $this->body = $body;
-  }
-
-  /**
-   * Returns the body array.
-   *
-   * @return array
-   */
-  public function get_body(){
-    return $this->body;
-  }
-
-  /**
-   * Sets the boolean flag indicating whether this is a "management query" or
-   * not.
-   *
-   * @param bool $in
-   */
-  public function set_management_query($in){
-    //ensure we have a bool
-    $this->management_query = (bool)$in;
-  }
-
-  /**
-   * Returns flag indicating whether this is a "management query".
-   *
-   * @return bool
-   */
-  public function get_management_query(){
-    return $this->management_query;
-  }
-
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/lib/vendor/Apache/Usergrid/Response.php
----------------------------------------------------------------------
diff --git a/sdks/php/lib/vendor/Apache/Usergrid/Response.php b/sdks/php/lib/vendor/Apache/Usergrid/Response.php
deleted file mode 100755
index 39467b7..0000000
--- a/sdks/php/lib/vendor/Apache/Usergrid/Response.php
+++ /dev/null
@@ -1,90 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Response - a data structure to hold all response-related parameters
- *
- * @author Rod Simpson <ro...@apigee.com>
- * @since 26-Apr-2013
- */
-
-namespace Apache\Usergrid;
-
-
-class Response extends Request{
-  private $data = array();
-  private $json = '';
-  private $curl_meta = array();
-  private $error = FALSE;
-  private $error_code = '';
-  private $error_message = '';
-
-  public function __construct($data = array(), $curl_meta = array(), $error = FALSE, $error_code = '', $error_message = '', $json = '') {
-		$this->data = $data;
-		$this->json = $json;
-		$this->curl_meta = $curl_meta;
-		$this->error = $error;
-		$this->set_error_code = $error_code;
-		$this->error_message = $error_message;
-  }
-
-  public function set_data($in){
-    $this->data = $in;
-  }
-  public function get_data(){
-    return $this->data;
-  }
-
-  public function set_json($in){
-    $this->json = $in;
-  }
-  public function get_json(){
-    return $this->json;
-  }
-
-  public function set_curl_meta($in){
-    $this->curl_meta = $in;
-  }
-  public function get_curl_meta(){
-    return $this->curl_meta;
-  }
-
-  public function set_error($in){
-    $this->error = $in;
-  }
-  public function get_error(){
-    return $this->error;
-  }
-
-  public function set_error_code($in){
-    $this->error_code = $in;
-  }
-  public function get_error_code(){
-    return $this->error_code;
-  }
-
-  public function set_error_message($in){
-    $this->error_message = $in;
-  }
-  public function get_error_message(){
-    return $this->error_message;
-  }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php/tests/autoloader.inc.php
----------------------------------------------------------------------
diff --git a/sdks/php/tests/autoloader.inc.php b/sdks/php/tests/autoloader.inc.php
deleted file mode 100644
index 3793355..0000000
--- a/sdks/php/tests/autoloader.inc.php
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/usr/bin/env php
-<?php
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-function usergrid_autoload($class) {
-
-
-  if (strpos($class, '\\') !== FALSE) {
-    $path_parts = explode('\\', $class);
-    if ($path_parts[0] == 'Apache') {
-      $lib_path = realpath(dirname(__FILE__) . '/../lib/vendor');
-      $class_path = $lib_path . '/' . join('/', $path_parts) . '.php';
-      if (file_exists($class_path)) {
-        require_once($class_path);
-      }
-    }
-  }
-}
-
-spl_autoload_register('usergrid_autoload');

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/.gitignore b/sdks/php5/apache-usergrid/.gitignore
deleted file mode 100644
index 61ba991..0000000
--- a/sdks/php5/apache-usergrid/.gitignore
+++ /dev/null
@@ -1,12 +0,0 @@
-# Created by .gitignore support plugin (hsz.mobi)
-### Composer template
-composer.phar
-vendor/
-
-# dot env files
-.env.php
-.evn.*.php
-
-# Commit your application's lock file http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file
-# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
-# composer.lock

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/attrubites/attributes.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/attrubites/attributes.php b/sdks/php5/apache-usergrid/Examples/attrubites/attributes.php
deleted file mode 100644
index 0f4f180..0000000
--- a/sdks/php5/apache-usergrid/Examples/attrubites/attributes.php
+++ /dev/null
@@ -1,122 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-include('data.php');
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-
-/**
- * Attributes are a new feature that make getting related models easy as accessing a property on a model object
- * The way relationships work before this feature it required you to call the getRelationship method on the application
- * service which is still available, so for example you would first get the user then once you had the user you create a
- * array that contained the uuid of the user the related collection name and the relationship name then call the api passing in the
- * array but for the default relationships we already have the data that we need to make the api call so that is what
- * I've done.
- * <pre>
- * <?php
- *  $user = Usergrid::users()->findById(['uuid' => '1234abcd']) ;
- *  $device = $user->device;
- * ?>
- * </pre>
- *  That's all you need to do to get a device for the user this only works when you have one user in your user collection
- *  if you call this with more then one user in your user collection it will return the device for the first user in the
- *  collection.
- *
- */
-
-$user = Usergrid::users()->findById(['uuid' => '1234abcd']);
-
-echo "device" . PHP_EOL;
-var_dump($user->device);
-var_dump('=================================================================');
-
-echo "roles" . PHP_EOL;
-var_dump($user->roles);
-var_dump('=================================================================');
-
-echo "groups" . PHP_EOL;
-var_dump($user->groups);
-var_dump('=================================================================');
-
-echo "connections" . PHP_EOL;
-var_dump($user->connections);
-var_dump('=================================================================');
-
-
-var_dump('=================================================================');
-echo "GROUPS" . PHP_EOL;
-var_dump('=================================================================');
-
-
-$group = Usergrid::groups()->findById(['uuid' => '121212']);
-
-
-echo "roles" . PHP_EOL;
-var_dump($group->roles);
-var_dump('=================================================================');
-
-echo "groups" . PHP_EOL;
-var_dump($group->users);
-var_dump('=================================================================');
-
-echo "connections" . PHP_EOL;
-var_dump($group->connections);
-var_dump('=================================================================');
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/collections/books.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/collections/books.php b/sdks/php5/apache-usergrid/Examples/collections/books.php
deleted file mode 100644
index 034046e..0000000
--- a/sdks/php5/apache-usergrid/Examples/collections/books.php
+++ /dev/null
@@ -1,130 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-include('data.php');
-
-use Apache\Usergrid\Api\Filters\Date;
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-
-foreach ($books_data as $book) {
-    Usergrid::application()->EntityJsonPost($book);
-}
-
-
-$books = Usergrid::application()->EntityGet(['collection' => 'books', 'limit' => 25]);
-
-
-// get result count just call the Illuminate\Support\Collection  count method
-var_dump($books->entities->count());
-
-
-// As responses are model object you can treat them like a assoc arrays
-var_dump($books->entities[0]['uuid']);
-
-// if you like a more object orientated way then use the Collection Class methods
-
-// get all uuid
-var_dump($books->entities->fetch('uuid'));
-
-//get first uuid
-var_dump($books->entities->fetch('uuid')->first());
-
-// get first item in collection -- this is the first item in my response php collection not the Usergrid Collection (table).
-var_dump($books->entities->first());
-
-// get last item in collection -- this is the last item in my response php collection not the Usergrid Collection (table).
-var_dump($books->entities->last());
-
-// convert created date to string
-var_dump(Date::convert($books->entities->fetch('created')->first()));
-
-// Illuminate\Support\Collection class support all advanced collection methods
-
-// pop last item off collection
-$book = $books->entities->pop();
-
-// Converting methods
-$json_ = $books->entities->toJson();
-
-//Convert the object into something JSON serializable.
-$books->entities->jsonSerialize();
-
-// Get an iterator for the items in collection
-$iterator = $books->entities->getIterator();
-
-//Get a CachingIterator instance
-$caching_iterator = $books->entities->getCachingIterator();
-
-/// Here are some more Methods that you can call on your responses .. To get the most out of this SDK please look at the Illuminate\Support\Collection class
-/// which is the supper class of Apache/Usergrid/Api/Models/BaseCollection class
-/**
- * $books->unique();
- * $books->transform();
- * $books->take();
- * $books->splice();
- * $books->sum($callback );
- * $books->values();
- * $books->sortByDesc($callback);
- * $books->sortBy();
- * $books->shuffle();
- * $books->chunk();
- */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/collections/data.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/collections/data.php b/sdks/php5/apache-usergrid/Examples/collections/data.php
deleted file mode 100644
index e9ca805..0000000
--- a/sdks/php5/apache-usergrid/Examples/collections/data.php
+++ /dev/null
@@ -1,38 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-$books_data = [
-    ['collection' => 'books', 'title' => 'book one', 'name' => 'book_one', 'author' => 'author 1'],
-    ['collection' => 'books', 'title' => 'book two', 'name' => 'book_two', 'author' => 'author 2'],
-    ['collection' => 'books', 'title' => 'book three', 'name' => 'book_three', 'author' => 'author 3'],
-    ['collection' => 'books', 'title' => 'book four', 'name' => 'book_four', 'author' => 'author 4'],
-    ['collection' => 'books', 'title' => 'book five', 'name' => 'book_five', 'author' => 'author 5'],
-    ['collection' => 'books', 'title' => 'book six', 'name' => 'book_six', 'author' => 'author 6'],
-    ['collection' => 'books', 'title' => 'book seven', 'name' => 'book_seven', 'author' => 'author 7'],
-    ['collection' => 'books', 'title' => 'book eight', 'name' => 'book_eight', 'author' => 'author 8'],
-    ['collection' => 'books', 'title' => 'book nine', 'name' => 'book_nine', 'author' => 'author 9'],
-    ['collection' => 'books', 'title' => 'book ten', 'name' => 'book_ten', 'author' => 'author 10'],
-    ['collection' => 'books', 'title' => 'book eleven', 'name' => 'book_eleven', 'author' => 'author 11'],
-    ['collection' => 'books', 'title' => 'book twelve', 'name' => 'book_twelve', 'author' => 'author 12'],
-    ['collection' => 'books', 'title' => 'book thirteen', 'name' => 'book_thirteen', 'author' => 'author 13'],
-    ['collection' => 'books', 'title' => 'book fourteen', 'name' => 'book_fourteen', 'author' => 'author 14'],
-    ['collection' => 'books', 'title' => 'book fifteen', 'name' => 'book_fifteen', 'author' => 'author 15'],
-    ['collection' => 'books', 'title' => 'book sixteen', 'name' => 'book_sixteen', 'author' => 'author 16'],
-    ['collection' => 'books', 'title' => 'book seventeen', 'name' => 'book_seventeen', 'author' => 'author 17'],
-    ['collection' => 'books', 'title' => 'book eighteen', 'name' => 'book_eighteen', 'author' => 'author 18'],
-    ['collection' => 'books', 'title' => 'book nineteen', 'name' => 'book_nineteen', 'author' => 'author 19'],
-    ['collection' => 'books', 'title' => 'book twenty', 'name' => 'book_twenty', 'author' => 'author 20'],
-];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/collections/users.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/collections/users.php b/sdks/php5/apache-usergrid/Examples/collections/users.php
deleted file mode 100644
index da67ac3..0000000
--- a/sdks/php5/apache-usergrid/Examples/collections/users.php
+++ /dev/null
@@ -1,120 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-include('data.php');
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-
-// call user by page size 20
-$users_paged = Usergrid::users()->all();
-var_dump(get_class($users_paged->entities));
-
-//// get user 50 page size
-$users_paged_50 = Usergrid::users()->all(['limit' => 50]);
-var_dump($users_paged_50->entities);
-
-// get all users
-$all_users = Usergrid::usersIterator();
-foreach ($all_users as $user) {
-//    var_dump($user['uuid']); // as array
-}
-
-// find user by query
-$find_user_by_query = Usergrid::users()->find(['ql' => "select * where email='jason@apps4u.com.au'"]);
-var_dump($find_user_by_query->entities->fetch('uuid'));
-
-$find_user_by_uuid = Usergrid::users()->findById(['uuid' => $find_user_by_query->entities->fetch('uuid')->first()]);
-var_dump($find_user_by_uuid->entities);
-
-
-// AS all results as PHP Collections and the entities property is always returned as a PHP Collection you can fetch nested records
-$user_addr = Usergrid::users()->findById(['uuid' => 'Jason']);
-echo $user_addr->entities->fetch('adr.addr1');
-//or
-echo $user_addr->entities->fetch('adr.city');
-
-// get users device URL -- nested fetch on php collection
-$users_nested = Usergrid::users()->all();
-var_dump($users_nested->entities->fetch('metadata.collections.devices')->first());
-
-// The response that is returned is a PHP collection that has a Zero indexed $item property.
-// but as its a collection class it has some methods that can help you find what you need and one
-// of my fav feature is changing the Zero indexed collection to be indexed by the entity uuid or name or any other property.
-$users_by = Usergrid::users()->all();
-
-$users_by_uuid = $users_by->entities->keyBy('uuid');
-var_dump($users_by_uuid->get('add uuid of user'));
-
-$users_by_name = $users_by->entities->keyBy('username');
-var_dump($users_by_name->get('jasonk'));
-
-$users_by_email = $users_by->entities->keyBy('email');
-var_dump($users_by_email->get('jasonk@apps4u.com.au'));
-
-// sort by key
-$sorted_by_email = $users_by->sortBy('username');
-var_dump($sorted_by_email);
-
-
-// add user to group
-//$user_to_group = Usergrid::groups()->addUser(['entity_name_or_uuid' => 'group_name_or_uuid', 'user_name_or_uuid' => 'user name or uuid']);
-
-//$user_remove_group = Usergrid::groups()->removeUser(['entity_name_or_uuid' => 'group_name_or_uuid', 'user_name_or_uuid' => 'user name or uuid']);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/examples.md
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/examples.md b/sdks/php5/apache-usergrid/Examples/examples.md
deleted file mode 100644
index 6bfdcd7..0000000
--- a/sdks/php5/apache-usergrid/Examples/examples.md
+++ /dev/null
@@ -1,17 +0,0 @@
-## Examples Read Me ##
-
-I don't show every method that you can call in the examples but I show you the most common api calls you will make but to get the most out of this api 
-you really should spend around 10 to 15 minutes to read all the guzzle web service descriptors files in the Manifest folders that are versioned the most 
-up to date version is 1.0.1 folder.
-
-### Manifest files ###
-Guzzle web service descriptors.
-
-You can use the files included with the sdk but you are able to create your own , so you can pass the path the the manifest folder in the config to the sdk. 
-The reason you might create you own is to support you own custom collections. So the way to do that is to copy the manifest folder to the location you want
-then there is a file called custom that you need to copy and edit so for example if I had a custom Collection called Books and I want to be able to call
-the sdk like ```Usergrid::books()->findById(['uuid'=> '12121']); ``` . All I have to do is copy the manifest file called custom and name it books and then 
-in the file replace the ```$custom``` with the word ```'books'``` .
-From that point on I can make api calls to my custom collection just like any of the default collection usergrid give you its a easy as that Ive designed this
-SDK to be extended so you can get the most out of your usergrid install .
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/examples.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/examples.php b/sdks/php5/apache-usergrid/Examples/examples.php
deleted file mode 100644
index 0348610..0000000
--- a/sdks/php5/apache-usergrid/Examples/examples.php
+++ /dev/null
@@ -1,245 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-include('vendor/autoload.php');
-
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => './src/Manifests', //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'application',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'password',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-/** Usergrid Facades Off */
-
-//call the bootstrap class that will create the api client then get the usergrid instance from the bootstrapper
-$bootstrapper = new UsergridBootstrapper($config);
-$usergrid = $bootstrapper->createUsergrid();
-
-/** Note: I'm using Users for the first lot of example's but you could do the same for all default collections eg: groups, devices, roles, notification etc*/
-
-// All responses are model objects that subclass the baseCollection class so all collection methods are available eg: first(), map(), fetch(), hasValue(), hasKey() etc.
-
-//find users with query
-$user = $usergrid->users()->find(['ql' => 'select * where activated=true']);
-
-//var_dump($user->entities->first());
-
-//request that throw exception in this case 404 not found
-try {
-
-    $user2 = $usergrid->users()->findById(['uuid' => 'uuid-number']);
-//    var_dump($user2->get('entities'));
-} catch (Apache\Usergrid\Api\Exception\NotFoundException $e) {
-
-//    var_dump($e->getResponse());
-}
-/**
- * There a errors for all Usergrid response errors and http errors so you can create a catch all error class or plug it into your fav php frameworks error handling.
- * Apache\Usergrid\Api\Exception\BadRequestException = http 400
- * Apache\Usergrid\Api\Exception\UnauthorizedException = http 401
- * Apache\Usergrid\Api\Exception\RequestFailedException = http 402
- * Apache\Usergrid\Api\Exception\NotFoundException = http 404
- * Apache\Usergrid\Api\Exception\ServerErrorException = http 500
- * Apache\Usergrid\Api\Exception\ServerErrorException = http 502
- * Apache\Usergrid\Api\Exception\ServerErrorException = http 503
- * Apache\Usergrid\Api\Exception\ServerErrorException = http 504
- */
-
-// collection Iterators no need to keep calling request with a cursor to get all entities in a collection
-// UserIterator(), DeviceIterator() GroupsIterator() , RolesIterator() etc.
-$user_iterator = $usergrid->usersIterator();
-
-foreach ($user_iterator as $iUser) {
-    var_dump($iUser);
-    var_dump("---------------------------------------------------------------------------------");
-}
-
-// create new user
-$new_user = ['name' => 'jasonk', 'username' => 'JasonK', 'email' => 'jason@example.com', 'password' => 'some_password'];
-//$created_user = $usergrid->users()->create($new_user);
-//var_dump($created_user->entities);
-
-//Update Users by name or uuid
-$new_email = ['email' => 'jason@example', 'entity_name_or_uuid' => 'benn'];
-$updated_user = $usergrid->users()->update($new_email);
-//var_dump($updated_user->entities);
-
-// delete a user
-//$deleted_user = $usergrid->users()->delete(['entity_name_or_uuid' => 'benn']);
-//var_dump($deleted_user);
-
-//get custom collection
-$custom_collection = $usergrid->application()->EntityGet(['collection' => 'shops']);
-//var_dump($custom_collection->entities->get('name'));
-
-//get custom collection with query
-$custom_collection_query = $usergrid->application()->EntityGet([
-    'collection' => 'shops',
-    'ql' => "select * where country='aus'"
-]);
-//var_dump($custom_collection_query->get('entities'));
-
-// Post custom collection as JSON data
-$custom_entity = [
-    'collection' => 'shops',
-    'name' => 'shop_name',
-    'adr' => ['street' => '1 main st', 'location' => 'sydney', 'post_code' => '2323'],
-    'type' => 'pet_shop'
-];
-//$created_entity = $usergrid->application()->EntityJsonPost($custom_entity);
-//var_dump($created_entity->entities);
-
-// update custom Entity
-$custom_entity_edit = [
-    'collection' => 'shops',
-    'entity_name_or_uuid' => '918a044a-618a-11e4-8c11-253e9c3723a9',
-    ['adr' => ['street' => '3 main st', 'location' => 'act', 'post_code' => '3323']]
-];
-$edited_entity = $usergrid->application()->EntityPut($custom_entity_edit);
-
-
-/** Usergrid Facades On */
-
-//create a bootstrap instance and then call the static instance method on the Usergrid facade
-$bootstrapper2 = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper2);
-
-
-// find users with query
-$fUser = Usergrid::users()->find(['ql' => 'select * where activated=true']);
-
-$fUser_iterator = Usergrid::usersIterator();
-
-foreach ($fUser_iterator as $iUser) {
-    var_dump($iUser);
-    var_dump("---------------------------------------------------------------------------------");
-}
-
-// create new user
-$fNew_user = [
-    'name' => 'jasonk',
-    'username' => 'JasonK2',
-    'email' => 'jaso2n@example.com',
-    'password' => 'some_password'
-];
-$fCreated_user = Usergrid::users()->create($fNew_user);
-//var_dump($fCreated_user->entities);
-
-//Update Users by name or uuid
-$fNew_email = ['email' => 'jason@example', 'entity_name_or_uuid' => 'benn'];
-$fUpdated_user = Usergrid::users()->update($fNew_email);
-//var_dump($fUpdated_user->entities);
-
-// delete a user
-$fDeleted_user = Usergrid::users()->delete(['entity_name_or_uuid' => 'benn']);
-//var_dump($fDeleted_user->entities);
-
-//get custom collection
-$fCustom_collection = Usergrid::application()->EntityGet(['collection' => 'shops']);
-//var_dump($custom_collection->get('entities'));
-
-//get custom collection with query
-$fCustom_collection_query = Usergrid::application()->EntityGet([
-    'collection' => 'shops',
-    'ql' => "select * where country='aus'"
-]);
-//var_dump($custom_collection_query->get('name'));
-
-// Post custom collection as JSON data
-$fCustom_entity = [
-    'collection' => 'shops',
-    'name' => 'shop_name3',
-    'adr' => ['street' => '1 main st', 'location' => 'sydney', 'post_code' => '2323'],
-    'type' => 'pet_shop'
-];
-$fCreated_entity = Usergrid::applictions()->EntityJsonPost($custom_entity);
-//var_dump($fCreated_entity->entities);
-
-// update entity
-$fCustom_entity_edit = [
-    'collection' => 'shops',
-    'entity_name_or_uuid' => 'shop_name2',
-    ['adr' => ['street' => '3 main st', 'location' => 'act', 'post_code' => '3323']]
-];
-$fEdited_entity = Usergrid::applications()->EntityPut($fCustom_entity_edit);
-//var_dump($fEdited_entity->entities);
-
-
-/** Relationships */
-$related_data = [
-    'collection' => 'required',
-    'entity_id' => 'required',
-    'relationship' => 'required',
-    'ql' => 'optional'
-];
-$get_relationship = Usergrid::application()->GetRelationship($related_data);
-
-
-$create_relationship_data = [
-    'collection' => 'required',
-    'first_entity_id' => 'required',
-    'relationship' => 'required',
-    'second_entity_id' => 'required'
-];
-$new_relationship = Usergrid::application()->CreateRelationship($create_relationship_data);
-
-
-/** Groups  */
-
-//add user to group
-$fAdd_user_to_group_data = [
-    'entity_name_or_uuid' => 'group_name',
-    'user_name_or_uuid' => 'username'
-];
-$fAdded_user_to_group = Usergrid::groups()->addUser($fAdd_user_to_group_data);
-
-//delete user from group
-$fDeleted_user_from_group = Usergrid::groups()->deleteUser($fAdd_user_to_group_data);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/management/management.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/management/management.php b/sdks/php5/apache-usergrid/Examples/management/management.php
deleted file mode 100644
index cfc5d61..0000000
--- a/sdks/php5/apache-usergrid/Examples/management/management.php
+++ /dev/null
@@ -1,91 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-/**
- * When working with the management api any calls that require a application to target will use the default app name set in the config but some times you may want to
- * make a api call to a different application which is possible when the url requires a application name it taken from the config but if you pass in a different application
- * name in the method arguments it will override the default application name just for that api call so If I wanted to add a user to two application I could make the same call
- * twice but pass in a application name only for the 2nd call.
- */
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-
-// Get organization activity
-$activity_feed = Usergrid::management()->OrgFeedGet();
-
-// get org details
-$organization_details = Usergrid::management()->OrgGet();
-
-//get organizations application
-$organization_applications = Usergrid::management()->OrgAppsGet();
-
-//create application
-$app = ['name' => 'app name -- required'];
-$new_application = Usergrid::management()->OrgAppsJsonPost($app);
-
-// delete application
-$deleted_application = Usergrid::management()->OrgAppDelete($app);
-
-//get irg admin users
-$organization_admin_users = Usergrid::management()->OrgUsersGet();
-
-/** There are many more api calls just look at the management manifest file to get the method name's and arguments to pass .
- * The management manifest file is a copy of the swagger file for usergrid so you can also run the swagger UI tool on your usergrid install as well.
- */
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/messages/data.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/messages/data.php b/sdks/php5/apache-usergrid/Examples/messages/data.php
deleted file mode 100644
index 5d00ec4..0000000
--- a/sdks/php5/apache-usergrid/Examples/messages/data.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-$message = [];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/messages/messages.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/messages/messages.php b/sdks/php5/apache-usergrid/Examples/messages/messages.php
deleted file mode 100644
index 0eded4a..0000000
--- a/sdks/php5/apache-usergrid/Examples/messages/messages.php
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-include('data.php');
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/notifications/data.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/notifications/data.php b/sdks/php5/apache-usergrid/Examples/notifications/data.php
deleted file mode 100644
index 0efdf85..0000000
--- a/sdks/php5/apache-usergrid/Examples/notifications/data.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-$notification = [];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/notifications/notifications.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/notifications/notifications.php b/sdks/php5/apache-usergrid/Examples/notifications/notifications.php
deleted file mode 100644
index 1a76ef8..0000000
--- a/sdks/php5/apache-usergrid/Examples/notifications/notifications.php
+++ /dev/null
@@ -1,86 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-
-include('data.php');
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1', // set manifest version
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => null, //leave as default or change to your own custom folder
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => '',
-        'password' => '',
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-
-// to user
-$to_user = Usergrid::notifications()->toUser();
-
-
-//to users
-$to_users = Usergrid::notifications()->toUsers();
-
-
-//to group
-$to_group = Usergrid::notifications()->toGroup();
-
-
-// to groups
-$to_groups = Usergrid::notifications()->toGroups();
-
-
-// to device
-$to_device = Usergrid::notifications()->toDevice();
-
-
-// to devices
-$to_devices = Usergrid::notifications()->toDevices();

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/Examples/notifications/notifiers.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/Examples/notifications/notifiers.php b/sdks/php5/apache-usergrid/Examples/notifications/notifiers.php
deleted file mode 100644
index e32f6f4..0000000
--- a/sdks/php5/apache-usergrid/Examples/notifications/notifiers.php
+++ /dev/null
@@ -1,79 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-include('vendor/autoload.php');
-include('data.php');
-
-use Apache\Usergrid\Native\Facades\Usergrid;
-use Apache\Usergrid\Native\UsergridBootstrapper;
-
-
-/** Source your config from file I'm using array here just for ease of use.
- * When using Laravel Framework publish the package config file when using with
- * other modern PHP frameworks just use their default config system .
- */
-$config = [
-    'usergrid' => [
-        'url' => 'https://api.usergrid.com',
-        'version' => '1.0.1',
-        'orgName' => '',
-        'appName' => '',
-        'manifestPath' => './src/Manifests',
-        'clientId' => '',
-        'clientSecret' => '',
-        'username' => null,
-        'password' => null,
-        /**
-         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-         * Token from.  You have two options here one is 'application' the other is 'organization'
-         *
-         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
-         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
-         */
-        'auth_type' => 'organization',
-        /** The Grant Type to use
-         *
-         * This has to be set to one of the 2 grant types that Apache Usergrid
-         * supports which at the moment is client_credentials or password but at
-         * 2 level organization or application
-         */
-        'grant_type' => 'client_credentials',
-        /**
-         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-         * */
-        'enable_oauth2_plugin' => true
-    ]
-];
-
-// You need to add a push cert to this folder and pass the path in the apple_notifier_data array
-
-$bootstrapper = new UsergridBootstrapper($config);
-Usergrid::instance($bootstrapper);
-
-//create Apple Notifier
-$apple_notifier_data = [
-    'name' => 'apple_test',
-    'environment' => 'development',
-    'p12Certificate' => @'pushtest_dev.p12'
-];
-$apple_notifier = Usergrid::notifiers()->createApple($apple_notifier_data);
-
-// create Google Notifier
-$google_notifier_data = [
-    'name' => 'google_test',
-    'apiKey' => 'AIzaSyCIH_7WC0mOqBGMOXyQnFgrBpOePgHvQJM',
-    'provider' => 'google'
-];
-$google_notifier = Usergrid::notifiers()->createGoogle($google_notifier_data);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/LICENSE b/sdks/php5/apache-usergrid/LICENSE
deleted file mode 100644
index e06d208..0000000
--- a/sdks/php5/apache-usergrid/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-Apache License
-                           Version 2.0, January 2004
-                        http://www.apache.org/licenses/
-
-   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
-   1. Definitions.
-
-      "License" shall mean the terms and conditions for use, reproduction,
-      and distribution as defined by Sections 1 through 9 of this document.
-
-      "Licensor" shall mean the copyright owner or entity authorized by
-      the copyright owner that is granting the License.
-
-      "Legal Entity" shall mean the union of the acting entity and all
-      other entities that control, are controlled by, or are under common
-      control with that entity. For the purposes of this definition,
-      "control" means (i) the power, direct or indirect, to cause the
-      direction or management of such entity, whether by contract or
-      otherwise, or (ii) ownership of fifty percent (50%) or more of the
-      outstanding shares, or (iii) beneficial ownership of such entity.
-
-      "You" (or "Your") shall mean an individual or Legal Entity
-      exercising permissions granted by this License.
-
-      "Source" form shall mean the preferred form for making modifications,
-      including but not limited to software source code, documentation
-      source, and configuration files.
-
-      "Object" form shall mean any form resulting from mechanical
-      transformation or translation of a Source form, including but
-      not limited to compiled object code, generated documentation,
-      and conversions to other media types.
-
-      "Work" shall mean the work of authorship, whether in Source or
-      Object form, made available under the License, as indicated by a
-      copyright notice that is included in or attached to the work
-      (an example is provided in the Appendix below).
-
-      "Derivative Works" shall mean any work, whether in Source or Object
-      form, that is based on (or derived from) the Work and for which the
-      editorial revisions, annotations, elaborations, or other modifications
-      represent, as a whole, an original work of authorship. For the purposes
-      of this License, Derivative Works shall not include works that remain
-      separable from, or merely link (or bind by name) to the interfaces of,
-      the Work and Derivative Works thereof.
-
-      "Contribution" shall mean any work of authorship, including
-      the original version of the Work and any modifications or additions
-      to that Work or Derivative Works thereof, that is intentionally
-      submitted to Licensor for inclusion in the Work by the copyright owner
-      or by an individual or Legal Entity authorized to submit on behalf of
-      the copyright owner. For the purposes of this definition, "submitted"
-      means any form of electronic, verbal, or written communication sent
-      to the Licensor or its representatives, including but not limited to
-      communication on electronic mailing lists, source code control systems,
-      and issue tracking systems that are managed by, or on behalf of, the
-      Licensor for the purpose of discussing and improving the Work, but
-      excluding communication that is conspicuously marked or otherwise
-      designated in writing by the copyright owner as "Not a Contribution."
-
-      "Contributor" shall mean Licensor and any individual or Legal Entity
-      on behalf of whom a Contribution has been received by Licensor and
-      subsequently incorporated within the Work.
-
-   2. Grant of Copyright License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      copyright license to reproduce, prepare Derivative Works of,
-      publicly display, publicly perform, sublicense, and distribute the
-      Work and such Derivative Works in Source or Object form.
-
-   3. Grant of Patent License. Subject to the terms and conditions of
-      this License, each Contributor hereby grants to You a perpetual,
-      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
-      (except as stated in this section) patent license to make, have made,
-      use, offer to sell, sell, import, and otherwise transfer the Work,
-      where such license applies only to those patent claims licensable
-      by such Contributor that are necessarily infringed by their
-      Contribution(s) alone or by combination of their Contribution(s)
-      with the Work to which such Contribution(s) was submitted. If You
-      institute patent litigation against any entity (including a
-      cross-claim or counterclaim in a lawsuit) alleging that the Work
-      or a Contribution incorporated within the Work constitutes direct
-      or contributory patent infringement, then any patent licenses
-      granted to You under this License for that Work shall terminate
-      as of the date such litigation is filed.
-
-   4. Redistribution. You may reproduce and distribute copies of the
-      Work or Derivative Works thereof in any medium, with or without
-      modifications, and in Source or Object form, provided that You
-      meet the following conditions:
-
-      (a) You must give any other recipients of the Work or
-          Derivative Works a copy of this License; and
-
-      (b) You must cause any modified files to carry prominent notices
-          stating that You changed the files; and
-
-      (c) You must retain, in the Source form of any Derivative Works
-          that You distribute, all copyright, patent, trademark, and
-          attribution notices from the Source form of the Work,
-          excluding those notices that do not pertain to any part of
-          the Derivative Works; and
-
-      (d) If the Work includes a "NOTICE" text file as part of its
-          distribution, then any Derivative Works that You distribute must
-          include a readable copy of the attribution notices contained
-          within such NOTICE file, excluding those notices that do not
-          pertain to any part of the Derivative Works, in at least one
-          of the following places: within a NOTICE text file distributed
-          as part of the Derivative Works; within the Source form or
-          documentation, if provided along with the Derivative Works; or,
-          within a display generated by the Derivative Works, if and
-          wherever such third-party notices normally appear. The contents
-          of the NOTICE file are for informational purposes only and
-          do not modify the License. You may add Your own attribution
-          notices within Derivative Works that You distribute, alongside
-          or as an addendum to the NOTICE text from the Work, provided
-          that such additional attribution notices cannot be construed
-          as modifying the License.
-
-      You may add Your own copyright statement to Your modifications and
-      may provide additional or different license terms and conditions
-      for use, reproduction, or distribution of Your modifications, or
-      for any such Derivative Works as a whole, provided Your use,
-      reproduction, and distribution of the Work otherwise complies with
-      the conditions stated in this License.
-
-   5. Submission of Contributions. Unless You explicitly state otherwise,
-      any Contribution intentionally submitted for inclusion in the Work
-      by You to the Licensor shall be under the terms and conditions of
-      this License, without any additional terms or conditions.
-      Notwithstanding the above, nothing herein shall supersede or modify
-      the terms of any separate license agreement you may have executed
-      with Licensor regarding such Contributions.
-
-   6. Trademarks. This License does not grant permission to use the trade
-      names, trademarks, service marks, or product names of the Licensor,
-      except as required for reasonable and customary use in describing the
-      origin of the Work and reproducing the content of the NOTICE file.
-
-   7. Disclaimer of Warranty. Unless required by applicable law or
-      agreed to in writing, Licensor provides the Work (and each
-      Contributor provides its Contributions) on an "AS IS" BASIS,
-      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-      implied, including, without limitation, any warranties or conditions
-      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
-      PARTICULAR PURPOSE. You are solely responsible for determining the
-      appropriateness of using or redistributing the Work and assume any
-      risks associated with Your exercise of permissions under this License.
-
-   8. Limitation of Liability. In no event and under no legal theory,
-      whether in tort (including negligence), contract, or otherwise,
-      unless required by applicable law (such as deliberate and grossly
-      negligent acts) or agreed to in writing, shall any Contributor be
-      liable to You for damages, including any direct, indirect, special,
-      incidental, or consequential damages of any character arising as a
-      result of this License or out of the use or inability to use the
-      Work (including but not limited to damages for loss of goodwill,
-      work stoppage, computer failure or malfunction, or any and all
-      other commercial damages or losses), even if such Contributor
-      has been advised of the possibility of such damages.
-
-   9. Accepting Warranty or Additional Liability. While redistributing
-      the Work or Derivative Works thereof, You may choose to offer,
-      and charge a fee for, acceptance of support, warranty, indemnity,
-      or other liability obligations and/or rights consistent with this
-      License. However, in accepting such obligations, You may act only
-      on Your own behalf and on Your sole responsibility, not on behalf
-      of any other Contributor, and only if You agree to indemnify,
-      defend, and hold each Contributor harmless for any liability
-      incurred by, or claims asserted against, such Contributor by reason
-      of your accepting any such warranty or additional liability.
-
-   END OF TERMS AND CONDITIONS
-
-   APPENDIX: How to apply the Apache License to your work.
-
-      To apply the Apache License to your work, attach the following
-      boilerplate notice, with the fields enclosed by brackets "{}"
-      replaced with your own identifying information. (Don't include
-      the brackets!)  The text should be enclosed in the appropriate
-      comment syntax for the file format. We also recommend that a
-      file or class name and description of purpose be included on the
-      same "printed page" as the copyright notice for easier
-      identification within third-party archives.
-
-   Copyright {yyyy} {name of copyright owner}
-
-   Licensed under the Apache License, Version 2.0 (the "License");
-   you may not use this file except in compliance with the License.
-   You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/README.md
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/README.md b/sdks/php5/apache-usergrid/README.md
deleted file mode 100644
index 567f3f1..0000000
--- a/sdks/php5/apache-usergrid/README.md
+++ /dev/null
@@ -1,219 +0,0 @@
-# README 
-
-This a Guzzle Web Service Client and Service Descriptor to work with the Apache Usergrid Management and Application API . 
-
-## Getting Started 
-
-install as composer package by adding this to your composer.json file.
-
-``` 
-    "apache-usergrid" : "dev-master" 
-```
-
-and add the URL to the repositories section within your composer.json file.
-
-```
-    "repositories": [{
-        "type" : "vcs",
-        "url" : "https://apps4u@bitbucket.org/apps4u/apache-usergrid.git"
-    }]
-```
-
-import the classes ``` include autoload.php ``` then create a new instance of the class with a path to you config file
-or native use just create a config file
-
-
-
-    use Apache\Usergrid\UsergridBootstrapper;
-    $config = [    
-    'usergrid' => [
-                       'url' => 'https://api.usergrid.com',
-                       'version' => '1.0.0',
-                       'orgName' => '',
-                       'appName' => '',
-                       'manifestPath' => './src/Manifests',
-                       'clientId' => '',
-                       'clientSecret' => '',
-                       'username' => '',
-                       'password' => '',
-                       /**
-                        * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
-                        * Token from.  You have two options here one is 'application' the other is 'organization'
-                        *
-                        *  organization will get the the token from http://example.com/management/token using  client_credentials or password grant type
-                        *  application will get the token from http://example.com/org_name/app_name/token using client_credentials or password grant type
-                        */
-                       'auth_type' => 'application',
-                       /** The Grant Type to use
-                        *
-                        * This has to be set to one of the 2 grant types that Apache Usergrid
-                        * supports which at the moment is client_credentials or password.
-                        */
-                       'grant_type' => 'client_credentials'
-                        /**
-                        * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
-                        * */
-                       'enable_oauth2_plugin' => true
-                   ]
-             ];
-                   
-                   $bootstrap = new UsergridBootstrapper($config);
-                   $usergrid = $bootstrap->createUsergrid();
-                   $collection =$usergrid->application()->getEntity(['collection' => 'shops']);
-
-
-## Or if you like Static Facades
-
-```
-     $bootstrap = new UsergridBootstrapper($config);
-     Usergrid::instance($bootstrap);
-     $res = Usergrid::application()->EntityGet(['collection' => 'shops']);
-```
-
-
-### Laravel
-
-In Laravel once you have install the composer package you then publish the config file like ```php artisan config:publish apache/usergrid ``` which will publish the config file to the app/config/packages/apache/usergrid/config.php 
-then add your client_id and secret to the config file the set the service provider in the app/config.php providers array ```Apache\Usergrid\Laravel\ApacheUsergridServiceProvider``` and add the alias to
-the aliases array ```'Usergrid' => 'Apache\Usergrid\Laravel\Facades\Usergrid``` to be able to access class via a Facade. Example for Laravel
-
-```
-    $collection = Usergrid::application()->EntityGet(['collection' => 'shops']);
-```
-
-## how it works
-
- You have one main client called Usergrid so if I wanted to call the Management Api and I have Facades enabled then
- I would call like this ```Usergrid::Management->OrgAppsGet();``` or ```Usergrid::Application->EntityGet();```
- 
- There is one top level manifest file called Manifest.php and contain only top level Guzzle service descriptor properties and a empty operations array so 
- when calling ```php Usergrid::Management()->OrgAppsGet() ```  the Main Manifest file has the operation array filled in by the Management Manifest files operations array
- and they are cached by the Usergrid web service client. Calls on the Usergrid client are like magic method in the sense that ```php Usergrid::Management()-> method``` call is not
- backed by a Management class or method its the Manifest that it being selected . Also by using Facades all method are like static method and fit in with newer PHP frameworks just like using the
- AWS PHP SDK when calling enableFacades() on the AWS factory method.
- 
- All responses are subclasses of Illuminate\Support\Collection class so all collection methods are available to call on your response model eg: first(), get(), map(), fetch(), hasKey(), hasValue(), etc.
- this is not to mistake this with a Usergrid collection which is like your DB table they too are collection object but if you get a response of a single entity then its a Collection with a count of 1.
- 
- 
- 
-### Error Handling 
-
-All HTTP and Server error returned by the Usergrid API have error classes attached to the services descriptors so to handle error's that you want too, Just catch the correct exception eg. resource not found.
-
-```
-    try {
-     $collection = Usergrid::Application()->GetEntity(['collection' => 'shops', 'uuid' => 'not found uuid']);
-    } catch(NotFoundException $e) {
-        // Handle resource not found
-    }
-```
- 
-### Authentication
-
-  You can manage your own Oauth 2 flow by setting the enable_oauth2_plugin config setting to false then you need to call the Token api or get the token from elsewhere and then set the token on the usergrid instance.
-  By default this will manage Oauth2 flow for you and I recommend that you leave it set to true. But if you want to do it yourself set the config setting to false and then do something like this.
-  
-```
-    $res  =  Usergrid::management()->authPasswordGet($array);
-    $token = $res->get('access_token');
-    Usergrid::setToken($token)->users()->findById(['uuid' => '1234']);
-```
- 
- Authentication for Apache Usergrid uses OAuth-2 protocol and has 4 levels of authentication.
- 
-* Organization Token  Top level organization access the token is for the organization.
-* Organization Admin Token Top level Admin user this token is the organizations admin users.
-* Application Token  Per Application token that is for the application.
-*  Application User Token User level access this token is for a logged in user.
- 
- The Organization and Application token's when using client_credentials should only be used in a server side application as it has full access to all resources.
- The Organization Token can access all applications and edit Organization details. The Application token has full access to all application 
- resources. The Admin user token is the organization admin user so it too has access to all Applications and Organizations and the last level which is a User
- Token that is a per application user and will have access to all resources that roles attached to that user can access.
- 
-So there are two settings in the config that controls which type of token you get.
-the ```'auth_type' => 'application' ``` controls the level you get Organization or Application and the ``` 'grant_type' => 'client_credentials'``` controls
-which type of credentials you use which can be either `client_credentials` or `password` using client_id & client_secret or username & password.
-
-### Result Iteration
-Apache Usergrid has a default paging size of 10 records so if you ask for a collection that has more then 10 result (entities) then it will return 
-a Cursor so you can pass it to the next request to get then next lot of 10 results so Ive made this easier. Using manifest version 1.0.1 and above you can now use a resource iterator  
-that will return all entities for you in one request. So again let the SDK do the hard work for you. Resource Iterators as lazy loaded so they only make the api call if the data is needed 
-for example when you first make the call no data is requested from the network but as soon as you dereference the data then the first page is requested and the 2nd page is not requested till
-you request the data for example if I used it in a foreach loop it will make a network request for the next page of data only after the loop has gone through the current page count and if you cancel the 
-foreach loop then it wont request any more data the default page size is 20 for resource iterators.
-
-The SDK will check each response to see if their is a cursor and if there is it will get the next set till all entities are returned.
-```
-    $allDevices = Usergrid::DevicesIterator();
-    foreach($allDevices as $device) {
-    // this will have all devices. 
-    }
-```
-# NEW feature - Attributes
-### Attributes (relationships) 
-The Usergrid PHP SDK has api call on the application service to get a related models but it requires that you make two api calls one to get the entity then a 2nd to get the relationship eg:
-
-```
-$users = Usergrid::users()->all(['limit' => 1]);
-$user_uuid = $users-entities->fetch('uuid');
-$data = [ 'collection' => 'users', 'entity_id' => $user_uuid, 'relationship' => 'devices'];
-$device = Usergrid::application()->GetRelationship($data);
-```
-
-Now the data we require for you to make the relationship api call is already in the SDK we should not force you to make a 2nd api call and give us data we already have. so now you don't need to any more. Just access the default relationships as a property on your response Model.
-
-```
-    $users = Usergrid::users()->all();
-    $user = $users->entities->get(0);
-    $device = $user->device;
-```
-
-that's it, So the take away point is let the SDK do the work for you and if you create custom service descriptors and model classes for your custom collection then look at the User response
-model class at it's deviceAttribute method to see how you can either add it to your custom collections or add custom relationship attributes to the default collections. Remember the SDK is designed
-for you to be able to extend the Guzzle service descriptors (manifest files).
-
-
-### HTTP headers and UserAgents
-
- When working with http clients & server system you may want to sett additional HTTP Headers. Ive have made this easy as well on the Usergrid class you 
- can set any http headers or access token or user agent when calling the set method it will append new headers or replace headers already set so if you 
- have some customer analytics set up on your version of usergrid server then just pass the headers you like in a fluent way eg:
- ``` Usergrid::setHeaders(['BAAS-PLATFORM-ANALYTICS' => 'user001'])->users()->findById(['uuid' => '12343']); ```
- 
-
-
-## Manifest Files (Guzzle & Swagger  Service Descriptors)
-
-All the files in the manifest folder are just temp file the final Service Descriptors are versioned so
-the real files are in the manifest/1.0.0 folder so as usergrid is updated new versions can be added like 1.1.0 etc.
-Ill leave the other manifest file there for now but will cleanup when Apache Usergrid accepts this library.
-
-## designs guidelines
-
-The design of this is to make it easy to add to existing project and be able to map Model objects in your project 
-to response models for example in my project I have a organization object that is saved in a mysql database and I can
-call a Usergrid Api call on that model object just like using the Usergrid api class eg:
-``` Usergrid::Management->putOrganization($data_array) ``` is the same as
-``` Organization::put($data_array) ``` how to do this is beyond the scope of the SDK but its not hard to create 
-Gateway Objects using php Traits
-
-## PHPUnit Tests
-Some unit tests require a internet connection and a usergrid install so they have been marked with a phpunit @group annotation so to run the tests without a usergrid install just pass the ```--exclude-group internet``` as a option on the command line or IDE setting
-that will exclude the few tests that require access to usergrid which I've limited to only a few unit tests like testing if it can get a oauth2 access_token. 
-
-## Javascript
-
-There is a javascript api to go with this for example I have a site that uses the javascript sdk to login to Apache Usergrid then it send the token server side 
-to be used in api calls on behalf of the logged in user. You can find this javascript sdk in my public git repo it requires one extra config setting and then you include
-the javascript file in your page  It's set to works with Laravel as it posts the token to a route but it would not be hard to use else where just create uri it can post the token too. Its not part of this SDK so think
-of it as a helper as some times it good to have access to both world server side calls for long running or large result sets and Ajax calls to update UI using the one login token for both type of calls.
-
-
-### Contribution guidelines
-* Please help if you like this.
-* Writing tests
-* Code review
-* Code
-* Manifest files

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/TODO.md
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/TODO.md b/sdks/php5/apache-usergrid/TODO.md
deleted file mode 100644
index 9038491..0000000
--- a/sdks/php5/apache-usergrid/TODO.md
+++ /dev/null
@@ -1,2 +0,0 @@
-## To Do ##
-PHP unit tests , I need to create test for most API calls 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/composer.json
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/composer.json b/sdks/php5/apache-usergrid/composer.json
deleted file mode 100644
index 14341a9..0000000
--- a/sdks/php5/apache-usergrid/composer.json
+++ /dev/null
@@ -1,40 +0,0 @@
-{
-    "name": "apache/usergrid",
-    "description": "Apache Usergrid PHP SDK guzzle web service client and service descriptor to interact with usergrid management and application api",
-    "minimum-stability": "stable",
-    "license": "Apache",
-    "authors": [
-        {
-            "name": "Jason Kristian",
-            "email": "jasonk@apps4u.com.au"
-        }
-    ],
-    "repositories": [
-        {
-            "type" : "vcs",
-            "url" : "https://apps4u@bitbucket.org/apps4u/apache-usergrid.git"
-        }
-    ],
-    "require": {
-        "guzzle/guzzle": "3.9.*",
-        "illuminate/support": "~4.2",
-        "nesbot/carbon": "~1.0"
-
-    },
-    "require-dev": {
-        "mockery/mockery": "~0.9",
-        "phpunit/phpunit": "~4.0"
-    },
-    "autoload": {
-        "classmap": [],
-        "psr-4": {
-            "Apache\\Usergrid\\": "src/"
-        }
-    },
-    "extra": {
-        "branch-alias": {
-            "dev-master": "master"
-        }
-    }
-
-}


[23/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/composer.lock
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/composer.lock b/sdks/other/php5/apache-usergrid/composer.lock
new file mode 100644
index 0000000..3060421
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/composer.lock
@@ -0,0 +1,1225 @@
+{
+    "_readme": [
+        "This file locks the dependencies of your project to a known state",
+        "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
+        "This file is @generated automatically"
+    ],
+    "hash": "f77c404fc8b03f21424d391e5451af8a",
+    "packages": [
+        {
+            "name": "guzzle/guzzle",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/guzzle/guzzle3.git",
+                "reference": "5e6fb7097efac7180bd75006079144025255eb63"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/guzzle/guzzle3/zipball/5e6fb7097efac7180bd75006079144025255eb63",
+                "reference": "5e6fb7097efac7180bd75006079144025255eb63",
+                "shasum": ""
+            },
+            "require": {
+                "ext-curl": "*",
+                "php": ">=5.3.3",
+                "symfony/event-dispatcher": "~2.1"
+            },
+            "replace": {
+                "guzzle/batch": "self.version",
+                "guzzle/cache": "self.version",
+                "guzzle/common": "self.version",
+                "guzzle/http": "self.version",
+                "guzzle/inflection": "self.version",
+                "guzzle/iterator": "self.version",
+                "guzzle/log": "self.version",
+                "guzzle/parser": "self.version",
+                "guzzle/plugin": "self.version",
+                "guzzle/plugin-async": "self.version",
+                "guzzle/plugin-backoff": "self.version",
+                "guzzle/plugin-cache": "self.version",
+                "guzzle/plugin-cookie": "self.version",
+                "guzzle/plugin-curlauth": "self.version",
+                "guzzle/plugin-error-response": "self.version",
+                "guzzle/plugin-history": "self.version",
+                "guzzle/plugin-log": "self.version",
+                "guzzle/plugin-md5": "self.version",
+                "guzzle/plugin-mock": "self.version",
+                "guzzle/plugin-oauth": "self.version",
+                "guzzle/service": "self.version",
+                "guzzle/stream": "self.version"
+            },
+            "require-dev": {
+                "doctrine/cache": "~1.3",
+                "monolog/monolog": "~1.0",
+                "phpunit/phpunit": "3.7.*",
+                "psr/log": "~1.0",
+                "symfony/class-loader": "~2.1",
+                "zendframework/zend-cache": "2.*,<2.3",
+                "zendframework/zend-log": "2.*,<2.3"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "3.9-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Guzzle": "src/",
+                    "Guzzle\\Tests": "tests/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Michael Dowling",
+                    "email": "mtdowling@gmail.com",
+                    "homepage": "https://github.com/mtdowling"
+                },
+                {
+                    "name": "Guzzle Community",
+                    "homepage": "https://github.com/guzzle/guzzle/contributors"
+                }
+            ],
+            "description": "Guzzle is a PHP HTTP client library and framework for building RESTful web service clients",
+            "homepage": "http://guzzlephp.org/",
+            "keywords": [
+                "client",
+                "curl",
+                "framework",
+                "http",
+                "http client",
+                "rest",
+                "web service"
+            ],
+            "time": "2014-10-29 23:08:23"
+        },
+        {
+            "name": "illuminate/support",
+            "version": "4.2.x-dev",
+            "target-dir": "Illuminate/Support",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/illuminate/support.git",
+                "reference": "4831699d6bcddd766e3cebbd8279976854d37027"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/illuminate/support/zipball/4831699d6bcddd766e3cebbd8279976854d37027",
+                "reference": "4831699d6bcddd766e3cebbd8279976854d37027",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.4.0"
+            },
+            "require-dev": {
+                "jeremeamia/superclosure": "~1.0.1",
+                "patchwork/utf8": "1.1.*"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "4.2-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Illuminate\\Support": ""
+                },
+                "files": [
+                    "Illuminate/Support/helpers.php"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Taylor Otwell",
+                    "email": "taylorotwell@gmail.com"
+                }
+            ],
+            "time": "2014-09-27 01:17:10"
+        },
+        {
+            "name": "nesbot/carbon",
+            "version": "1.13.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/briannesbitt/Carbon.git",
+                "reference": "5cb6e71055f7b0b57956b73d324cc4de31278f42"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/5cb6e71055f7b0b57956b73d324cc4de31278f42",
+                "reference": "5cb6e71055f7b0b57956b73d324cc4de31278f42",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.0"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.0"
+            },
+            "type": "library",
+            "autoload": {
+                "psr-0": {
+                    "Carbon": "src"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Brian Nesbitt",
+                    "email": "brian@nesbot.com",
+                    "homepage": "http://nesbot.com"
+                }
+            ],
+            "description": "A simple API extension for DateTime.",
+            "homepage": "https://github.com/briannesbitt/Carbon",
+            "keywords": [
+                "date",
+                "datetime",
+                "time"
+            ],
+            "time": "2014-09-26 02:52:02"
+        },
+        {
+            "name": "symfony/event-dispatcher",
+            "version": "2.7.x-dev",
+            "target-dir": "Symfony/Component/EventDispatcher",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/symfony/EventDispatcher.git",
+                "reference": "8e5829263631e686bf4d1254b02411263b8fa228"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/8e5829263631e686bf4d1254b02411263b8fa228",
+                "reference": "8e5829263631e686bf4d1254b02411263b8fa228",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "psr/log": "~1.0",
+                "symfony/config": "~2.0",
+                "symfony/dependency-injection": "~2.6",
+                "symfony/expression-language": "~2.6",
+                "symfony/stopwatch": "~2.2"
+            },
+            "suggest": {
+                "symfony/dependency-injection": "",
+                "symfony/http-kernel": ""
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "2.7-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Symfony\\Component\\EventDispatcher\\": ""
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Symfony Community",
+                    "homepage": "http://symfony.com/contributors"
+                },
+                {
+                    "name": "Fabien Potencier",
+                    "email": "fabien@symfony.com"
+                }
+            ],
+            "description": "Symfony EventDispatcher Component",
+            "homepage": "http://symfony.com",
+            "time": "2014-11-10 18:00:54"
+        }
+    ],
+    "packages-dev": [
+        {
+            "name": "doctrine/instantiator",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/doctrine/instantiator.git",
+                "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f976e5de371104877ebc89bd8fecb0019ed9c119",
+                "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3,<8.0-DEV"
+            },
+            "require-dev": {
+                "athletic/athletic": "~0.1.8",
+                "ext-pdo": "*",
+                "ext-phar": "*",
+                "phpunit/phpunit": "~4.0",
+                "squizlabs/php_codesniffer": "2.0.*@ALPHA"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.0.x-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Doctrine\\Instantiator\\": "src"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Marco Pivetta",
+                    "email": "ocramius@gmail.com",
+                    "homepage": "http://ocramius.github.com/"
+                }
+            ],
+            "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors",
+            "homepage": "https://github.com/doctrine/instantiator",
+            "keywords": [
+                "constructor",
+                "instantiate"
+            ],
+            "time": "2014-10-13 12:58:55"
+        },
+        {
+            "name": "mockery/mockery",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/padraic/mockery.git",
+                "reference": "30eb319efcf2ebe6b4529be51f60df78340bdbb5"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/padraic/mockery/zipball/30eb319efcf2ebe6b4529be51f60df78340bdbb5",
+                "reference": "30eb319efcf2ebe6b4529be51f60df78340bdbb5",
+                "shasum": ""
+            },
+            "require": {
+                "lib-pcre": ">=7.0",
+                "php": ">=5.3.2"
+            },
+            "require-dev": {
+                "hamcrest/hamcrest-php": "~1.1",
+                "phpunit/phpunit": "~4.0",
+                "satooshi/php-coveralls": "~0.7@dev"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "0.9.x-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Mockery": "library/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "P�draic Brady",
+                    "email": "padraic.brady@gmail.com",
+                    "homepage": "http://blog.astrumfutura.com"
+                },
+                {
+                    "name": "Dave Marshall",
+                    "email": "dave.marshall@atstsolutions.co.uk",
+                    "homepage": "http://davedevelopment.co.uk"
+                }
+            ],
+            "description": "Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succint API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL). Designed as a drop in alternative to PHPUnit's phpunit-mock-objects library, Mockery is easy to integrate with PHPUnit and can operate alongside phpunit-mock-objects without the World ending.",
+            "homepage": "http://github.com/padraic/mockery",
+            "keywords": [
+                "BDD",
+                "TDD",
+                "library",
+                "mock",
+                "mock objects",
+                "mockery",
+                "stub",
+                "test",
+                "test double",
+                "testing"
+            ],
+            "time": "2014-11-10 08:31:38"
+        },
+        {
+            "name": "phpdocumentor/reflection-docblock",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git",
+                "reference": "fd0ac2007401505fb596fdfb859ec4e103d69e55"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/fd0ac2007401505fb596fdfb859ec4e103d69e55",
+                "reference": "fd0ac2007401505fb596fdfb859ec4e103d69e55",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.0"
+            },
+            "suggest": {
+                "dflydev/markdown": "~1.0",
+                "erusev/parsedown": "~1.0"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "2.0.x-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "phpDocumentor": [
+                        "src/"
+                    ]
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Mike van Riel",
+                    "email": "mike.vanriel@naenius.com"
+                }
+            ],
+            "time": "2014-09-02 14:26:20"
+        },
+        {
+            "name": "phpspec/prophecy",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/phpspec/prophecy.git",
+                "reference": "2bbc78d0b4b1ce8049479395ba950d4b13f21d94"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/phpspec/prophecy/zipball/2bbc78d0b4b1ce8049479395ba950d4b13f21d94",
+                "reference": "2bbc78d0b4b1ce8049479395ba950d4b13f21d94",
+                "shasum": ""
+            },
+            "require": {
+                "doctrine/instantiator": "~1.0,>=1.0.2",
+                "phpdocumentor/reflection-docblock": "~2.0"
+            },
+            "require-dev": {
+                "phpspec/phpspec": "~2.0"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.2.x-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Prophecy\\": "src/"
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Konstantin Kudryashov",
+                    "email": "ever.zet@gmail.com",
+                    "homepage": "http://everzet.com"
+                },
+                {
+                    "name": "Marcello Duarte",
+                    "email": "marcello.duarte@gmail.com"
+                }
+            ],
+            "description": "Highly opinionated mocking framework for PHP 5.3+",
+            "homepage": "http://phpspec.org",
+            "keywords": [
+                "Double",
+                "Dummy",
+                "fake",
+                "mock",
+                "spy",
+                "stub"
+            ],
+            "time": "2014-10-05 19:43:51"
+        },
+        {
+            "name": "phpunit/php-code-coverage",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/php-code-coverage.git",
+                "reference": "21b9006b7ceb7e1cb0b705615af31f67c8cd1692"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/21b9006b7ceb7e1cb0b705615af31f67c8cd1692",
+                "reference": "21b9006b7ceb7e1cb0b705615af31f67c8cd1692",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3",
+                "phpunit/php-file-iterator": "~1.3",
+                "phpunit/php-text-template": "~1.2",
+                "phpunit/php-token-stream": "~1.3",
+                "sebastian/environment": "~1.0",
+                "sebastian/version": "~1.0"
+            },
+            "require-dev": {
+                "ext-xdebug": ">=2.1.4",
+                "phpunit/phpunit": "dev-master"
+            },
+            "suggest": {
+                "ext-dom": "*",
+                "ext-xdebug": ">=2.2.1",
+                "ext-xmlwriter": "*"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "3.0.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sb@sebastian-bergmann.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.",
+            "homepage": "https://github.com/sebastianbergmann/php-code-coverage",
+            "keywords": [
+                "coverage",
+                "testing",
+                "xunit"
+            ],
+            "time": "2014-11-11 14:18:30"
+        },
+        {
+            "name": "phpunit/php-file-iterator",
+            "version": "1.3.4",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/php-file-iterator.git",
+                "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/acd690379117b042d1c8af1fafd61bde001bf6bb",
+                "reference": "acd690379117b042d1c8af1fafd61bde001bf6bb",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "type": "library",
+            "autoload": {
+                "classmap": [
+                    "File/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "include-path": [
+                ""
+            ],
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sb@sebastian-bergmann.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "FilterIterator implementation that filters files based on a list of suffixes.",
+            "homepage": "https://github.com/sebastianbergmann/php-file-iterator/",
+            "keywords": [
+                "filesystem",
+                "iterator"
+            ],
+            "time": "2013-10-10 15:34:57"
+        },
+        {
+            "name": "phpunit/php-text-template",
+            "version": "1.2.0",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/php-text-template.git",
+                "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/206dfefc0ffe9cebf65c413e3d0e809c82fbf00a",
+                "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "type": "library",
+            "autoload": {
+                "classmap": [
+                    "Text/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "include-path": [
+                ""
+            ],
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sb@sebastian-bergmann.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "Simple template engine.",
+            "homepage": "https://github.com/sebastianbergmann/php-text-template/",
+            "keywords": [
+                "template"
+            ],
+            "time": "2014-01-30 17:20:04"
+        },
+        {
+            "name": "phpunit/php-timer",
+            "version": "1.0.5",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/php-timer.git",
+                "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/19689d4354b295ee3d8c54b4f42c3efb69cbc17c",
+                "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "type": "library",
+            "autoload": {
+                "classmap": [
+                    "PHP/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "include-path": [
+                ""
+            ],
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sb@sebastian-bergmann.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "Utility class for timing",
+            "homepage": "https://github.com/sebastianbergmann/php-timer/",
+            "keywords": [
+                "timer"
+            ],
+            "time": "2013-08-02 07:42:54"
+        },
+        {
+            "name": "phpunit/php-token-stream",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/php-token-stream.git",
+                "reference": "f8d5d08c56de5cfd592b3340424a81733259a876"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/f8d5d08c56de5cfd592b3340424a81733259a876",
+                "reference": "f8d5d08c56de5cfd592b3340424a81733259a876",
+                "shasum": ""
+            },
+            "require": {
+                "ext-tokenizer": "*",
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.2"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.3-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Wrapper around PHP's tokenizer extension.",
+            "homepage": "https://github.com/sebastianbergmann/php-token-stream/",
+            "keywords": [
+                "tokenizer"
+            ],
+            "time": "2014-08-31 06:12:13"
+        },
+        {
+            "name": "phpunit/phpunit",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/phpunit.git",
+                "reference": "247756f342dfb0a319f8985ef06f21a00d98b59c"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/247756f342dfb0a319f8985ef06f21a00d98b59c",
+                "reference": "247756f342dfb0a319f8985ef06f21a00d98b59c",
+                "shasum": ""
+            },
+            "require": {
+                "ext-dom": "*",
+                "ext-json": "*",
+                "ext-pcre": "*",
+                "ext-reflection": "*",
+                "ext-spl": "*",
+                "php": ">=5.3.3",
+                "phpspec/prophecy": "~1.2",
+                "phpunit/php-code-coverage": "3.0.*@dev",
+                "phpunit/php-file-iterator": "~1.3.2",
+                "phpunit/php-text-template": "~1.2",
+                "phpunit/php-timer": "~1.0.2",
+                "phpunit/phpunit-mock-objects": "2.4.*@dev",
+                "sebastian/comparator": "1.1.*@dev",
+                "sebastian/diff": "~1.1",
+                "sebastian/environment": "~1.2",
+                "sebastian/exporter": "~1.0",
+                "sebastian/global-state": "1.0.*@dev",
+                "sebastian/version": "~1.0",
+                "symfony/yaml": "~2.0"
+            },
+            "suggest": {
+                "phpunit/php-invoker": "~1.1"
+            },
+            "bin": [
+                "phpunit"
+            ],
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "4.5.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "The PHP Unit Testing framework.",
+            "homepage": "https://phpunit.de/",
+            "keywords": [
+                "phpunit",
+                "testing",
+                "xunit"
+            ],
+            "time": "2014-11-06 08:43:29"
+        },
+        {
+            "name": "phpunit/phpunit-mock-objects",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git",
+                "reference": "96c5b81f9842f38fe6c73ad0020306cc4862a9e3"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/96c5b81f9842f38fe6c73ad0020306cc4862a9e3",
+                "reference": "96c5b81f9842f38fe6c73ad0020306cc4862a9e3",
+                "shasum": ""
+            },
+            "require": {
+                "doctrine/instantiator": "~1.0,>=1.0.2",
+                "php": ">=5.3.3",
+                "phpunit/php-text-template": "~1.2"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "4.4.*@dev"
+            },
+            "suggest": {
+                "ext-soap": "*"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "2.4.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sb@sebastian-bergmann.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "Mock Object library for PHPUnit",
+            "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/",
+            "keywords": [
+                "mock",
+                "xunit"
+            ],
+            "time": "2014-10-04 10:04:20"
+        },
+        {
+            "name": "sebastian/comparator",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/comparator.git",
+                "reference": "6f67d2ae044ba17ba30573941f4ac96c4777be97"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/6f67d2ae044ba17ba30573941f4ac96c4777be97",
+                "reference": "6f67d2ae044ba17ba30573941f4ac96c4777be97",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3",
+                "sebastian/diff": "~1.1",
+                "sebastian/exporter": "~1.0"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.1"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.1.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Jeff Welch",
+                    "email": "whatthejeff@gmail.com"
+                },
+                {
+                    "name": "Volker Dusch",
+                    "email": "github@wallbash.com"
+                },
+                {
+                    "name": "Bernhard Schussek",
+                    "email": "bschussek@2bepublished.at"
+                },
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Provides the functionality to compare PHP values for equality",
+            "homepage": "http://www.github.com/sebastianbergmann/comparator",
+            "keywords": [
+                "comparator",
+                "compare",
+                "equality"
+            ],
+            "time": "2014-10-21 10:04:18"
+        },
+        {
+            "name": "sebastian/diff",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/diff.git",
+                "reference": "3e22c89be2e1cddf7db89699cb23a9159df12e0c"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3e22c89be2e1cddf7db89699cb23a9159df12e0c",
+                "reference": "3e22c89be2e1cddf7db89699cb23a9159df12e0c",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.2"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.2-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Kore Nordmann",
+                    "email": "mail@kore-nordmann.de"
+                },
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Diff implementation",
+            "homepage": "http://www.github.com/sebastianbergmann/diff",
+            "keywords": [
+                "diff"
+            ],
+            "time": "2014-11-05 15:28:21"
+        },
+        {
+            "name": "sebastian/environment",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/environment.git",
+                "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6e6c71d918088c251b181ba8b3088af4ac336dd7",
+                "reference": "6e6c71d918088c251b181ba8b3088af4ac336dd7",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.3"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.2.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Provides functionality to handle HHVM/PHP environments",
+            "homepage": "http://www.github.com/sebastianbergmann/environment",
+            "keywords": [
+                "Xdebug",
+                "environment",
+                "hhvm"
+            ],
+            "time": "2014-10-25 08:00:45"
+        },
+        {
+            "name": "sebastian/exporter",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/exporter.git",
+                "reference": "c7d59948d6e82818e1bdff7cadb6c34710eb7dc0"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c7d59948d6e82818e1bdff7cadb6c34710eb7dc0",
+                "reference": "c7d59948d6e82818e1bdff7cadb6c34710eb7dc0",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.0"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.0.x-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Jeff Welch",
+                    "email": "whatthejeff@gmail.com"
+                },
+                {
+                    "name": "Volker Dusch",
+                    "email": "github@wallbash.com"
+                },
+                {
+                    "name": "Bernhard Schussek",
+                    "email": "bschussek@2bepublished.at"
+                },
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                },
+                {
+                    "name": "Adam Harvey",
+                    "email": "aharvey@php.net"
+                }
+            ],
+            "description": "Provides the functionality to export PHP variables for visualization",
+            "homepage": "http://www.github.com/sebastianbergmann/exporter",
+            "keywords": [
+                "export",
+                "exporter"
+            ],
+            "time": "2014-09-10 00:51:36"
+        },
+        {
+            "name": "sebastian/global-state",
+            "version": "dev-master",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/global-state.git",
+                "reference": "231d48620efde984fd077ee92916099a3ece9a59"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/231d48620efde984fd077ee92916099a3ece9a59",
+                "reference": "231d48620efde984fd077ee92916099a3ece9a59",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "require-dev": {
+                "phpunit/phpunit": "~4.2"
+            },
+            "suggest": {
+                "ext-uopz": "*"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "1.0-dev"
+                }
+            },
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de"
+                }
+            ],
+            "description": "Snapshotting of global state",
+            "homepage": "http://www.github.com/sebastianbergmann/global-state",
+            "keywords": [
+                "global state"
+            ],
+            "time": "2014-10-06 09:49:11"
+        },
+        {
+            "name": "sebastian/version",
+            "version": "1.0.3",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/sebastianbergmann/version.git",
+                "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43",
+                "reference": "b6e1f0cf6b9e1ec409a0d3e2f2a5fb0998e36b43",
+                "shasum": ""
+            },
+            "type": "library",
+            "autoload": {
+                "classmap": [
+                    "src/"
+                ]
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "BSD-3-Clause"
+            ],
+            "authors": [
+                {
+                    "name": "Sebastian Bergmann",
+                    "email": "sebastian@phpunit.de",
+                    "role": "lead"
+                }
+            ],
+            "description": "Library that helps with managing the version number of Git-hosted PHP projects",
+            "homepage": "https://github.com/sebastianbergmann/version",
+            "time": "2014-03-07 15:35:33"
+        },
+        {
+            "name": "symfony/yaml",
+            "version": "2.7.x-dev",
+            "target-dir": "Symfony/Component/Yaml",
+            "source": {
+                "type": "git",
+                "url": "https://github.com/symfony/Yaml.git",
+                "reference": "6165f4b5224c22de2873deb6a3a4e622044f0705"
+            },
+            "dist": {
+                "type": "zip",
+                "url": "https://api.github.com/repos/symfony/Yaml/zipball/6165f4b5224c22de2873deb6a3a4e622044f0705",
+                "reference": "6165f4b5224c22de2873deb6a3a4e622044f0705",
+                "shasum": ""
+            },
+            "require": {
+                "php": ">=5.3.3"
+            },
+            "type": "library",
+            "extra": {
+                "branch-alias": {
+                    "dev-master": "2.7-dev"
+                }
+            },
+            "autoload": {
+                "psr-0": {
+                    "Symfony\\Component\\Yaml\\": ""
+                }
+            },
+            "notification-url": "https://packagist.org/downloads/",
+            "license": [
+                "MIT"
+            ],
+            "authors": [
+                {
+                    "name": "Symfony Community",
+                    "homepage": "http://symfony.com/contributors"
+                },
+                {
+                    "name": "Fabien Potencier",
+                    "email": "fabien@symfony.com"
+                }
+            ],
+            "description": "Symfony Yaml Component",
+            "homepage": "http://symfony.com",
+            "time": "2014-11-10 18:00:54"
+        }
+    ],
+    "aliases": [],
+    "minimum-stability": "dev",
+    "stability-flags": [],
+    "prefer-stable": false,
+    "platform": [],
+    "platform-dev": []
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/phpunit.xml
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/phpunit.xml b/sdks/other/php5/apache-usergrid/phpunit.xml
new file mode 100644
index 0000000..ce3af97
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/phpunit.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<phpunit backupGlobals="false"
+         backupStaticAttributes="false"
+         bootstrap="tests/bootstrap.php"
+         colors="true"
+         convertErrorsToExceptions="true"
+         convertNoticesToExceptions="true"
+         convertWarningsToExceptions="true"
+         processIsolation="false"
+         stopOnFailure="false"
+         syntaxCheck="false"
+        >
+    <testsuites>
+        <testsuite name="Apache Usergrid PHP SDK Test Suite">
+            <directory>./tests</directory>
+        </testsuite>
+    </testsuites>
+    <filter>
+        <whitelist>
+            <directory suffix=".php">./src/</directory>
+            <exclude>
+                <file>./src/Laravel/ApacheUsergridServiceProvider.php</file>
+            </exclude>
+        </whitelist>
+    </filter>
+    <logging>
+        <log type="coverage-text" target="php://stdout" showUncoveredFiles="true"/>
+    </logging>
+</phpunit>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/BadRequestException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
new file mode 100644
index 0000000..1e63c40
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/BadRequestException.php
@@ -0,0 +1,34 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+
+namespace Apache\Usergrid\Api\Exception;
+
+
+/**
+ * Class BadRequestException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class BadRequestException extends UsergridException
+{
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
new file mode 100644
index 0000000..c59a683
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/InvalidIdException.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Exception;
+
+
+/**
+ * Class InvalidIdException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class InvalidIdException extends UsergridException
+{
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/NotFoundException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
new file mode 100644
index 0000000..c371538
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/NotFoundException.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Exception;
+
+
+/**
+ * Class NotFoundException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class NotFoundException extends UsergridException
+{
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
new file mode 100644
index 0000000..2286133
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/ServerErrorException.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Exception;
+
+
+/**
+ * Class ServerErrorException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class ServerErrorException extends UsergridException
+{
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
new file mode 100644
index 0000000..3e3ae41
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/UnauthorizedException.php
@@ -0,0 +1,34 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+
+namespace Apache\Usergrid\Api\Exception;
+
+
+/**
+ * Class UnauthorizedException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UnauthorizedException extends UsergridException
+{
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Exception/UsergridException.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Exception/UsergridException.php b/sdks/other/php5/apache-usergrid/src/Api/Exception/UsergridException.php
new file mode 100644
index 0000000..8aedb03
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Exception/UsergridException.php
@@ -0,0 +1,152 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+namespace Apache\Usergrid\Api\Exception;
+
+
+use Exception;
+use Guzzle\Http\Message\Request;
+use Guzzle\Http\Message\Response;
+use Guzzle\Plugin\ErrorResponse\ErrorResponseExceptionInterface;
+use Guzzle\Service\Command\CommandInterface;
+
+/**
+ * Class UsergridException
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class UsergridException extends Exception implements ErrorResponseExceptionInterface
+{
+    /**
+     * The Guzzle request.
+     *
+     * @var \Guzzle\Http\Message\Request
+     */
+    protected $request;
+
+    /**
+     * The Guzzle response.
+     *
+     * @var \Guzzle\Http\Message\Response
+     */
+    protected $response;
+
+    /**
+     * The error type returned by Usergrid.
+     *
+     * @var string
+     */
+    protected $errorType;
+
+    /**
+     * {@inheritDoc}
+     */
+    public static function fromCommand(CommandInterface $command, Response $response)
+    {
+        $errors = json_decode($response->getBody(true), true);
+
+        $type = array_get($errors, 'error.type', null);
+
+        $code = array_get($errors, 'error.code', null);
+
+        $message = array_get($errors, 'error.message', null);
+
+        $class = '\\Apache\\Usergrid\\Api\\Exception\\' . studly_case($type) . 'Exception';
+
+        if (class_exists($class)) {
+            $exception = new $class($message, $response->getStatusCode());
+        } else {
+            $exception = new static($message, $response->getStatusCode());
+        }
+
+        $exception->setErrorType($type);
+
+        $exception->setResponse($response);
+
+        $exception->setRequest($command->getRequest());
+
+        return $exception;
+    }
+
+    /**
+     * Returns the Guzzle request.
+     *
+     * @return \Guzzle\Http\Message\Request
+     */
+    public function getRequest()
+    {
+        return $this->request;
+    }
+
+    /**
+     * Sets the Guzzle request.
+     *
+     * @param  \Guzzle\Http\Message\Request $request
+     * @return void
+     */
+    public function setRequest(Request $request)
+    {
+        $this->request = $request;
+    }
+
+    /**
+     * Returns the Guzzle response.
+     *
+     * @return \Guzzle\Http\Message\Response
+     */
+    public function getResponse()
+    {
+        return $this->response;
+    }
+
+    /**
+     * Sets the Guzzle response.
+     *
+     * @param  \Guzzle\Http\Message\Response $response
+     * @return void
+     */
+    public function setResponse(Response $response)
+    {
+        $this->response = $response;
+    }
+
+    /**
+     * Returns the error type returned by Usergrid.
+     *
+     * @return string
+     */
+    public function getErrorType()
+    {
+        return $this->errorType;
+    }
+
+    /**
+     * Sets the error type returned by Usergrid.
+     *
+     * @param  string $errorType
+     * @return void
+     */
+    public function setErrorType($errorType)
+    {
+        $this->errorType = $errorType;
+    }
+
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Filters/Boolean.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Filters/Boolean.php b/sdks/other/php5/apache-usergrid/src/Api/Filters/Boolean.php
new file mode 100644
index 0000000..021f2fd
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Filters/Boolean.php
@@ -0,0 +1,44 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Filters;
+
+
+/**
+ * Class Boolean
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Boolean
+{
+
+    /**
+     * Converts a boolean into its string representation.
+     *
+     * @param  bool $boolean
+     * @return string
+     */
+    public static function convert($boolean)
+    {
+        return $boolean ? 'true' : 'false';
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Filters/Date.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Filters/Date.php b/sdks/other/php5/apache-usergrid/src/Api/Filters/Date.php
new file mode 100644
index 0000000..8b3c5c6
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Filters/Date.php
@@ -0,0 +1,44 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Filters;
+
+use Carbon\Carbon;
+
+/**
+ * Class Date
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Date
+{
+
+    /**
+     * @param $date
+     * @return static
+     */
+    public static function convert($date)
+    {
+        $date2 = (int)($date / 1000);
+        $date_string = Carbon::createFromTimestampUTC($date2)->toDayDateTimeString();
+        return $date_string;
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Filters/Number.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Filters/Number.php b/sdks/other/php5/apache-usergrid/src/Api/Filters/Number.php
new file mode 100644
index 0000000..41047d3
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Filters/Number.php
@@ -0,0 +1,48 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Filters;
+
+
+/**
+ * Class Number
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Number
+{
+
+    /**
+     * Converts a number into an integer.
+     *
+     * @param  mixed $number
+     * @return int
+     */
+    public static function convert($number)
+    {
+        if (is_string($number) || is_float($number)) {
+            return (int)($number * 100);
+        }
+
+        return $number;
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/GuzzleClient.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/GuzzleClient.php b/sdks/other/php5/apache-usergrid/src/Api/GuzzleClient.php
new file mode 100644
index 0000000..6ef9d8a
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/GuzzleClient.php
@@ -0,0 +1,64 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api;
+
+
+use Guzzle\Service\Client;
+
+/**
+ * Class GuzzleClient
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class GuzzleClient extends Client
+{
+
+    /**
+     * The Usergrid API client instance.
+     *
+     * @var  \Apache\Usergrid\Api\Usergrid
+     */
+    protected $apiClient;
+
+    /**
+     * Returns the Usergrid API client instance.
+     *
+     * @return  \Apache\Usergrid\Api\Usergrid
+     */
+    public function getApiClient()
+    {
+        return $this->apiClient;
+    }
+
+    /**
+     * Sets the Usergrid API client instance.
+     *
+     * @param \Apache\Usergrid\Api\Usergrid $client
+     * @return void
+     */
+    public function setApiClient(Usergrid $client)
+    {
+        $this->apiClient = $client;
+    }
+
+
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Application.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Application.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Application.php
new file mode 100644
index 0000000..336d6d9
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Application.php
@@ -0,0 +1,35 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Application
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Application extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/BaseCollection.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/BaseCollection.php b/sdks/other/php5/apache-usergrid/src/Api/Models/BaseCollection.php
new file mode 100644
index 0000000..4cc7d67
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/BaseCollection.php
@@ -0,0 +1,116 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Apache\Usergrid\Api\Usergrid;
+use Illuminate\Support\Collection;
+
+/**
+ * Class BaseCollection
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class BaseCollection extends Collection
+{
+    /**
+     * List of API response properties that'll be
+     * automatically converted into collections.
+     *
+     * @var array
+     */
+    protected $collections = ['entities'];
+
+    /**
+     * The Usergrid API client instance.
+     *
+     * @var /Apache\Usergrid\Api\Usergrid
+     */
+    protected $apiClient;
+
+    /**
+     * Returns the given key value from the collection.
+     *
+     * @param  mixed $key
+     * @return mixed
+     */
+    public function __get($key)
+    {
+        if (in_array($key, $this->collections) || array_key_exists($key, $this->collections)) {
+            if ($mappedKey = array_get($this->collections, $key, [])) {
+                $key = strstr($mappedKey, '.', true);
+
+                $query = ltrim(strstr($mappedKey, '.'), '.');
+
+                $data = array_get($this->get($key), $query, []);
+            } else {
+                $data = $this->get($key, []);
+            }
+            // create a new class of self so subclasses get new collection from entities of the correct model
+            // eg: before when asking  the User Model for its entities returned a collection of the BaseCollection class not the user class..
+            $class = self::instance($data);
+            //set the api client on collection so api attribute properties can make api calls to get related models
+            $class->setApiClient($this->getApiClient());
+            // return class.
+            return $class;
+
+        }
+        // check to see if the property you asked for is a attribute method
+        if (method_exists($this, $method = "{$key}Attribute")) {
+            return $this->{$method}($this->get($key));
+        }
+
+        //else return key
+        return $this->get($key, null);
+    }
+
+    /**
+     * @param $data
+     * @return static
+     */
+    private static function instance($data)
+    {
+        return new static($data);
+    }
+
+    /**
+     * Returns the Usergrid API client instance.
+     *
+     * @return  /Apache\Usergrid\Api\Usergrid  /Apache\Usergrid\Api\Usergrid
+     */
+    public function getApiClient()
+    {
+        return $this->apiClient;
+    }
+
+    /**
+     * Sets the Usergrid API client instance.
+     *
+     * @param Usergrid $client
+     * @internal param $ /Apache\Usergrid\Api\Usergrid $client
+     * @return void
+     */
+    public function setApiClient(Usergrid $client)
+    {
+        $this->apiClient = $client;
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Collection.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Collection.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Collection.php
new file mode 100644
index 0000000..9fb6d5b
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Collection.php
@@ -0,0 +1,37 @@
+<?php
+
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Collection
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Collection extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Device.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Device.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Device.php
new file mode 100644
index 0000000..403ff8d
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Device.php
@@ -0,0 +1,50 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Device
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Device extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+
+    public function userAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'devices',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'users'
+        ])->toArray();
+    }
+
+    public function notifierAttribute()
+    {
+
+    }
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Entity.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Entity.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Entity.php
new file mode 100644
index 0000000..5063fd0
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Entity.php
@@ -0,0 +1,36 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Entity
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Entity extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Event.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Event.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Event.php
new file mode 100644
index 0000000..2e04595
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Event.php
@@ -0,0 +1,35 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Event
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Event extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Group.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Group.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Group.php
new file mode 100644
index 0000000..6b034ca
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Group.php
@@ -0,0 +1,54 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Group
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Group extends BaseCollection implements ResponseClassInterface
+{
+
+    use GuzzleCommandTrait;
+
+    public function usersAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'groups',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'users'
+        ])->toArray();
+    }
+
+    public function rolesAttribute()
+    {
+        return $this->getApiClient()->application()->GetRelationship([
+            'collection' => 'groups',
+            'entity_id' => $this->entities->fetch('uuid')->first(),
+            'relationship' => 'roles'
+        ])->toArray();
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php b/sdks/other/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
new file mode 100644
index 0000000..e6ccb68
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/GuzzleCommandTrait.php
@@ -0,0 +1,59 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+use Guzzle\Service\Command\OperationCommand;
+
+/**
+ * Class GuzzleCommandTrait
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+trait GuzzleCommandTrait
+{
+    /**
+     * Create a response model object from a completed command.
+     *
+     * @param OperationCommand $command That serialized the request
+     * @return \Illuminate\Support\Collection
+     */
+    public static function fromCommand(OperationCommand $command)
+    {
+        // Initialize the collection
+        $collection = new self($command->getResponse()->json());
+
+        // Set the Usergrid API client on the collection
+        $collection->setApiClient($command->getClient()->getApiClient());
+
+        // Return the collection
+        return $collection;
+    }
+
+    /**
+     *  Returns true if there is a cursor or false if there is not
+     * @return bool
+     */
+    public function hasNextPage()
+    {
+        return $this->has('cursor');
+    }
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Notifier.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Notifier.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Notifier.php
new file mode 100644
index 0000000..a4c21c8
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Notifier.php
@@ -0,0 +1,36 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Application
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Notifier extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Organization.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Organization.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Organization.php
new file mode 100644
index 0000000..d58d3d4
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Organization.php
@@ -0,0 +1,38 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Organization
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Organization extends BaseCollection implements ResponseClassInterface
+{
+
+    use GuzzleCommandTrait;
+
+
+} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Api/Models/Receipt.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Api/Models/Receipt.php b/sdks/other/php5/apache-usergrid/src/Api/Models/Receipt.php
new file mode 100644
index 0000000..bc09235
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Api/Models/Receipt.php
@@ -0,0 +1,36 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Application
+ *
+ * @package    Apache/Usergrid
+ * @version    1.0.0
+ * @author     Jason Kristian <ja...@gmail.com>
+ * @license    Apache License, Version  2.0
+ * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link       http://baas-platform.com
+ */
+class Receipt extends BaseCollection implements ResponseClassInterface
+{
+    use GuzzleCommandTrait;
+
+} 
\ No newline at end of file


[44/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.m
deleted file mode 100755
index 134e34a..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParser.m
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
- Neither the name of the the author nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamParser.h"
-#import "SBJsonTokeniser.h"
-#import "SBJsonStreamParserState.h"
-#import <limits.h>
-
-@implementation SBJsonStreamParser
-
-@synthesize supportMultipleDocuments;
-@synthesize error;
-@synthesize delegate;
-@synthesize maxDepth;
-@synthesize state;
-@synthesize stateStack;
-
-#pragma mark Housekeeping
-
-- (id)init {
-	self = [super init];
-	if (self) {
-		maxDepth = 32u;
-        stateStack = [[NSMutableArray alloc] initWithCapacity:maxDepth];
-        state = [SBJsonStreamParserStateStart sharedInstance];
-		tokeniser = [[SBJsonTokeniser alloc] init];
-	}
-	return self;
-}
-
-- (void)dealloc {
-    self.state = nil;
-}
-
-#pragma mark Methods
-
-- (NSString*)tokenName:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_array_start:
-			return @"start of array";
-			break;
-
-		case sbjson_token_array_end:
-			return @"end of array";
-			break;
-
-		case sbjson_token_number:
-			return @"number";
-			break;
-
-		case sbjson_token_string:
-			return @"string";
-			break;
-
-		case sbjson_token_true:
-		case sbjson_token_false:
-			return @"boolean";
-			break;
-
-		case sbjson_token_null:
-			return @"null";
-			break;
-
-		case sbjson_token_keyval_separator:
-			return @"key-value separator";
-			break;
-
-		case sbjson_token_separator:
-			return @"value separator";
-			break;
-
-		case sbjson_token_object_start:
-			return @"start of object";
-			break;
-
-		case sbjson_token_object_end:
-			return @"end of object";
-			break;
-
-		case sbjson_token_eof:
-		case sbjson_token_error:
-			break;
-	}
-	NSAssert(NO, @"Should not get here");
-	return @"<aaiiie!>";
-}
-
-- (void)maxDepthError {
-    self.error = [NSString stringWithFormat:@"Input depth exceeds max depth of %lu", maxDepth];
-    self.state = [SBJsonStreamParserStateError sharedInstance];
-}
-
-- (void)handleObjectStart {
-	if (stateStack.count >= maxDepth) {
-        [self maxDepthError];
-        return;
-	}
-
-    [delegate parserFoundObjectStart:self];
-    [stateStack addObject:state];
-    self.state = [SBJsonStreamParserStateObjectStart sharedInstance];
-}
-
-- (void)handleObjectEnd: (sbjson_token_t) tok  {
-    self.state = [stateStack lastObject];
-    [stateStack removeLastObject];
-    [state parser:self shouldTransitionTo:tok];
-    [delegate parserFoundObjectEnd:self];
-}
-
-- (void)handleArrayStart {
-	if (stateStack.count >= maxDepth) {
-        [self maxDepthError];
-        return;
-    }
-	
-	[delegate parserFoundArrayStart:self];
-    [stateStack addObject:state];
-    self.state = [SBJsonStreamParserStateArrayStart sharedInstance];
-}
-
-- (void)handleArrayEnd: (sbjson_token_t) tok  {
-    self.state = [stateStack lastObject];
-    [stateStack removeLastObject];
-    [state parser:self shouldTransitionTo:tok];
-    [delegate parserFoundArrayEnd:self];
-}
-
-- (void) handleTokenNotExpectedHere: (sbjson_token_t) tok  {
-    NSString *tokenName = [self tokenName:tok];
-    NSString *stateName = [state name];
-
-    self.error = [NSString stringWithFormat:@"Token '%@' not expected %@", tokenName, stateName];
-    self.state = [SBJsonStreamParserStateError sharedInstance];
-}
-
-- (SBJsonStreamParserStatus)parse:(NSData *)data_ {
-    @autoreleasepool {
-        [tokeniser appendData:data_];
-        
-        for (;;) {
-            
-            if ([state isError])
-                return SBJsonStreamParserError;
-            
-            NSObject *token;
-            sbjson_token_t tok = [tokeniser getToken:&token];
-            switch (tok) {
-                case sbjson_token_eof:
-                    return [state parserShouldReturn:self];
-                    break;
-                    
-                case sbjson_token_error:
-                    self.state = [SBJsonStreamParserStateError sharedInstance];
-                    self.error = tokeniser.error;
-                    return SBJsonStreamParserError;
-                    break;
-                    
-                default:
-                    
-                    if (![state parser:self shouldAcceptToken:tok]) {
-                        [self handleTokenNotExpectedHere: tok];
-                        return SBJsonStreamParserError;
-                    }
-                    
-                    switch (tok) {
-                        case sbjson_token_object_start:
-                            [self handleObjectStart];
-                            break;
-                            
-                        case sbjson_token_object_end:
-                            [self handleObjectEnd: tok];
-                            break;
-                            
-                        case sbjson_token_array_start:
-                            [self handleArrayStart];
-                            break;
-                            
-                        case sbjson_token_array_end:
-                            [self handleArrayEnd: tok];
-                            break;
-                            
-                        case sbjson_token_separator:
-                        case sbjson_token_keyval_separator:
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        case sbjson_token_true:
-                            [delegate parser:self foundBoolean:YES];
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        case sbjson_token_false:
-                            [delegate parser:self foundBoolean:NO];
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        case sbjson_token_null:
-                            [delegate parserFoundNull:self];
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        case sbjson_token_number:
-                            [delegate parser:self foundNumber:(NSNumber*)token];
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        case sbjson_token_string:
-                            if ([state needKey])
-                                [delegate parser:self foundObjectKey:(NSString*)token];
-                            else
-                                [delegate parser:self foundString:(NSString*)token];
-                            [state parser:self shouldTransitionTo:tok];
-                            break;
-                            
-                        default:
-                            break;
-                    }
-                    break;
-            }
-        }
-        return SBJsonStreamParserComplete;
-    }
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
deleted file mode 100755
index 141d6ee..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- Copyright (C) 2011 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-#import "SBJsonStreamParserAdapter.h"
-
-@interface SBJsonStreamParserAccumulator : NSObject <SBJsonStreamParserAdapterDelegate>
-
-@property (copy) id value;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
deleted file mode 100755
index 1d39ceb..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- Copyright (C) 2011 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamParserAccumulator.h"
-
-@implementation SBJsonStreamParserAccumulator
-
-@synthesize value;
-
-
-#pragma mark SBJsonStreamParserAdapterDelegate
-
-- (void)parser:(SBJsonStreamParser*)parser foundArray:(NSArray *)array {
-	value = array;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser foundObject:(NSDictionary *)dict {
-	value = dict;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
deleted file mode 100755
index 942bc01..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-#import "SBJsonStreamParser.h"
-
-typedef enum {
-	SBJsonStreamParserAdapterNone,
-	SBJsonStreamParserAdapterArray,
-	SBJsonStreamParserAdapterObject,
-} SBJsonStreamParserAdapterType;
-
-/**
- @brief Delegate for getting objects & arrays from the stream parser adapter
- 
- @see The TweetStream example project.
- */
-@protocol SBJsonStreamParserAdapterDelegate
-
-/**
- @brief Called if a JSON array is found
- 
- This method is called if a JSON array is found.
- 
- */
-- (void)parser:(SBJsonStreamParser*)parser foundArray:(NSArray*)array;
-
-/**
- @brief Called when a JSON object is found
-
- This method is called if a JSON object is found.
- */
-- (void)parser:(SBJsonStreamParser*)parser foundObject:(NSDictionary*)dict;
-
-@end
-
-/**
- @brief SBJsonStreamParserDelegate protocol adapter
- 
- Rather than implementing the SBJsonStreamParserDelegate protocol yourself you will
- most likely find it much more convenient to use an instance of this class and
- implement the SBJsonStreamParserAdapterDelegate protocol instead.
- 
- The default behaviour is that the delegate only receives one call from
- either the -parser:foundArray: or -parser:foundObject: method when the
- document is fully parsed. However, if your inputs contains multiple JSON
- documents and you set the parser's -supportMultipleDocuments property to YES
- you will get one call for each full method.
- 
- @code
- SBJsonStreamParserAdapter *adapter = [[[SBJsonStreamParserAdapter alloc] init] autorelease];
- adapter.delegate = self;
- 
- SBJsonStreamParser *parser = [[[SBJsonStreamParser alloc] init] autorelease];
- parser.delegate = adapter;
- parser.supportMultipleDocuments = YES;
-
- // Note that this input contains multiple top-level JSON documents
- NSData *json = [@"[]{}[]{}" dataWithEncoding:NSUTF8StringEncoding]; 
- [parser parse:data];
- @endcode
- 
- In the above example @p self will have the following sequence of methods called on it:
- 
- @li -parser:foundArray:
- @li -parser:foundObject:
- @li -parser:foundArray:
- @li -parser:foundObject:
-
- Often you won't have control over the input you're parsing, so can't make use of
- this feature. But, all is not lost: this class will let you get the same effect by 
- allowing you to skip one or more of the outer enclosing objects. Thus, the next
- example results in the same sequence of -parser:foundArray: / -parser:foundObject:
- being called on your delegate.
- 
- @code
- SBJsonStreamParserAdapter *adapter = [[[SBJsonStreamParserAdapter alloc] init] autorelease];
- adapter.delegate = self;
- adapter.levelsToSkip = 1;
- 
- SBJsonStreamParser *parser = [[[SBJsonStreamParser alloc] init] autorelease];
- parser.delegate = adapter;
- 
- // Note that this input contains A SINGLE top-level document
- NSData *json = [@"[[],{},[],{}]" dataWithEncoding:NSUTF8StringEncoding]; 
- [parser parse:data];
- @endcode
- 
-*/
-@interface SBJsonStreamParserAdapter : NSObject <SBJsonStreamParserDelegate> {
-@private
-	NSUInteger depth;
-    NSMutableArray *array;
-	NSMutableDictionary *dict;
-	NSMutableArray *keyStack;
-	NSMutableArray *stack;
-	
-	SBJsonStreamParserAdapterType currentType;
-}
-
-/**
- @brief How many levels to skip
- 
- This is useful for parsing huge JSON documents, or documents coming in over a very slow link.
- 
- If you set this to N it will skip the outer N levels and call the -parser:foundArray:
- or -parser:foundObject: methods for each of the inner objects, as appropriate.
- 
- @see The StreamParserIntegrationTest.m file for examples
-*/
-@property NSUInteger levelsToSkip;
-
-/**
- @brief Your delegate object
- Set this to the object you want to receive the SBJsonStreamParserAdapterDelegate messages.
- */
-@property (unsafe_unretained) id<SBJsonStreamParserAdapterDelegate> delegate;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
deleted file mode 100755
index e77b534..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamParserAdapter.h"
-
-@interface SBJsonStreamParserAdapter ()
-
-- (void)pop;
-- (void)parser:(SBJsonStreamParser*)parser found:(id)obj;
-
-@end
-
-
-
-@implementation SBJsonStreamParserAdapter
-
-@synthesize delegate;
-@synthesize levelsToSkip;
-
-#pragma mark Housekeeping
-
-- (id)init {
-	self = [super init];
-	if (self) {
-		keyStack = [[NSMutableArray alloc] initWithCapacity:32];
-		stack = [[NSMutableArray alloc] initWithCapacity:32];
-		
-		currentType = SBJsonStreamParserAdapterNone;
-	}
-	return self;
-}	
-
-
-#pragma mark Private methods
-
-- (void)pop {
-	[stack removeLastObject];
-	array = nil;
-	dict = nil;
-	currentType = SBJsonStreamParserAdapterNone;
-	
-	id value = [stack lastObject];
-	
-	if ([value isKindOfClass:[NSArray class]]) {
-		array = value;
-		currentType = SBJsonStreamParserAdapterArray;
-	} else if ([value isKindOfClass:[NSDictionary class]]) {
-		dict = value;
-		currentType = SBJsonStreamParserAdapterObject;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser found:(id)obj {
-	NSParameterAssert(obj);
-	
-	switch (currentType) {
-		case SBJsonStreamParserAdapterArray:
-			[array addObject:obj];
-			break;
-
-		case SBJsonStreamParserAdapterObject:
-			NSParameterAssert(keyStack.count);
-			[dict setObject:obj forKey:[keyStack lastObject]];
-			[keyStack removeLastObject];
-			break;
-			
-		case SBJsonStreamParserAdapterNone:
-			if ([obj isKindOfClass:[NSArray class]]) {
-				[delegate parser:parser foundArray:obj];
-			} else {
-				[delegate parser:parser foundObject:obj];
-			}				
-			break;
-
-		default:
-			break;
-	}
-}
-
-
-#pragma mark Delegate methods
-
-- (void)parserFoundObjectStart:(SBJsonStreamParser*)parser {
-	if (++depth > self.levelsToSkip) {
-		dict = [NSMutableDictionary new];
-		[stack addObject:dict];
-		currentType = SBJsonStreamParserAdapterObject;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser foundObjectKey:(NSString*)key_ {
-	[keyStack addObject:key_];
-}
-
-- (void)parserFoundObjectEnd:(SBJsonStreamParser*)parser {
-	if (depth-- > self.levelsToSkip) {
-		id value = dict;
-		[self pop];
-		[self parser:parser found:value];
-	}
-}
-
-- (void)parserFoundArrayStart:(SBJsonStreamParser*)parser {
-	if (++depth > self.levelsToSkip) {
-		array = [NSMutableArray new];
-		[stack addObject:array];
-		currentType = SBJsonStreamParserAdapterArray;
-	}
-}
-
-- (void)parserFoundArrayEnd:(SBJsonStreamParser*)parser {
-	if (depth-- > self.levelsToSkip) {
-		id value = array;
-		[self pop];
-		[self parser:parser found:value];
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser foundBoolean:(BOOL)x {
-	[self parser:parser found:[NSNumber numberWithBool:x]];
-}
-
-- (void)parserFoundNull:(SBJsonStreamParser*)parser {
-	[self parser:parser found:[NSNull null]];
-}
-
-- (void)parser:(SBJsonStreamParser*)parser foundNumber:(NSNumber*)num {
-	[self parser:parser found:num];
-}
-
-- (void)parser:(SBJsonStreamParser*)parser foundString:(NSString*)string {
-	[self parser:parser found:string];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.h
deleted file mode 100755
index ea893cb..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.h
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-#import "SBJsonTokeniser.h"
-#import "SBJsonStreamParser.h"
-
-@interface SBJsonStreamParserState : NSObject
-+ (id)sharedInstance;
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token;
-- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser;
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok;
-- (BOOL)needKey;
-- (BOOL)isError;
-
-- (NSString*)name;
-
-@end
-
-@interface SBJsonStreamParserStateStart : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateComplete : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateError : SBJsonStreamParserState
-@end
-
-
-@interface SBJsonStreamParserStateObjectStart : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateObjectGotKey : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateObjectSeparator : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateObjectGotValue : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateObjectNeedKey : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateArrayStart : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateArrayGotValue : SBJsonStreamParserState
-@end
-
-@interface SBJsonStreamParserStateArrayNeedValue : SBJsonStreamParserState
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.m
deleted file mode 100755
index a24c6f6..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamParserState.m
+++ /dev/null
@@ -1,355 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamParserState.h"
-#import "SBJsonStreamParser.h"
-
-#define SINGLETON \
-+ (id)sharedInstance { \
-    static id state; \
-    if (!state) state = [[self alloc] init]; \
-    return state; \
-}
-
-@implementation SBJsonStreamParserState
-
-+ (id)sharedInstance { return nil; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	return NO;
-}
-
-- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
-	return SBJsonStreamParserWaitingForData;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {}
-
-- (BOOL)needKey {
-	return NO;
-}
-
-- (NSString*)name {
-	return @"<aaiie!>";
-}
-
-- (BOOL)isError {
-    return NO;
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateStart
-
-SINGLETON
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	return token == sbjson_token_array_start || token == sbjson_token_object_start;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-
-	SBJsonStreamParserState *state = nil;
-	switch (tok) {
-		case sbjson_token_array_start:
-			state = [SBJsonStreamParserStateArrayStart sharedInstance];
-			break;
-
-		case sbjson_token_object_start:
-			state = [SBJsonStreamParserStateObjectStart sharedInstance];
-			break;
-
-		case sbjson_token_array_end:
-		case sbjson_token_object_end:
-			if (parser.supportMultipleDocuments)
-				state = parser.state;
-			else
-				state = [SBJsonStreamParserStateComplete sharedInstance];
-			break;
-
-		case sbjson_token_eof:
-			return;
-
-		default:
-			state = [SBJsonStreamParserStateError sharedInstance];
-			break;
-	}
-
-
-	parser.state = state;
-}
-
-- (NSString*)name { return @"before outer-most array or object"; }
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateComplete
-
-SINGLETON
-
-- (NSString*)name { return @"after outer-most array or object"; }
-
-- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
-	return SBJsonStreamParserComplete;
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateError
-
-SINGLETON
-
-- (NSString*)name { return @"in error"; }
-
-- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
-	return SBJsonStreamParserError;
-}
-
-- (BOOL)isError {
-    return YES;
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateObjectStart
-
-SINGLETON
-
-- (NSString*)name { return @"at beginning of object"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_object_end:
-		case sbjson_token_string:
-			return YES;
-			break;
-		default:
-			return NO;
-			break;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateObjectGotKey sharedInstance];
-}
-
-- (BOOL)needKey {
-	return YES;
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateObjectGotKey
-
-SINGLETON
-
-- (NSString*)name { return @"after object key"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	return token == sbjson_token_keyval_separator;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateObjectSeparator sharedInstance];
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateObjectSeparator
-
-SINGLETON
-
-- (NSString*)name { return @"as object value"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_object_start:
-		case sbjson_token_array_start:
-		case sbjson_token_true:
-		case sbjson_token_false:
-		case sbjson_token_null:
-		case sbjson_token_number:
-		case sbjson_token_string:
-			return YES;
-			break;
-
-		default:
-			return NO;
-			break;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateObjectGotValue sharedInstance];
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateObjectGotValue
-
-SINGLETON
-
-- (NSString*)name { return @"after object value"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_object_end:
-		case sbjson_token_separator:
-			return YES;
-			break;
-		default:
-			return NO;
-			break;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateObjectNeedKey sharedInstance];
-}
-
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateObjectNeedKey
-
-SINGLETON
-
-- (NSString*)name { return @"in place of object key"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-    return sbjson_token_string == token;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateObjectGotKey sharedInstance];
-}
-
-- (BOOL)needKey {
-	return YES;
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateArrayStart
-
-SINGLETON
-
-- (NSString*)name { return @"at array start"; }
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_object_end:
-		case sbjson_token_keyval_separator:
-		case sbjson_token_separator:
-			return NO;
-			break;
-
-		default:
-			return YES;
-			break;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateArrayGotValue sharedInstance];
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateArrayGotValue
-
-SINGLETON
-
-- (NSString*)name { return @"after array value"; }
-
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	return token == sbjson_token_array_end || token == sbjson_token_separator;
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	if (tok == sbjson_token_separator)
-		parser.state = [SBJsonStreamParserStateArrayNeedValue sharedInstance];
-}
-
-@end
-
-#pragma mark -
-
-@implementation SBJsonStreamParserStateArrayNeedValue
-
-SINGLETON
-
-- (NSString*)name { return @"as array value"; }
-
-
-- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
-	switch (token) {
-		case sbjson_token_array_end:
-		case sbjson_token_keyval_separator:
-		case sbjson_token_object_end:
-		case sbjson_token_separator:
-			return NO;
-			break;
-
-		default:
-			return YES;
-			break;
-	}
-}
-
-- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
-	parser.state = [SBJsonStreamParserStateArrayGotValue sharedInstance];
-}
-
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.h
deleted file mode 100755
index a46b7a1..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.h
+++ /dev/null
@@ -1,195 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-/// Enable JSON writing for non-native objects
-@interface NSObject (SBProxyForJson)
-
-/**
- @brief Allows generation of JSON for otherwise unsupported classes.
- 
- If you have a custom class that you want to create a JSON representation
- for you can implement this method in your class. It should return a
- representation of your object defined in terms of objects that can be
- translated into JSON. For example, a Person object might implement it like this:
- 
- @code
- - (id)proxyForJson {
-	return [NSDictionary dictionaryWithObjectsAndKeys:
-	name, @"name",
-	phone, @"phone",
-	email, @"email",
-	nil];
- }
- @endcode
- 
- */
-- (id)proxyForJson;
-
-@end
-
-@class SBJsonStreamWriter;
-
-@protocol SBJsonStreamWriterDelegate
-
-- (void)writer:(SBJsonStreamWriter*)writer appendBytes:(const void *)bytes length:(NSUInteger)length;
-
-@end
-
-@class SBJsonStreamWriterState;
-
-/**
- @brief The Stream Writer class.
- 
- Accepts a stream of messages and writes JSON of these to its delegate object.
- 
- This class provides a range of high-, mid- and low-level methods. You can mix
- and match calls to these. For example, you may want to call -writeArrayOpen
- to start an array and then repeatedly call -writeObject: with various objects
- before finishing off with a -writeArrayClose call.
-  
- @see @ref json2objc
-
- */
-
-@interface SBJsonStreamWriter : NSObject {
-    NSMutableDictionary *cache;
-}
-
-@property (nonatomic, unsafe_unretained) SBJsonStreamWriterState *state; // Internal
-@property (nonatomic, readonly, strong) NSMutableArray *stateStack; // Internal 
-
-/**
- @brief delegate to receive JSON output
- Delegate that will receive messages with output.
- */
-@property (unsafe_unretained) id<SBJsonStreamWriterDelegate> delegate;
-
-/**
- @brief The maximum recursing depth.
- 
- Defaults to 512. If the input is nested deeper than this the input will be deemed to be
- malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
- turn off this security feature by setting the maxDepth value to 0.
- */
-@property NSUInteger maxDepth;
-
-/**
- @brief Whether we are generating human-readable (multiline) JSON.
- 
- Set whether or not to generate human-readable JSON. The default is NO, which produces
- JSON without any whitespace between tokens. If set to YES, generates human-readable
- JSON with linebreaks after each array value and dictionary key/value pair, indented two
- spaces per nesting level.
- */
-@property BOOL humanReadable;
-
-/**
- @brief Whether or not to sort the dictionary keys in the output.
- 
- If this is set to YES, the dictionary keys in the JSON output will be in sorted order.
- (This is useful if you need to compare two structures, for example.) The default is NO.
- */
-@property BOOL sortKeys;
-
-/**
- @brief An optional comparator to be used if sortKeys is YES.
- 
- If this is nil, sorting will be done via @selector(compare:).
- */
-@property (copy) NSComparator sortKeysComparator;
-
-/// Contains the error description after an error has occured.
-@property (copy) NSString *error;
-
-/** 
- Write an NSDictionary to the JSON stream.
- @return YES if successful, or NO on failure
- */
-- (BOOL)writeObject:(NSDictionary*)dict;
-
-/**
- Write an NSArray to the JSON stream.
- @return YES if successful, or NO on failure
- */
-- (BOOL)writeArray:(NSArray *)array;
-
-/** 
- Start writing an Object to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeObjectOpen;
-
-/**
- Close the current object being written
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeObjectClose;
-
-/** Start writing an Array to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeArrayOpen;
-
-/** Close the current Array being written
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeArrayClose;
-
-/** Write a null to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeNull;
-
-/** Write a boolean to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeBool:(BOOL)x;
-
-/** Write a Number to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeNumber:(NSNumber*)n;
-
-/** Write a String to the stream
- @return YES if successful, or NO on failure
-*/
-- (BOOL)writeString:(NSString*)s;
-
-@end
-
-@interface SBJsonStreamWriter (Private)
-- (BOOL)writeValue:(id)v;
-- (void)appendBytes:(const void *)bytes length:(NSUInteger)length;
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.m
deleted file mode 100755
index 1cdd26d..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriter.m
+++ /dev/null
@@ -1,374 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamWriter.h"
-#import "SBJsonStreamWriterState.h"
-
-static NSNumber *kNotANumber;
-static NSNumber *kTrue;
-static NSNumber *kFalse;
-static NSNumber *kPositiveInfinity;
-static NSNumber *kNegativeInfinity;
-
-
-@implementation SBJsonStreamWriter
-
-@synthesize error;
-@synthesize maxDepth;
-@synthesize state;
-@synthesize stateStack;
-@synthesize humanReadable;
-@synthesize sortKeys;
-@synthesize sortKeysComparator;
-
-+ (void)initialize {
-	kNotANumber = [NSDecimalNumber notANumber];
-    kPositiveInfinity = [NSNumber numberWithDouble:+INFINITY];
-    kNegativeInfinity = [NSNumber numberWithDouble:-INFINITY];
-    kTrue = [NSNumber numberWithBool:YES];
-    kFalse = [NSNumber numberWithBool:NO];
-}
-
-#pragma mark Housekeeping
-
-@synthesize delegate;
-
-- (id)init {
-	self = [super init];
-	if (self) {
-		maxDepth = 32u;
-        stateStack = [[NSMutableArray alloc] initWithCapacity:maxDepth];
-        state = [SBJsonStreamWriterStateStart sharedInstance];
-        cache = [[NSMutableDictionary alloc] initWithCapacity:32];
-    }
-	return self;
-}
-
-- (void)dealloc {
-    self.state = nil;
-}
-
-#pragma mark Methods
-
-- (void)appendBytes:(const void *)bytes length:(NSUInteger)length {
-    [delegate writer:self appendBytes:bytes length:length];
-}
-
-- (BOOL)writeObject:(NSDictionary *)dict {
-	if (![self writeObjectOpen])
-		return NO;
-
-	NSArray *keys = [dict allKeys];
-	
-	if (sortKeys) {
-		if (sortKeysComparator) {
-			keys = [keys sortedArrayWithOptions:NSSortStable usingComparator:sortKeysComparator];
-		}
-		else{
-			keys = [keys sortedArrayUsingSelector:@selector(compare:)];
-		}
-	}
-
-	for (id k in keys) {
-		if (![k isKindOfClass:[NSString class]]) {
-			self.error = [NSString stringWithFormat:@"JSON object key must be string: %@", k];
-			return NO;
-		}
-
-		if (![self writeString:k])
-			return NO;
-		if (![self writeValue:[dict objectForKey:k]])
-			return NO;
-	}
-
-	return [self writeObjectClose];
-}
-
-- (BOOL)writeArray:(NSArray*)array {
-	if (![self writeArrayOpen])
-		return NO;
-	for (id v in array)
-		if (![self writeValue:v])
-			return NO;
-	return [self writeArrayClose];
-}
-
-
-- (BOOL)writeObjectOpen {
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable && stateStack.count) [state appendWhitespace:self];
-
-    [stateStack addObject:state];
-    self.state = [SBJsonStreamWriterStateObjectStart sharedInstance];
-
-	if (maxDepth && stateStack.count > maxDepth) {
-		self.error = @"Nested too deep";
-		return NO;
-	}
-
-	[delegate writer:self appendBytes:"{" length:1];
-	return YES;
-}
-
-- (BOOL)writeObjectClose {
-	if ([state isInvalidState:self]) return NO;
-
-    SBJsonStreamWriterState *prev = state;
-
-    self.state = [stateStack lastObject];
-    [stateStack removeLastObject];
-
-	if (humanReadable) [prev appendWhitespace:self];
-	[delegate writer:self appendBytes:"}" length:1];
-
-	[state transitionState:self];
-	return YES;
-}
-
-- (BOOL)writeArrayOpen {
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable && stateStack.count) [state appendWhitespace:self];
-
-    [stateStack addObject:state];
-	self.state = [SBJsonStreamWriterStateArrayStart sharedInstance];
-
-	if (maxDepth && stateStack.count > maxDepth) {
-		self.error = @"Nested too deep";
-		return NO;
-	}
-
-	[delegate writer:self appendBytes:"[" length:1];
-	return YES;
-}
-
-- (BOOL)writeArrayClose {
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-
-    SBJsonStreamWriterState *prev = state;
-
-    self.state = [stateStack lastObject];
-    [stateStack removeLastObject];
-
-	if (humanReadable) [prev appendWhitespace:self];
-	[delegate writer:self appendBytes:"]" length:1];
-
-	[state transitionState:self];
-	return YES;
-}
-
-- (BOOL)writeNull {
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable) [state appendWhitespace:self];
-
-	[delegate writer:self appendBytes:"null" length:4];
-	[state transitionState:self];
-	return YES;
-}
-
-- (BOOL)writeBool:(BOOL)x {
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable) [state appendWhitespace:self];
-
-	if (x)
-		[delegate writer:self appendBytes:"true" length:4];
-	else
-		[delegate writer:self appendBytes:"false" length:5];
-	[state transitionState:self];
-	return YES;
-}
-
-
-- (BOOL)writeValue:(id)o {
-	if ([o isKindOfClass:[NSDictionary class]]) {
-		return [self writeObject:o];
-
-	} else if ([o isKindOfClass:[NSArray class]]) {
-		return [self writeArray:o];
-
-	} else if ([o isKindOfClass:[NSString class]]) {
-		[self writeString:o];
-		return YES;
-
-	} else if ([o isKindOfClass:[NSNumber class]]) {
-		return [self writeNumber:o];
-
-	} else if ([o isKindOfClass:[NSNull class]]) {
-		return [self writeNull];
-
-	} else if ([o respondsToSelector:@selector(proxyForJson)]) {
-		return [self writeValue:[o proxyForJson]];
-
-	}
-
-	self.error = [NSString stringWithFormat:@"JSON serialisation not supported for %@", [o class]];
-	return NO;
-}
-
-static const char *strForChar(int c) {
-	switch (c) {
-		case 0: return "\\u0000"; break;
-		case 1: return "\\u0001"; break;
-		case 2: return "\\u0002"; break;
-		case 3: return "\\u0003"; break;
-		case 4: return "\\u0004"; break;
-		case 5: return "\\u0005"; break;
-		case 6: return "\\u0006"; break;
-		case 7: return "\\u0007"; break;
-		case 8: return "\\b"; break;
-		case 9: return "\\t"; break;
-		case 10: return "\\n"; break;
-		case 11: return "\\u000b"; break;
-		case 12: return "\\f"; break;
-		case 13: return "\\r"; break;
-		case 14: return "\\u000e"; break;
-		case 15: return "\\u000f"; break;
-		case 16: return "\\u0010"; break;
-		case 17: return "\\u0011"; break;
-		case 18: return "\\u0012"; break;
-		case 19: return "\\u0013"; break;
-		case 20: return "\\u0014"; break;
-		case 21: return "\\u0015"; break;
-		case 22: return "\\u0016"; break;
-		case 23: return "\\u0017"; break;
-		case 24: return "\\u0018"; break;
-		case 25: return "\\u0019"; break;
-		case 26: return "\\u001a"; break;
-		case 27: return "\\u001b"; break;
-		case 28: return "\\u001c"; break;
-		case 29: return "\\u001d"; break;
-		case 30: return "\\u001e"; break;
-		case 31: return "\\u001f"; break;
-		case 34: return "\\\""; break;
-		case 92: return "\\\\"; break;
-	}
-	NSLog(@"FUTFUTFUT: -->'%c'<---", c);
-	return "FUTFUTFUT";
-}
-
-- (BOOL)writeString:(NSString*)string {
-	if ([state isInvalidState:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable) [state appendWhitespace:self];
-
-	NSMutableData *buf = [cache objectForKey:string];
-	if (!buf) {
-
-        NSUInteger len = [string lengthOfBytesUsingEncoding:NSUTF8StringEncoding];
-        const char *utf8 = [string UTF8String];
-        NSUInteger written = 0, i = 0;
-
-        buf = [NSMutableData dataWithCapacity:(NSUInteger)(len * 1.1f)];
-        [buf appendBytes:"\"" length:1];
-
-        for (i = 0; i < len; i++) {
-            int c = utf8[i];
-            BOOL isControlChar = c >= 0 && c < 32;
-            if (isControlChar || c == '"' || c == '\\') {
-                if (i - written)
-                    [buf appendBytes:utf8 + written length:i - written];
-                written = i + 1;
-
-                const char *t = strForChar(c);
-                [buf appendBytes:t length:strlen(t)];
-            }
-        }
-
-        if (i - written)
-            [buf appendBytes:utf8 + written length:i - written];
-
-        [buf appendBytes:"\"" length:1];
-        [cache setObject:buf forKey:string];
-    }
-
-	[delegate writer:self appendBytes:[buf bytes] length:[buf length]];
-	[state transitionState:self];
-	return YES;
-}
-
-- (BOOL)writeNumber:(NSNumber*)number {
-	if (number == kTrue || number == kFalse)
-		return [self writeBool:[number boolValue]];
-
-	if ([state isInvalidState:self]) return NO;
-	if ([state expectingKey:self]) return NO;
-	[state appendSeparator:self];
-	if (humanReadable) [state appendWhitespace:self];
-
-	if ([kPositiveInfinity isEqualToNumber:number]) {
-		self.error = @"+Infinity is not a valid number in JSON";
-		return NO;
-
-	} else if ([kNegativeInfinity isEqualToNumber:number]) {
-		self.error = @"-Infinity is not a valid number in JSON";
-		return NO;
-
-	} else if ([kNotANumber isEqualToNumber:number]) {
-		self.error = @"NaN is not a valid number in JSON";
-		return NO;
-	}
-
-	const char *objcType = [number objCType];
-	char num[128];
-	size_t len;
-
-	switch (objcType[0]) {
-		case 'c': case 'i': case 's': case 'l': case 'q':
-			len = snprintf(num, sizeof num, "%lld", [number longLongValue]);
-			break;
-		case 'C': case 'I': case 'S': case 'L': case 'Q':
-			len = snprintf(num, sizeof num, "%llu", [number unsignedLongLongValue]);
-			break;
-		case 'f': case 'd': default:
-			if ([number isKindOfClass:[NSDecimalNumber class]]) {
-				char const *utf8 = [[number stringValue] UTF8String];
-				[delegate writer:self appendBytes:utf8 length: strlen(utf8)];
-				[state transitionState:self];
-				return YES;
-			}
-			len = snprintf(num, sizeof num, "%.17g", [number doubleValue]);
-			break;
-	}
-	[delegate writer:self appendBytes:num length: len];
-	[state transitionState:self];
-	return YES;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
deleted file mode 100755
index b12d0d5..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- Copyright (C) 2011 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamWriter.h"
-
-@interface SBJsonStreamWriterAccumulator : NSObject <SBJsonStreamWriterDelegate>
-
-@property (readonly, copy) NSMutableData* data;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
deleted file mode 100755
index be65190..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- Copyright (C) 2011 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamWriterAccumulator.h"
-
-
-@implementation SBJsonStreamWriterAccumulator
-
-@synthesize data;
-
-- (id)init {
-    self = [super init];
-    if (self) {
-        data = [[NSMutableData alloc] initWithCapacity:8096u];
-    }
-    return self;
-}
-
-
-#pragma mark SBJsonStreamWriterDelegate
-
-- (void)writer:(SBJsonStreamWriter *)writer appendBytes:(const void *)bytes length:(NSUInteger)length {
-    [data appendBytes:bytes length:length];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.h b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
deleted file mode 100755
index 90d442a..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-  
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
- 
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-@class SBJsonStreamWriter;
-
-@interface SBJsonStreamWriterState : NSObject
-+ (id)sharedInstance;
-- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer;
-- (void)appendSeparator:(SBJsonStreamWriter*)writer;
-- (BOOL)expectingKey:(SBJsonStreamWriter*)writer;
-- (void)transitionState:(SBJsonStreamWriter*)writer;
-- (void)appendWhitespace:(SBJsonStreamWriter*)writer;
-@end
-
-@interface SBJsonStreamWriterStateObjectStart : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateObjectKey : SBJsonStreamWriterStateObjectStart
-@end
-
-@interface SBJsonStreamWriterStateObjectValue : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateArrayStart : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateArrayValue : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateStart : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateComplete : SBJsonStreamWriterState
-@end
-
-@interface SBJsonStreamWriterStateError : SBJsonStreamWriterState
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.m b/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
deleted file mode 100755
index 9f04cac..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonStreamWriterState.m
+++ /dev/null
@@ -1,139 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
-   Redistributions of source code must retain the above copyright
-   notice, this list of conditions and the following disclaimer.
-
-   Redistributions in binary form must reproduce the above copyright
-   notice, this list of conditions and the following disclaimer in the
-   documentation and/or other materials provided with the distribution.
-
-   Neither the name of the the author nor the names of its contributors
-   may be used to endorse or promote products derived from this software
-   without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonStreamWriterState.h"
-#import "SBJsonStreamWriter.h"
-
-#define SINGLETON \
-+ (id)sharedInstance { \
-    static id state; \
-    if (!state) state = [[self alloc] init]; \
-    return state; \
-}
-
-
-@implementation SBJsonStreamWriterState
-+ (id)sharedInstance { return nil; }
-- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer { return NO; }
-- (void)appendSeparator:(SBJsonStreamWriter*)writer {}
-- (BOOL)expectingKey:(SBJsonStreamWriter*)writer { return NO; }
-- (void)transitionState:(SBJsonStreamWriter *)writer {}
-- (void)appendWhitespace:(SBJsonStreamWriter*)writer {
-	[writer appendBytes:"\n" length:1];
-	for (NSUInteger i = 0; i < writer.stateStack.count; i++)
-	    [writer appendBytes:"  " length:2];
-}
-@end
-
-@implementation SBJsonStreamWriterStateObjectStart
-
-SINGLETON
-
-- (void)transitionState:(SBJsonStreamWriter *)writer {
-	writer.state = [SBJsonStreamWriterStateObjectValue sharedInstance];
-}
-- (BOOL)expectingKey:(SBJsonStreamWriter *)writer {
-	writer.error = @"JSON object key must be string";
-	return YES;
-}
-@end
-
-@implementation SBJsonStreamWriterStateObjectKey
-
-SINGLETON
-
-- (void)appendSeparator:(SBJsonStreamWriter *)writer {
-	[writer appendBytes:"," length:1];
-}
-@end
-
-@implementation SBJsonStreamWriterStateObjectValue
-
-SINGLETON
-
-- (void)appendSeparator:(SBJsonStreamWriter *)writer {
-	[writer appendBytes:":" length:1];
-}
-- (void)transitionState:(SBJsonStreamWriter *)writer {
-    writer.state = [SBJsonStreamWriterStateObjectKey sharedInstance];
-}
-- (void)appendWhitespace:(SBJsonStreamWriter *)writer {
-	[writer appendBytes:" " length:1];
-}
-@end
-
-@implementation SBJsonStreamWriterStateArrayStart
-
-SINGLETON
-
-- (void)transitionState:(SBJsonStreamWriter *)writer {
-    writer.state = [SBJsonStreamWriterStateArrayValue sharedInstance];
-}
-@end
-
-@implementation SBJsonStreamWriterStateArrayValue
-
-SINGLETON
-
-- (void)appendSeparator:(SBJsonStreamWriter *)writer {
-	[writer appendBytes:"," length:1];
-}
-@end
-
-@implementation SBJsonStreamWriterStateStart
-
-SINGLETON
-
-
-- (void)transitionState:(SBJsonStreamWriter *)writer {
-    writer.state = [SBJsonStreamWriterStateComplete sharedInstance];
-}
-- (void)appendSeparator:(SBJsonStreamWriter *)writer {
-}
-@end
-
-@implementation SBJsonStreamWriterStateComplete
-
-SINGLETON
-
-- (BOOL)isInvalidState:(SBJsonStreamWriter*)writer {
-	writer.error = @"Stream is closed";
-	return YES;
-}
-@end
-
-@implementation SBJsonStreamWriterStateError
-
-SINGLETON
-
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.h b/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.h
deleted file mode 100755
index e484a94..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.h
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- Copyright (c) 2010, Stig Brautaset.
- All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- 
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- 
- Neither the name of the the author nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-typedef enum {
-    sbjson_token_error = -1,
-    sbjson_token_eof,
-    
-    sbjson_token_array_start,
-    sbjson_token_array_end,
-    
-    sbjson_token_object_start,
-    sbjson_token_object_end,
-
-    sbjson_token_separator,
-    sbjson_token_keyval_separator,
-    
-    sbjson_token_number,
-    sbjson_token_string,
-    sbjson_token_true,
-    sbjson_token_false,
-    sbjson_token_null,
-    
-} sbjson_token_t;
-
-@class SBJsonUTF8Stream;
-
-@interface SBJsonTokeniser : NSObject 
-
-@property (strong) SBJsonUTF8Stream *stream;
-@property (copy) NSString *error;
-
-- (void)appendData:(NSData*)data_;
-
-- (sbjson_token_t)getToken:(NSObject**)token;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.m b/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.m
deleted file mode 100755
index 75d3268..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonTokeniser.m
+++ /dev/null
@@ -1,453 +0,0 @@
-/*
- Copyright (c) 2010-2011, Stig Brautaset. All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
-
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
- Neither the name of the the author nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
-
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonTokeniser.h"
-#import "SBJsonUTF8Stream.h"
-
-#define SBStringIsIllegalSurrogateHighCharacter(character) (((character) >= 0xD800UL) && ((character) <= 0xDFFFUL))
-#define SBStringIsSurrogateLowCharacter(character) ((character >= 0xDC00UL) && (character <= 0xDFFFUL))
-#define SBStringIsSurrogateHighCharacter(character) ((character >= 0xD800UL) && (character <= 0xDBFFUL))
-
-@implementation SBJsonTokeniser
-
-@synthesize error = _error;
-@synthesize stream = _stream;
-
-- (id)init {
-    self = [super init];
-    if (self) {
-        _stream = [[SBJsonUTF8Stream alloc] init];
-
-    }
-
-    return self;
-}
-
-
-- (void)appendData:(NSData *)data_ {
-    [_stream appendData:data_];
-}
-
-
-- (sbjson_token_t)match:(const char *)pattern length:(NSUInteger)len retval:(sbjson_token_t)token {
-    if (![_stream haveRemainingCharacters:len])
-        return sbjson_token_eof;
-
-    if ([_stream skipCharacters:pattern length:len])
-        return token;
-
-    self.error = [NSString stringWithFormat:@"Expected '%s' after initial '%.1s'", pattern, pattern];
-    return sbjson_token_error;
-}
-
-- (BOOL)decodeEscape:(unichar)ch into:(unichar*)decoded {
-    switch (ch) {
-        case '\\':
-        case '/':
-        case '"':
-            *decoded = ch;
-            break;
-
-        case 'b':
-            *decoded = '\b';
-            break;
-
-        case 'n':
-            *decoded = '\n';
-            break;
-
-        case 'r':
-            *decoded = '\r';
-            break;
-
-        case 't':
-            *decoded = '\t';
-            break;
-
-        case 'f':
-            *decoded = '\f';
-            break;
-
-        default:
-            self.error = @"Illegal escape character";
-            return NO;
-            break;
-    }
-    return YES;
-}
-
-- (BOOL)decodeHexQuad:(unichar*)quad {
-    unichar c, tmp = 0;
-
-    for (int i = 0; i < 4; i++) {
-        (void)[_stream getNextUnichar:&c];
-        tmp *= 16;
-        switch (c) {
-            case '0' ... '9':
-                tmp += c - '0';
-                break;
-
-            case 'a' ... 'f':
-                tmp += 10 + c - 'a';
-                break;
-
-            case 'A' ... 'F':
-                tmp += 10 + c - 'A';
-                break;
-
-            default:
-                return NO;
-        }
-    }
-    *quad = tmp;
-    return YES;
-}
-
-- (sbjson_token_t)getStringToken:(NSObject**)token {
-    NSMutableString *acc = nil;
-
-    for (;;) {
-        [_stream skip];
-        
-        unichar ch;
-        {
-            NSMutableString *string = nil;
-            
-            if (![_stream getStringFragment:&string])
-                return sbjson_token_eof;
-            
-            if (!string) {
-                self.error = @"Broken Unicode encoding";
-                return sbjson_token_error;
-            }
-            
-            if (![_stream getUnichar:&ch])
-                return sbjson_token_eof;
-            
-            if (acc) {
-                [acc appendString:string];
-                
-            } else if (ch == '"') {
-                *token = [string copy];
-                [_stream skip];
-                return sbjson_token_string;
-                
-            } else {
-                acc = [string mutableCopy];
-            }
-        }
-
-        
-        switch (ch) {
-            case 0 ... 0x1F:
-                self.error = [NSString stringWithFormat:@"Unescaped control character [0x%0.2X]", (int)ch];
-                return sbjson_token_error;
-                break;
-
-            case '"':
-                *token = acc;
-                [_stream skip];
-                return sbjson_token_string;
-                break;
-
-            case '\\':
-                if (![_stream getNextUnichar:&ch])
-                    return sbjson_token_eof;
-
-                if (ch == 'u') {
-                    if (![_stream haveRemainingCharacters:5])
-                        return sbjson_token_eof;
-
-                    unichar hi;
-                    if (![self decodeHexQuad:&hi]) {
-                        self.error = @"Invalid hex quad";
-                        return sbjson_token_error;
-                    }
-
-                    if (SBStringIsSurrogateHighCharacter(hi)) {
-                        unichar lo;
-
-                        if (![_stream haveRemainingCharacters:6])
-                            return sbjson_token_eof;
-
-                        (void)[_stream getNextUnichar:&ch];
-                        (void)[_stream getNextUnichar:&lo];
-                        if (ch != '\\' || lo != 'u' || ![self decodeHexQuad:&lo]) {
-                            self.error = @"Missing low character in surrogate pair";
-                            return sbjson_token_error;
-                        }
-
-                        if (!SBStringIsSurrogateLowCharacter(lo)) {
-                            self.error = @"Invalid low character in surrogate pair";
-                            return sbjson_token_error;
-                        }
-
-                        [acc appendFormat:@"%C%C", hi, lo];
-                    } else if (SBStringIsIllegalSurrogateHighCharacter(hi)) {
-                        self.error = @"Invalid high character in surrogate pair";
-                        return sbjson_token_error;
-                    } else {
-                        [acc appendFormat:@"%C", hi];
-                    }
-
-
-                } else {
-                    unichar decoded;
-                    if (![self decodeEscape:ch into:&decoded])
-                        return sbjson_token_error;
-                    [acc appendFormat:@"%C", decoded];
-                }
-
-                break;
-
-            default: {
-                self.error = [NSString stringWithFormat:@"Invalid UTF-8: '%x'", (int)ch];
-                return sbjson_token_error;
-                break;
-            }
-        }
-    }
-    return sbjson_token_eof;
-}
-
-- (sbjson_token_t)getNumberToken:(NSObject**)token {
-
-    NSUInteger numberStart = _stream.index;
-    NSCharacterSet *digits = [NSCharacterSet decimalDigitCharacterSet];
-
-    unichar ch;
-    if (![_stream getUnichar:&ch])
-        return sbjson_token_eof;
-
-    BOOL isNegative = NO;
-    if (ch == '-') {
-        isNegative = YES;
-        if (![_stream getNextUnichar:&ch])
-            return sbjson_token_eof;
-    }
-
-    unsigned long long mantissa = 0;
-    int mantissa_length = 0;
-    
-    if (ch == '0') {
-        mantissa_length++;
-        if (![_stream getNextUnichar:&ch])
-            return sbjson_token_eof;
-
-        if ([digits characterIsMember:ch]) {
-            self.error = @"Leading zero is illegal in number";
-            return sbjson_token_error;
-        }
-    }
-
-    while ([digits characterIsMember:ch]) {
-        mantissa *= 10;
-        mantissa += (ch - '0');
-        mantissa_length++;
-
-        if (![_stream getNextUnichar:&ch])
-            return sbjson_token_eof;
-    }
-
-    short exponent = 0;
-    BOOL isFloat = NO;
-
-    if (ch == '.') {
-        isFloat = YES;
-        if (![_stream getNextUnichar:&ch])
-            return sbjson_token_eof;
-
-        while ([digits characterIsMember:ch]) {
-            mantissa *= 10;
-            mantissa += (ch - '0');
-            mantissa_length++;
-            exponent--;
-
-            if (![_stream getNextUnichar:&ch])
-                return sbjson_token_eof;
-        }
-
-        if (!exponent) {
-            self.error = @"No digits after decimal point";
-            return sbjson_token_error;
-        }
-    }
-
-    BOOL hasExponent = NO;
-    if (ch == 'e' || ch == 'E') {
-        hasExponent = YES;
-
-        if (![_stream getNextUnichar:&ch])
-            return sbjson_token_eof;
-
-        BOOL expIsNegative = NO;
-        if (ch == '-') {
-            expIsNegative = YES;
-            if (![_stream getNextUnichar:&ch])
-                return sbjson_token_eof;
-
-        } else if (ch == '+') {
-            if (![_stream getNextUnichar:&ch])
-                return sbjson_token_eof;
-        }
-
-        short explicit_exponent = 0;
-        short explicit_exponent_length = 0;
-        while ([digits characterIsMember:ch]) {
-            explicit_exponent *= 10;
-            explicit_exponent += (ch - '0');
-            explicit_exponent_length++;
-
-            if (![_stream getNextUnichar:&ch])
-                return sbjson_token_eof;
-        }
-
-        if (explicit_exponent_length == 0) {
-            self.error = @"No digits in exponent";
-            return sbjson_token_error;
-        }
-
-        if (expIsNegative)
-            exponent -= explicit_exponent;
-        else
-            exponent += explicit_exponent;
-    }
-
-    if (!mantissa_length && isNegative) {
-        self.error = @"No digits after initial minus";
-        return sbjson_token_error;
-
-    } else if (mantissa_length >= 19) {
-        
-        NSString *number = [_stream stringWithRange:NSMakeRange(numberStart, _stream.index - numberStart)];
-        *token = [NSDecimalNumber decimalNumberWithString:number];
-
-    } else if (!isFloat && !hasExponent) {
-        if (!isNegative)
-            *token = [NSNumber numberWithUnsignedLongLong:mantissa];
-        else
-            *token = [NSNumber numberWithLongLong:-mantissa];
-    } else {
-        *token = [NSDecimalNumber decimalNumberWithMantissa:mantissa
-                                                   exponent:exponent
-                                                 isNegative:isNegative];
-    }
-
-    return sbjson_token_number;
-}
-
-- (sbjson_token_t)getToken:(NSObject **)token {
-
-    [_stream skipWhitespace];
-
-    unichar ch;
-    if (![_stream getUnichar:&ch])
-        return sbjson_token_eof;
-
-    NSUInteger oldIndexLocation = _stream.index;
-    sbjson_token_t tok;
-
-    switch (ch) {
-        case '[':
-            tok = sbjson_token_array_start;
-            [_stream skip];
-            break;
-
-        case ']':
-            tok = sbjson_token_array_end;
-            [_stream skip];
-            break;
-
-        case '{':
-            tok = sbjson_token_object_start;
-            [_stream skip];
-            break;
-
-        case ':':
-            tok = sbjson_token_keyval_separator;
-            [_stream skip];
-            break;
-
-        case '}':
-            tok = sbjson_token_object_end;
-            [_stream skip];
-            break;
-
-        case ',':
-            tok = sbjson_token_separator;
-            [_stream skip];
-            break;
-
-        case 'n':
-            tok = [self match:"null" length:4 retval:sbjson_token_null];
-            break;
-
-        case 't':
-            tok = [self match:"true" length:4 retval:sbjson_token_true];
-            break;
-
-        case 'f':
-            tok = [self match:"false" length:5 retval:sbjson_token_false];
-            break;
-
-        case '"':
-            tok = [self getStringToken:token];
-            break;
-
-        case '0' ... '9':
-        case '-':
-            tok = [self getNumberToken:token];
-            break;
-
-        case '+':
-            self.error = @"Leading + is illegal in number";
-            tok = sbjson_token_error;
-            break;
-
-        default:
-            self.error = [NSString stringWithFormat:@"Illegal start of token [%c]", ch];
-            tok = sbjson_token_error;
-            break;
-    }
-
-    if (tok == sbjson_token_eof) {
-        // We ran out of bytes in the middle of a token.
-        // We don't know how to restart in mid-flight, so
-        // rewind to the start of the token for next attempt.
-        // Hopefully we'll have more data then.
-        _stream.index = oldIndexLocation;
-    }
-
-    return tok;
-}
-
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.h b/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
deleted file mode 100755
index a26f032..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- Copyright (c) 2011, Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- 
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- 
- Neither the name of the the author nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-
-@interface SBJsonUTF8Stream : NSObject {
-@private
-    const char *_bytes;
-    NSMutableData *_data;
-    NSUInteger _length;
-}
-
-@property (assign) NSUInteger index;
-
-- (void)appendData:(NSData*)data_;
-
-- (BOOL)haveRemainingCharacters:(NSUInteger)chars;
-
-- (void)skip;
-- (void)skipWhitespace;
-- (BOOL)skipCharacters:(const char *)chars length:(NSUInteger)len;
-
-- (BOOL)getUnichar:(unichar*)ch;
-- (BOOL)getNextUnichar:(unichar*)ch;
-- (BOOL)getStringFragment:(NSString**)string;
-
-- (NSString*)stringWithRange:(NSRange)range;
-
-@end


[26/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/Makefile.PL
----------------------------------------------------------------------
diff --git a/sdks/other/perl/Makefile.PL b/sdks/other/perl/Makefile.PL
new file mode 100644
index 0000000..6ab9874
--- /dev/null
+++ b/sdks/other/perl/Makefile.PL
@@ -0,0 +1,41 @@
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+
+use 5.008;
+
+use ExtUtils::MakeMaker;
+
+WriteMakefile(
+  LICENSE           => 'apache',
+  AUTHOR            => 'Anuradha Weeraman <anuradha@cpan.org',
+  ABSTRACT          => 'Client API for Apache Usergrid',
+  NAME              => 'Usergrid::Client',
+  VERSION_FROM      => 'lib/Usergrid/Client.pm',
+  PREREQ_PM => {
+    'Moose'                => 0,
+    'JSON'                 => 0,
+    'REST::Client'         => 0,
+    'URI::Template'        => 0,
+    'Log::Log4perl'        => 0,
+    'namespace::autoclean' => 0
+  },
+  BUILD_REQUIRES    => {
+    'Test::More'    => '0.98'
+  }
+);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/perl/README.md b/sdks/other/perl/README.md
new file mode 100644
index 0000000..61069cc
--- /dev/null
+++ b/sdks/other/perl/README.md
@@ -0,0 +1,341 @@
+# Usergrid Perl Client ![CI status](https://travis-ci.org/aweeraman/usergrid-perl-sdk.svg?branch=master "CI Status")
+
+Usergrid::Client provides an easy to use Perl API for Apache Usergrid.
+
+## Quickstart
+
+Install Usergrid::Client from CPAN:
+
+    $ sudo cpan Usergrid::Client
+
+Write a perl script that uses the Perl API to talk to Usergrid. Here's an example:
+
+```perl
+#!/usr/bin/perl
+use Usergrid::Client;
+
+# Create a client object for Usergrid that's used for subsequent activity
+my $client = Usergrid::Client->new(
+  organization => 'test-organization',
+  application  => 'test-app',
+  api_url      => 'http://localhost:8080',
+  trace        => 0
+);
+
+# Logs the user in. The security token is maintained by the library in memory
+$client->login('johndoe', 'Johndoe123$');
+
+# Add two entities to the "books" collection
+$client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
+$client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+
+# Retrieve a handle to the collection
+my $books = $client->get_collection("books");
+
+# Add a new attribute for quantity in stock
+while ($books->has_next_entity()) {
+  my $book = $books->get_next_entity();
+
+  print "Name: "   . $book->get('name')   . ", ";
+  print "Author: " . $book->get('author') . "\n";
+
+  # Create a new attribute and update the entity
+  $book->set("in-stock", 0);
+  $client->update_entity($book);
+}
+```
+
+## What is Apache Usergrid
+
+Usergrid is an open-source Backend-as-a-Service (\u201cBaaS\u201d or \u201cmBaaS\u201d) composed of
+an integrated distributed NoSQL database, application layer and client tier with
+SDKs for developers looking to rapidly build web and/or mobile applications.
+It provides elementary services (user registration & management, data storage,
+file storage, queues) and retrieval features (full text search, geolocation
+search, joins) to power common app features.
+
+It is a multi-tenant system designed for deployment to public cloud environments
+(such as Amazon Web Services, Rackspace, etc.) or to run on traditional server
+infrastructures so that anyone can run their own private BaaS deployment.
+
+For architects and back-end teams, it aims to provide a distributed, easily
+extendable, operationally predictable and highly scalable solution. For
+front-end developers, it aims to simplify the development process by enabling
+them to rapidly build and operate mobile and web applications without requiring
+backend expertise.
+
+Source: [Usergrid Documentation](https://usergrid.apache.org/docs/)
+
+For more information, visit [http://www.usergrid.org](http://www.usergrid.org)
+
+## Installation
+
+### Prerequisites
+Usergrid::Client depends on the following modules which can be installed
+from CPAN as shown below:
+
+    $ sudo cpan install Moose
+    $ sudo cpan install JSON
+    $ sudo cpan install REST::Client
+    $ sudo cpan install URI::Template
+    $ sudo cpan install Log::Log4perl
+    $ sudo cpan install namespace::autoclean
+
+### Build and install
+
+    $ perl Build.PL
+    $ ./Build
+    $ ./Build test
+    $ sudo ./Build install
+
+### For legacy users on older versions of Perl
+
+    $ perl Makefile.PL
+    $ make
+    $ make test
+    $ sudo make install
+
+## Usage
+
+### Getting started
+
+In order to login to Usergrid using the API, create a Usergrid::Client object
+as shown below and invoke the login function.
+
+```perl
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url
+);
+
+$client->login($username, $password);
+```
+
+For troubleshooting the requests and responses, tracing can be enabled, which
+will log all requests and responses to standard output.
+
+```perl
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 1
+);
+```
+
+To get more details on the API, read the following perldocs:
+
+    Usergrid::Client
+    Usergrid::Collection
+    Usergrid::Entity
+
+### Entities
+
+Creating and updating an entity is easy. Here's how:
+
+```perl
+$book = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+$book->set('genre', 'Cyberpunk');
+
+$client->update_entity($book);
+```
+
+Querying an entity can be done by UUID:
+
+```perl
+$book = $client->get_entity("books", $uuid);
+```
+
+or by name:
+
+```perl
+$book = $client->get_entity("books", "Neuromancer");
+```
+
+Similarly, an entity can be deleted by UUID or by name:
+
+```perl
+$client->delete_entity_by_id("books", $uuid_or_name);
+
+# An entity can be also deleted by passing an entity object
+$client->delete_entity($entity);
+```
+
+### Collections
+
+A collection can be retrieved as shown below:
+
+```perl
+$collection = $client->get_collection("books");
+
+# Outputs the number of records in the collection
+print "$collection->count()\n";
+```
+
+To iterate over the collection:
+
+```perl
+while ($collection->has_next_entity()) {
+  $book = $collection->get_next_entity();
+  print "$book->get('name')\n";
+}
+```
+
+Note that by default a collection returns a maximum of 10 records per page. This
+can be overridden when retrieving the collection as shown below:
+
+```perl
+$collection = $client->get_collection("books", 30);
+
+# Retrieve the first book in the collection's current page
+$first_book = $collection->get_first_entity();
+
+# Retrieve the last book in the collection's current page
+$last_book  = $collection->get_last_entity();
+```
+
+To navigate the pages in the collection:
+
+```perl
+$collection->get_next_page();
+
+$collection->get_prev_page();
+```
+
+Both of the above return FALSE if the end or the beginning of the collection
+is reached.
+
+When iterating through a collection, the auto_page attribute can be set
+to allow the collection to transparently fetch the next page when iterating.
+
+```perl
+$collection = $client->get_collection("books");
+
+$collection->auto_page(1);
+
+while ($collection->has_next_entity()) {
+  my $entity = $collection->get_next_entity();
+  # do something
+}
+```
+
+### Querying & Batch Updates
+
+Collections can be queried using a SQL-like query language for greater control
+over the data set that is returned.
+
+```perl
+$collection = $client->query_collection("books", "select * where genre = 'Cyberpunk'", $limit );
+```
+
+Queries can also be used when deleting collections:
+
+```perl
+$collection = $client->delete_collection("books", "select * where genre = 'Cyberpunk'", $limit);
+```
+
+If the $limit is omitted in the above method calls, a default of 10 is assumed.
+
+A collection can be batch updated as shown below:
+
+```perl
+$client->update_collection("books", { in_stock => 1 });
+```
+
+A query can be used to fine-tune the update:
+
+```perl
+$client->update_collection("books", { in_stock => 0 }, "select * where genre = 'Cyberpunk'", $limit);
+```
+
+Similarly, entities can be deleted in batch:
+
+```perl
+$client->delete_collection("books", "select * where genre = 'Novel'", $limit);
+```
+
+### Entity Connections
+
+Connections can be created between entities through relationships as shown below:
+
+```perl
+$book1 = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+$book2 = $client->add_entity("books", { name => "Count Zero", author => "William Gibson" });
+$book3 = $client->add_entity("books", { name => "Mona Lisa Overdrive", author => "William Gibson" });
+
+$client->connect_entities($book1, "similar_to", $book2);
+$client->connect_entities($book1, "similar_to", $book3);
+```
+
+They can also be queried just like any other collection:
+
+```perl
+$collection = $client->query_connections($book1, "similar_to");
+
+# Queries and limits can also be passed in
+$collection = $client->query_connections($book1, "similar_to", $query, $limit);
+```
+
+To delete a connection:
+
+```perl
+$client->disconnect_entities($book1, "similar_to", $book2);
+```
+
+### Code Coverage
+
+Code coverage reporting requires Devel::Cover module which can be
+installed from CPAN as shown:
+
+    $ sudo cpan install Devel::Cover
+
+For generating reports on code coverage:
+
+    $ ./Build testcover
+
+The generated report artifacts are located in cover_db/.
+
+## Release notes
+
+### 0.22
+
+* Auto paging for collections
+
+### 0.21
+
+* Documentation updates
+
+### 0.2
+
+* Creating, querying and deleting entity connections
+* Bi-directional collection pagination
+
+### 0.11
+
+* Added namespace::autoclean.pm as a dependency to fix build break on some
+  platforms
+
+### 0.1
+
+* Initial release
+* Application and admin authentication
+* Support for collections and entities (CRUD & queries)
+
+## License
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+the ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+     http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/examples/books.pl
----------------------------------------------------------------------
diff --git a/sdks/other/perl/examples/books.pl b/sdks/other/perl/examples/books.pl
new file mode 100644
index 0000000..842d378
--- /dev/null
+++ b/sdks/other/perl/examples/books.pl
@@ -0,0 +1,48 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use Usergrid::Client;
+
+# Create a client object for Usergrid that's used for subsequent activity
+my $client = Usergrid::Client->new(
+  organization => 'test-organization',
+  application  => 'test-app',
+  api_url      => 'http://localhost:8080',
+  trace        => 0
+);
+
+# Logs the user in. The security token is maintained by the library in memory
+$client->login('johndoe', 'Johndoe123$');
+
+# Add two entities to the "books" collection
+$client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
+$client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+
+# Retrieve a handle to the collection
+my $books = $client->get_collection("books");
+
+# Add a new attribute for quantity in stock
+while ($books->has_next_entity()) {
+  my $book = $books->get_next_entity();
+
+  print "Name: "   . $book->get('name')   . ", ";
+  print "Author: " . $book->get('author') . "\n";
+
+  # Create a new attribute and update the entity
+  $book->set("in-stock", 0);
+  $client->update_entity($book);
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/lib/Usergrid/Client.pm
----------------------------------------------------------------------
diff --git a/sdks/other/perl/lib/Usergrid/Client.pm b/sdks/other/perl/lib/Usergrid/Client.pm
new file mode 100644
index 0000000..ccb276b
--- /dev/null
+++ b/sdks/other/perl/lib/Usergrid/Client.pm
@@ -0,0 +1,492 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+package Usergrid::Client;
+
+use Moose;
+use namespace::autoclean;
+use Usergrid::Entity;
+use Usergrid::Collection;
+
+with (
+  'Usergrid::Request',
+);
+
+our $VERSION = '0.22';
+
+=head1 NAME
+
+Usergrid::Client - Usergrid Perl Client
+
+=head1 SYNOPSIS
+
+  use Usergrid::Client;
+
+  my $client = Usergrid::Client->new(
+    organization => 'test-organization',
+    application  => 'test-app',
+    api_url      => 'http://localhost:8080'
+  );
+
+  $client->login('johndoe', 'Johndoe123$');
+
+  $client->add_entity("books", { name => "Ulysses" });
+  $client->add_entity("books", { name => "Neuromancer" });
+
+  my $books = $client->get_collection("books");
+
+  while ($books->has_next_entity()) {
+    my $book = $books->get_next_entity();
+
+    print "Name: "   . $book->get('name')   . ", ";
+    print "Author: " . $book->get('author') . "\n";
+
+    $book->set("in-stock", 0);
+    $client->update_entity($book);
+  }
+
+=head1 DESCRIPTION
+
+Usergrid::Client provides an easy to use Perl API for Apache Usergrid.
+
+=head1 WHAT IS APACHE USERGRID
+
+Usergrid is an open-source Backend-as-a-Service ("BaaS" or "mBaaS") composed of
+an integrated distributed NoSQL database, application layer and client tier with
+SDKs for developers looking to rapidly build web and/or mobile applications.
+It provides elementary services (user registration & management, data storage,
+file storage, queues) and retrieval features (full text search, geolocation
+search, joins) to power common app features.
+
+It is a multi-tenant system designed for deployment to public cloud environments
+(such as Amazon Web Services, Rackspace, etc.) or to run on traditional server
+infrastructures so that anyone can run their own private BaaS deployment.
+
+For architects and back-end teams, it aims to provide a distributed, easily
+extendable, operationally predictable and highly scalable solution. For
+front-end developers, it aims to simplify the development process by enabling
+them to rapidly build and operate mobile and web applications without requiring
+backend expertise.
+
+Source: L<https://usergrid.apache.org/docs/>
+
+For more information, visit L<http://www.usergrid.org>
+
+=head1 ATTRIBUTES
+
+The following attributes are made available via the L<Usergrid::Request> role:
+
+=over 4
+
+=item organization (String)
+
+Organization name
+
+=item application (String)
+
+Application name
+
+=item api_url (String)
+
+URL of the Usergrid instance
+
+=item trace (Boolean)
+
+Enable/disable request and response tracing for debugging and troubleshooting
+(Optional)
+
+=back
+
+=head1 METHODS
+
+The following methods are provided in this API for interacting with the Apache
+Usergrid backend.
+
+=head2 Authentication
+
+=over 4
+
+=item login ( $username, $password )
+
+Performs application user authentication. Returns the user token for the
+logged in user. The token is also kept in memory and used for subsequent
+authentication of requests.
+
+=cut
+sub login {
+  my ($self, $username, $password) = @_;
+
+  my %request = (
+    grant_type => "password",
+    username   => $username,
+    password   => $password
+  );
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/token')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application
+  );
+
+  my $token = $self->POST($uri, \%request);
+
+  $self->user_token($token);
+
+  return $self->user_token;
+}
+
+=item admin_login ( $username, $password )
+
+Performs admin user authentication. Returns the user token for the
+logged in user. The token is also kept in memory and used for subsequent
+authentication of requests.
+
+=cut
+sub management_login {
+  my ($self, $username, $password) = @_;
+
+  my %request = (
+    grant_type => "password",
+    username   => $username,
+    password   => $password
+  );
+
+  my $token = $self->POST('/management/token', \%request);
+
+  $self->user_token($token);
+
+  return $self->user_token;
+}
+
+=back
+
+=head2 Entities
+
+This section covers some of the entity level methods available in the API.
+Entities form one of the basic building blocks of Usergrid and is analogous to
+a row in an RDBMS table.
+
+=over 4
+
+=item add_entity ( $collection, \%entity )
+
+Creates a new entity within the specified collection. Returns a L<Usergrid::Entity>
+for the newly added entity.
+
+=cut
+sub add_entity {
+  my ($self, $collection, $entity) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection
+  );
+
+  return Usergrid::Entity->new( object => $self->POST($uri, $entity));
+}
+
+=item update_entity ( L<Usergrid::Entity> )
+
+Saves changes to the given entity. Returns the updated L<Usergrid::Entity>.
+
+=cut
+sub update_entity {
+  my ($self, $entity) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/{uuid}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $entity->get('type'),
+      uuid         => $entity->get('uuid')
+  );
+
+  return Usergrid::Entity->new( object => $self->PUT($uri,
+    $entity->object->{'entities'}[0]) );
+}
+
+=item get_entity ( $collection, $id )
+
+Returns a L<Usergrid::Entity> identified by either UUID or name.
+If the entity does not exist, the method returns FALSE.
+
+=cut
+sub get_entity {
+  my ($self, $collection, $id_or_name) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/{id_or_name}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      id_or_name   => $id_or_name
+  );
+
+  my $response = $self->GET($uri);
+
+  return undef if (! $response);
+
+  return Usergrid::Entity->new( object => $response );
+}
+
+=item delete_entity_by_id ( $collection, $id )
+
+Deletes an entity from the collection identified by either UUID or name. Returns
+a L<Usergrid::Entity> of the deleted entity.
+
+=cut
+sub delete_entity_by_id {
+  my ($self, $collection, $id_or_name) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/{id}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      id           => $id_or_name
+  );
+
+  return Usergrid::Entity->new( object => $self->DELETE($uri) );
+}
+
+=item delete_entity ( L<Usergrid::Entity> )
+
+Deletes the specified L<Usergrid::Entity>. Returns an instance of the deleted
+L<Usergrid::Entity> if successful.
+
+=cut
+sub delete_entity {
+  my ($self, $entity) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/{uuid}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $entity->get('type'),
+      uuid         => $entity->get('uuid')
+  );
+
+  return Usergrid::Entity->new( object => $self->DELETE($uri) );
+}
+
+=item connect_entities ( L<Usergrid::Entity>, $relationship, L<Usergrid::Entity> )
+
+Creates a connection from Entity #1 to Entity #2 signified by the relationship.
+The first entity in this relationship is identified as the connecting entity and
+the second as the connected entity. The relationship is a string that signifies
+the type of connection. This returns a L<Usergrid::Entity> of the connecting
+entity.
+
+=cut
+sub connect_entities {
+  my ($self, $connecting, $relationship, $connected) = @_;
+
+  my $uri = URI::Template
+    ->new ('/{organization}/{application}/{connecting_collection}/{connecting}/{relationship}/{connected_collection}/{connected}')
+    ->process(
+      organization          => $self->organization,
+      application           => $self->application,
+      connecting_collection => $connecting->get('type'),
+      connecting            => $connecting->get('uuid'),
+      relationship          => $relationship,
+      connected_collection  => $connected->get('type'),
+      connected             => $connected->get('uuid')
+    );
+
+    return Usergrid::Entity->new ( object => $self->POST($uri));
+}
+
+=item disconnect_entities ( L<Usergrid::Entity>, $relationship, L<Usergrid::Entity> )
+
+Removes the connection between the two entities signified by the relationship.
+This does not affect the entities in any other way apart from the removal of the
+connection that is depicted by the relationship. This returns a L<Usergrid::Entity>
+of the connecting entity with the given relationship removed.
+
+=cut
+sub disconnect_entities {
+my ($self, $connecting, $relationship, $connected) = @_;
+
+my $uri = URI::Template
+  ->new ('/{organization}/{application}/{connecting_collection}/{connecting}/{relationship}/{connected_collection}/{connected}')
+  ->process(
+    organization          => $self->organization,
+    application           => $self->application,
+    connecting_collection => $connecting->get('type'),
+    connecting            => $connecting->get('uuid'),
+    relationship          => $relationship,
+    connected_collection  => $connected->get('type'),
+    connected             => $connected->get('uuid')
+  );
+
+  return Usergrid::Entity->new ( object => $self->DELETE($uri));
+}
+
+=back
+
+=head2 Collections
+
+This section covers the methods related to retrieving and working with
+collections in the Usergrid API. Collections contains groups of entities and is
+analogous to a table in an RDBMS.
+
+=over 4
+
+=item get_collection ( $collection, [ $limit ] )
+
+Returns a L<Usergrid::Collection> with the list of entities up to the maximum
+specified limit, which is 10 if not provided.
+
+=cut
+sub get_collection {
+  my ($self, $collection, $limit) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}?limit={limit}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      limit        => ( defined $limit ) ? $limit: 10
+  );
+
+  return $self->_collection($self->GET($uri), $uri);
+}
+
+=item update_collection ( $collection, \%attributes, [ $query ], [ $limit ] )
+
+Updates all the entities in the specified collection with the provided attributes.
+Optionally pass in the SQL-like query to narrow the scope of the objects that
+are affected. This also supports specifying a limit to restrict the maximum number of
+records that are updated. If not specified, the limit defaults to 10 entities.
+
+=cut
+sub update_collection {
+  my ($self, $collection, $properties, $query, $limit) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/?limit={limit}&ql={query}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      limit        => ( defined $limit ) ? $limit : 10,
+      query        => ( defined $query ) ? $query : undef
+  );
+
+  return $self->_collection($self->PUT($uri, $properties), $uri);
+}
+
+=item delete_collection ( $collection, [ $query ], [ $limit ] )
+
+Batch delete entities in the specified collection. Optionally pass in a SQL-like
+query to narrow the scope of the objects that are affected and a limit to restrict
+the maximum number of records that are deleted. If not specified, the limit
+defaults to 10 entities.
+
+=cut
+sub delete_collection {
+  my ($self, $collection, $query, $limit) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/?limit={limit}&ql={query}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      limit        => ( defined $limit ) ? $limit : 10,
+      query        => ( defined $query ) ? $query : undef
+  );
+
+  return $self->_collection($self->DELETE($uri), $uri);
+}
+
+=item query_collection ( $collection, $query, [ $limit ] )
+
+Queries all the entities in the specified collection using a SQL-like query string.
+This also supports specifying a limit to restrict the maximum number of
+records that are returned. If not specified, the limit defaults to 10 entities.
+
+=cut
+sub query_collection {
+  my ($self, $collection, $query, $limit) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}?limit={limit}&ql={ql}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $collection,
+      limit        => ( defined $limit ) ? $limit : 10,
+      ql           => $query
+  );
+
+  return $self->_collection($self->GET($uri), $uri);
+}
+
+=item query_connections ( $entity, $relationship, [ $query ], [ $limit ] )
+
+Returns a collection of entities for the given relationship, optionally filtered
+by a SQL-like query and limited to the maximum number of records specified. If no limit
+is provided, a default of 10 entities is assumed.
+
+=cut
+sub query_connections {
+  my ($self, $entity, $relationship, $query, $limit) = @_;
+
+  my $uri = URI::Template
+    ->new('/{organization}/{application}/{collection}/{id}/{relationship}?limit={limit}&ql={ql}')
+    ->process(
+      organization => $self->organization,
+      application  => $self->application,
+      collection   => $entity->get('type'),
+      id           => $entity->get('uuid'),
+      relationship => $relationship,
+      limit        => ( defined $limit ) ? $limit : 10,
+      ql           => $query
+  );
+
+  return $self->_collection($self->GET($uri), $uri);
+}
+
+__PACKAGE__->meta->make_immutable;
+
+1;
+
+__END__
+
+=back
+
+=head1 SEE ALSO
+
+L<Usergrid::Collection>, L<Usergrid::Entity>, L<Usergrid::Request>
+
+=head1 LICENSE
+
+This software is distributed under the Apache 2 license.
+
+=head1 AUTHOR
+
+Anuradha Weeraman <an...@cpan.org>
+
+=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/lib/Usergrid/Collection.pm
----------------------------------------------------------------------
diff --git a/sdks/other/perl/lib/Usergrid/Collection.pm b/sdks/other/perl/lib/Usergrid/Collection.pm
new file mode 100644
index 0000000..8d64ce6
--- /dev/null
+++ b/sdks/other/perl/lib/Usergrid/Collection.pm
@@ -0,0 +1,212 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+package Usergrid::Collection;
+
+use Moose;
+use namespace::autoclean;
+
+with (
+  'Usergrid::Request',
+);
+
+my @stack;
+
+=head1 NAME
+
+Usergrid::Collection - a Usergrid collection
+
+=head1 DESCRIPTION
+
+Encapsulates Usergrid collections and provides methods for iterating and paging
+through them.
+
+=head1 ATTRIBUTES
+
+=over 4
+
+=item object
+
+A hash reference with the collection data
+
+=item uri
+
+The URI from which this collection was retrieved
+
+=item auto_page
+
+When set, the collection will automatically move to the next page when iterating
+through the collection
+
+=back
+
+=cut
+has 'object'      => ( is => 'rw', required => 1 );
+has 'uri'         => ( is => 'rw', required => 1 );
+has 'auto_page'   => ( is => 'rw', isa => 'Bool' );
+has 'iterator'    => ( is => 'rw', isa => 'Int', default => sub { -1 } );
+
+=head1 METHODS
+
+=over 4
+
+=item has_next_entity
+
+Returns true if there's another entity available during iteration.
+
+=cut
+sub has_next_entity {
+  my $self = shift;
+  my $next = $self->iterator + 1;
+  if ( $self->auto_page && $next >= $self->count()) {
+    return $self->get_next_page();
+  }
+  return ($next >= 0 && $next < $self->count());
+}
+
+=item get_next_entity
+
+Returns the next available L<Usergrid::Entity>. If there's no entity available
+to return, it returns a FALSE. If the auto_page attribute it set, the next page
+is automatically fetched and the next entity is returned.
+
+=cut
+sub get_next_entity {
+  my $self = shift;
+  if ($self->has_next_entity()) {
+    $self->iterator ($self->iterator + 1);
+    return Usergrid::Entity->new ( object => $self->object->{'entities'}[$self->iterator] );
+  }
+  return undef;
+}
+
+=item count
+
+Returns the count of the items in the collection.
+
+=cut
+sub count {
+  my $self = shift;
+  return scalar @{$self->object->{'entities'}};
+}
+
+=item reset_iterator
+
+Rewinds the iterator back to the beginning.
+
+=cut
+sub reset_iterator {
+  my $self = shift;
+  $self->iterator (-1);
+}
+
+=item get_first_entity
+
+Returns the first entity in the collection. This is only applicable for the
+current page of the collection.
+
+=cut
+sub get_first_entity {
+  my $self = shift;
+  return ($self->count() > 0) ? Usergrid::Entity->new (
+    object => $self->object->{'entities'}[0] ) : undef;
+}
+
+=item get_last_entity
+
+Returns the last entity in the collection. This is only applicable for the
+current page of the collection.
+
+=cut
+sub get_last_entity {
+  my $self = shift;
+  return ($self->count() > 0) ? Usergrid::Entity->new (
+    object => $self->object->{'entities'}[$self->count() - 1] ) : undef;
+
+}
+
+=item get_next_page
+
+Fetches the next page in the collection. Returns false when there are no more reults.
+
+=cut
+sub get_next_page {
+  my $self = shift;
+
+  my $csr = $self->object->{'cursor'};
+
+  my $object = $self->GET($self->uri . "&cursor=". $csr);
+
+  if ($object->{'count'} > 0) {
+    push @stack, "1" if (scalar @stack == 0);
+    push @stack, $csr;
+
+    $self->object( $object );
+    $self->reset_iterator();
+
+    return $self;
+  }
+
+  0;
+}
+
+=item get_prev_page
+
+Fetches the previous page in the collection. Returns false when there are no more reults.
+
+=cut
+sub get_prev_page {
+  my $self = shift;
+  my $object;
+
+  if (scalar @stack > 0) {
+    my $csr = pop @stack;
+
+    if ($csr eq "1") {
+      $object = $self->GET($self->uri);
+    } else {
+      $object = $self->GET($self->uri . "&cursor=" . $csr);
+    }
+
+    $self->object( $object );
+    $self->reset_iterator();
+
+    return $self;
+  }
+
+  0;
+}
+
+__PACKAGE__->meta->make_immutable;
+
+1;
+
+__END__
+
+=back
+
+=head1 SEE ALSO
+
+L<Usergrid::Client>, L<Usergrid::Entity>, L<Usergrid::Request>
+
+=head1 LICENSE
+
+This software is distributed under the Apache 2 license.
+
+=head1 AUTHOR
+
+Anuradha Weeraman <an...@cpan.org>
+
+=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/lib/Usergrid/Entity.pm
----------------------------------------------------------------------
diff --git a/sdks/other/perl/lib/Usergrid/Entity.pm b/sdks/other/perl/lib/Usergrid/Entity.pm
new file mode 100644
index 0000000..051e9b6
--- /dev/null
+++ b/sdks/other/perl/lib/Usergrid/Entity.pm
@@ -0,0 +1,92 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+package Usergrid::Entity;
+
+use Moose;
+use namespace::autoclean;
+
+=head1 NAME
+
+Usergrid::Entity - a Usergrid entity
+
+=head1 DESCRIPTION
+
+Encapsulates Usergrid entities and provides methods for accessing the underlying
+data.
+
+=head1 ATTRIBUTES
+
+=over 4
+
+=item object
+
+A hash reference with the entity data
+
+=back
+
+=cut
+has 'object'      => ( is => 'rw', required => 1);
+
+=head1 METHODS
+
+=over 4
+
+=item get ( $attribute_name )
+
+Returns the value of the specified attribute.
+
+=cut
+sub get {
+  my ($self, $key) = @_;
+  return $self->object->{$key} if (defined $self->object->{$key});
+  return $self->object->{'entities'}[0]->{$key};
+}
+
+=item set ( $attribute_name, $value )
+
+Sets the value of the specified attribute.
+
+=cut
+sub set {
+  my ($self, $key, $value) = @_;
+  if (defined $self->object->{$key}) {
+    $self->object->{$key} = $value;
+    return;
+  }
+  $self->object->{'entities'}[0]->{$key} = $value;
+}
+
+__PACKAGE__->meta->make_immutable;
+
+1;
+
+__END__
+
+=back
+
+=head1 SEE ALSO
+
+L<Usergrid::Client>, L<Usergrid::Collection>, L<Usergrid::Request>
+
+=head1 LICENSE
+
+This software is distributed under the Apache 2 license.
+
+=head1 AUTHOR
+
+Anuradha Weeraman <an...@cpan.org>
+
+=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/lib/Usergrid/Request.pm
----------------------------------------------------------------------
diff --git a/sdks/other/perl/lib/Usergrid/Request.pm b/sdks/other/perl/lib/Usergrid/Request.pm
new file mode 100644
index 0000000..3768039
--- /dev/null
+++ b/sdks/other/perl/lib/Usergrid/Request.pm
@@ -0,0 +1,249 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+package Usergrid::Request;
+
+use Moose::Role;
+use namespace::autoclean;
+use Carp qw(confess);
+use Log::Log4perl qw(:easy);
+use REST::Client;
+use URI::Template;
+use JSON;
+
+my $json = JSON->new->allow_nonref;
+
+=head1 NAME
+
+Usergrid::Request - Role that provides HTTP invocation and utility methods
+
+=head1 DESCRIPTION
+
+This is a Role that is applied to L<Usergrid::Client> and L<Usergrid::Collection>
+which provides methods that relate to HTTP invocation as well as some utility
+functions.
+
+=head1 ATTRIBUTES
+
+=over 4
+
+=item organization (String)
+
+Organization name
+
+=item application (String)
+
+Application name
+
+=item api_url (String)
+
+URL of the Usergrid instance
+
+=item trace (Boolean)
+
+Enable/disable request and response tracing for debugging and troubleshooting
+(Optional)
+
+=cut
+has 'organization'  => ( is => 'rw', isa => 'Str', required => 1);
+has 'application'   => ( is => 'rw', isa => 'Str', required => 1);
+has 'api_url'       => ( is => 'rw', isa => 'Str', required => 1);
+
+has 'trace'         => ( is => 'rw', isa => 'Bool', trigger => \&_enable_tracing);
+
+has 'user_token'    => ( is => 'rw');
+
+# internal method
+sub _is_token_required {
+  my ($self, $resource) = @_;
+  return 0 if $resource =~ m/\/management\/token/;
+  1;
+}
+
+# internal method
+sub _api_request {
+  my ($self, $method, $resource, $request) = @_;
+
+  $self->trace_message("$method $resource");
+  $self->trace_message("REQUEST: " . $self->prettify($request)) if ($request);
+
+  my $client = REST::Client->new();
+  $client->setHost($self->api_url);
+
+  if ($self->_is_token_required($resource) == 1 && defined $self->user_token) {
+     $client->addHeader('Authorization',
+        'Bearer ' . $self->user_token->{'access_token'});
+  }
+
+  my $json_req = $self->json_encode($request) if ($request);
+
+  $client->DELETE($resource)          if ($method eq 'DELETE');
+  $client->GET($resource)             if ($method eq 'GET');
+  $client->POST($resource, $json_req) if ($method eq 'POST');
+  $client->PUT($resource, $json_req)  if ($method eq 'PUT');
+
+  my $response = $client->responseContent();
+
+  $self->trace_message("RESPONSE: " . $self->prettify($response)) if ($response);
+
+  return undef if ($client->responseCode() eq "404");
+
+  confess "Bad request"  if ($client->responseCode() eq "400");
+  confess "Unauthorized" if ($client->responseCode() eq "401");
+  confess "Forbidden"    if ($client->responseCode() eq "403");
+  confess "Server error" if ($client->responseCode() eq "500");
+
+  return $self->json_decode($response);
+}
+
+# internal method
+sub _enable_tracing {
+  my ($self, $state, $old_state) = @_;
+  if ($state) {
+    Log::Log4perl::easy_init($DEBUG);
+    our $logger = Log::Log4perl->get_logger();
+  }
+}
+
+# internal method
+sub _collection {
+  my ($self, $object, $uri) = @_;
+
+  return Usergrid::Collection->new (
+    object       => $object,
+    uri          => $uri,
+    organization => $self->organization,
+    application  => $self->application,
+    api_url      => $self->api_url,
+    trace        => $self->trace,
+    user_token   => $self->user_token
+  );
+}
+
+=back
+
+=head1 METHODS
+
+=head2 HTTP Invocation Methods
+
+=over 4
+
+=item DELETE ( $resource )
+
+Invokes HTTP DELETE on the specified resource.
+
+=cut
+sub DELETE {
+  my ($self, $resource) = @_;
+  $self->_api_request('DELETE', $resource);
+}
+
+=item GET ( $resource )
+
+Invokes HTTP GET on the specified resource.
+
+=cut
+sub GET {
+  my ($self, $resource) = @_;
+  $self->_api_request('GET', $resource);
+}
+
+=item POST ( $resource, \%request )
+
+Invokes HTTP POST on the specified resource and passes in the payload
+for the request.
+
+=cut
+sub POST {
+  my ($self, $resource, $request) = @_;
+  $self->_api_request('POST', $resource, $request);
+}
+
+=item PUT ( $resource, \%request )
+
+Invokes HTTP PUT on the specified resource and passes in the payload
+for the request.
+
+=cut
+sub PUT {
+  my ($self, $resource, $request) = @_;
+  $self->_api_request('PUT', $resource, $request);
+}
+
+=back
+
+=head2 Utility Methods
+
+=over 4
+
+=item trace_message ( $message )
+
+Utility method to log a message to console if tracing is enabled.
+
+=cut
+sub trace_message {
+  my ($self, $message) = @_;
+  $Usergrid::Request::logger->debug($message) if (defined $Usergrid::Request::logger);
+}
+
+=item prettify ( $message, \%object )
+
+Returns a prettified string representation hash reference.
+
+=cut
+sub prettify {
+  my ($self, $json_obj) = @_;
+  return $json->pretty->encode($json_obj);
+}
+
+=item json_encode ( \%hashref )
+
+Returns a JSON object from a hash reference.
+
+=cut
+sub json_encode {
+  my ($self, $json_obj) = @_;
+  $json->encode($json_obj);
+}
+
+=item json_decode ( $json_object )
+
+Returns a hash reference from a JSON object.
+
+=cut
+sub json_decode {
+  my ($self, $json_obj) = @_;
+  $json->decode($json_obj);
+}
+
+1;
+
+__END__
+
+=back
+
+=head1 SEE ALSO
+
+L<Usergrid::Client>, L<Usergrid::Collection>, L<Usergrid::Entity>
+
+=head1 LICENSE
+
+This software is distributed under the Apache 2 license.
+
+=head1 AUTHOR
+
+Anuradha Weeraman <an...@cpan.org>
+
+=cut

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/01_init.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/01_init.t b/sdks/other/perl/t/01_init.t
new file mode 100644
index 0000000..c410155
--- /dev/null
+++ b/sdks/other/perl/t/01_init.t
@@ -0,0 +1,27 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+
+use Test::More tests => 3;
+
+BEGIN {
+  use_ok 'Usergrid::Client'     || print "Bail out!\n";
+  use_ok 'Usergrid::Entity'     || print "Bail out!\n";
+  use_ok 'Usergrid::Collection' || print "Bail out!\n";
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/02_login.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/02_login.t b/sdks/other/perl/t/02_login.t
new file mode 100644
index 0000000..8397b92
--- /dev/null
+++ b/sdks/other/perl/t/02_login.t
@@ -0,0 +1,64 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+our $hostname        = 'localhost';
+our $port            = '8080';
+our $api_url         = "http://$hostname:$port";
+our $organization    = 'test-organization';
+our $application     = 'test-app';
+our $username        = 'testuser';
+our $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 1;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+ok ( $token->{user}->{username} eq $username, "user logged in" );
+
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/03_update.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/03_update.t b/sdks/other/perl/t/03_update.t
new file mode 100644
index 0000000..b05a260
--- /dev/null
+++ b/sdks/other/perl/t/03_update.t
@@ -0,0 +1,102 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 7;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $deleted_book);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  ok ( $token->{user}->{username} eq $username, "user logged in" );
+
+  $book = $client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
+
+  ok ( $book->get('author') eq "James Joyce", "check entity creation" );
+
+  $book->set('genre', 'Modernist');
+
+  $book = $client->update_entity($book);
+
+  ok ( $book->get('genre') eq "Modernist", "check for new attribute" );
+
+  $book->set('genre', 'Novel');
+
+  $book = $client->update_entity($book);
+
+  ok ( $book->get('genre') eq "Novel", "check for updated attribute" );
+
+  $book = $client->get_entity("books", $book->get('uuid'));
+
+  ok ( $book->get('genre') eq "Novel", "check again for updated attribute by uuid" );
+
+  $book = $client->get_entity("books", "Ulysses");
+
+  ok ( $book->get('name') eq 'Ulysses', "get object by name") ;
+
+  $book = $client->delete_entity_by_id("books", $book->get('uuid'));
+
+  $deleted_book = $client->get_entity("books", $book->get('uuid'));
+
+  ok ( (! defined $deleted_book), "deleted book cannot be found" );
+
+};
+
+diag($@) if $@;
+
+# Cleanup
+$client->delete_entity($book);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/04_collection.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/04_collection.t b/sdks/other/perl/t/04_collection.t
new file mode 100644
index 0000000..d823ced
--- /dev/null
+++ b/sdks/other/perl/t/04_collection.t
@@ -0,0 +1,104 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 10;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  $client->add_entity("books", { name => "Ulysses", author => "James Joyce" });
+  $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+  $client->add_entity("books", { name => "On the Road", author => "Jack Kerouac" });
+  $client->add_entity("books", { name => "Ubik", author => "Philip K. Dick" });
+  $client->add_entity("books", { name => "Reef", author => "Romesh Gunasekera" });
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 5, "count must now be five" );
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    ok ( length($book->get('name')) > 3, "check the book titles" );
+  }
+
+  $collection->reset_iterator();
+
+  ok ( $collection->iterator == -1, "iterator must be reset" );
+
+  ok ( $collection->count() == 5, "count must be five" );
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    $client->delete_entity($book);
+  }
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must now be again zero" );
+
+};
+
+diag($@) if $@;
+
+# Cleanup
+$collection = $client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/05_query.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/05_query.t b/sdks/other/perl/t/05_query.t
new file mode 100644
index 0000000..40e3f1b
--- /dev/null
+++ b/sdks/other/perl/t/05_query.t
@@ -0,0 +1,108 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 8;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection, $subset);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  for (my $i = 0; $i < 30; $i++) {
+    $client->add_entity("books", { name => "book $i", index => $i });
+  }
+
+  $collection = $client->get_collection("books", 30);
+
+  ok ( $collection->count() == 30, "count must now be 30" );
+
+  $book = $collection->get_first_entity();
+
+  ok ( $book->get('index') eq '0', "first index should be 0");
+
+  $book = $collection->get_last_entity();
+
+  ok ( $book->get('index') eq '29', "last index should be 29");
+
+  $subset = $client->query_collection("books", "select * where index = '5'", 15 );
+
+  ok ( $subset->count() == 1, "subset is 1" );
+  ok ( $subset->object->{'params'}->{'limit'}[0] eq '15', "check limit override" );
+
+  $book = $subset->get_next_entity();
+
+  ok ( $book->get('index') eq '5', "query returned the fifth book" );
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    $client->delete_entity($book);
+  }
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must now be again zero" );
+
+};
+
+diag($@) if $@;
+
+# Cleanup
+$collection = $client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/06_batch_update.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/06_batch_update.t b/sdks/other/perl/t/06_batch_update.t
new file mode 100644
index 0000000..04ff11d
--- /dev/null
+++ b/sdks/other/perl/t/06_batch_update.t
@@ -0,0 +1,107 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 34;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection, $count);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  for (my $i = 0; $i < 30; $i++) {
+    $client->add_entity("books", { name => "book $i", index => $i });
+  }
+
+  $collection = $client->get_collection("books", 30);
+
+  ok ( $collection->count() == 30, "count must now be 30" );
+
+  $client->update_collection("books", { in_stock => 1 });
+
+  $collection = $client->get_collection("books", 30);
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    ok ( $book->get('in_stock') == 1 );
+  }
+
+  $client->update_collection("books", { in_stock => 0 }, "select * where index = '1' or index = '2' or index = '3' or index = '4' or index = '5'");
+
+  $collection = $client->get_collection("books", 30);
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    $count++ if ($book->get('index') =~ /[12345]/ && $book->get('in_stock') == 0);
+    $client->delete_entity($book);
+  }
+
+  ok ( $count == 5, "batch update only 5 entities" );
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must now be again zero" );
+
+};
+
+diag($@) if $@;
+
+# Cleanup
+$collection = $client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/07_batch_delete.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/07_batch_delete.t b/sdks/other/perl/t/07_batch_delete.t
new file mode 100644
index 0000000..2ed6d72
--- /dev/null
+++ b/sdks/other/perl/t/07_batch_delete.t
@@ -0,0 +1,87 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 3;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection, $count);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  for (my $i = 0; $i < 30; $i++) {
+    $client->add_entity("books", { name => "book $i", index => $i });
+  }
+
+  $collection = $client->get_collection("books", 30);
+
+  ok ( $collection->count() == 30, "count must now be 30" );
+
+  $client->delete_collection("books", "select * where index = '1' or index = '2' or index = '3' or index = '4' or index = '5'");
+
+  $collection = $client->get_collection("books", 30);
+
+  ok ( $collection->count() == 25, "deleted 5 entities" );
+};
+
+diag($@) if $@;
+
+# Cleanup
+$collection = $client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/08_connections.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/08_connections.t b/sdks/other/perl/t/08_connections.t
new file mode 100644
index 0000000..35550e0
--- /dev/null
+++ b/sdks/other/perl/t/08_connections.t
@@ -0,0 +1,94 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 5;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $book1, $book2, $book3, $collection);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+  $book1 = $client->add_entity("books", { name => "Neuromancer", author => "William Gibson" });
+  $book2 = $client->add_entity("books", { name => "Count Zero", author => "William Gibson" });
+  $book3 = $client->add_entity("books", { name => "Mona Lisa Overdrive", author => "William Gibson" });
+
+  $client->connect_entities($book1, "similar_to", $book2);
+  $client->connect_entities($book1, "similar_to", $book3);
+
+  $collection = $client->query_connections($book1, "similar_to");
+
+  ok ( $collection->count == 2, "two connections must exist" );
+
+  while ($collection->has_next_entity()) {
+    $book = $collection->get_next_entity();
+    ok ( $book->get('name') eq 'Count Zero' || $book->get('name') eq ('Mona Lisa Overdrive'), "check connections");
+  }
+
+  $client->disconnect_entities($book1, "similar_to", $book2);
+
+  $collection = $client->query_connections($book1, "similar_to");
+
+  ok ( $collection->count() == 1 );
+
+  $book = $collection->get_next_entity();
+
+  ok ( $book->get('name') eq 'Mona Lisa Overdrive', "check remaining connection");
+};
+
+diag($@) if $@;
+
+# Cleanup
+$client->delete_collection("books", undef, 10);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/09_paging.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/09_paging.t b/sdks/other/perl/t/09_paging.t
new file mode 100644
index 0000000..9a38a7f
--- /dev/null
+++ b/sdks/other/perl/t/09_paging.t
@@ -0,0 +1,140 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 24;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection, $subset, $count);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  for (my $i = 0; $i < 30; $i++) {
+    $client->add_entity("books", { name => "book $i", index => $i });
+  }
+
+  $collection = $client->get_collection("books", 30);
+
+  ok ( $collection->count() == 30, "count must now be 30" );
+
+  $collection = $client->get_collection("books", 10);
+
+  ok ( $collection->count == 10, "checking first page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 0', "Check first entity of first page");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 9', "Check last entity of first page");
+
+  $collection->get_next_page();
+
+  ok ( $collection->count == 10, "checking second page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 10', "Check first entity of second page");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 19', "Check last entity of second page");
+
+  $collection->get_next_page();
+
+  ok ( $collection->count == 10, "checking third page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 20', "Check first entity of third page");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 29', "Check last entity of third page");
+
+  if (! $collection->get_next_page()) {
+    pass ( "no more results" );
+  }
+
+  $collection->get_prev_page();
+
+  ok ( $collection->count == 10, "checking third page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 20', "Check first entity of third page in reverse");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 29', "Check last entity of third page in reverse");
+
+  $collection->get_prev_page();
+
+  ok ( $collection->count == 10, "checking second page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 10', "Check first entity of second page in reverse");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 19', "Check last entity of second page in reverse");
+
+  $collection->get_prev_page();
+
+  ok ( $collection->count == 10, "checking first page count" );
+  ok ( $collection->get_first_entity()->get('name') eq 'book 0', "Check first entity of first page in reverse");
+  ok ( $collection->get_last_entity()->get('name')  eq 'book 9', "Check last entity of first page in reverse");
+
+  if (! $collection->get_prev_page()) {
+    pass ( "no more results in reverse" );
+  }
+
+  $count = 0;
+  $collection = $client->get_collection("books", 10);
+  do {
+    $count += $collection->count();
+  } while ($collection->get_next_page());
+
+  ok ( $count == 30, "should return 30 entities in forward" );
+
+  $count = 0;
+  while ($collection->get_prev_page()) {
+    $count += $collection->count();
+  }
+
+  ok ( $count == 30, "should return 30 entities in reverse" );
+};
+
+diag($@) if $@;
+
+# Cleanup
+$client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/t/10_auto_paging.t
----------------------------------------------------------------------
diff --git a/sdks/other/perl/t/10_auto_paging.t b/sdks/other/perl/t/10_auto_paging.t
new file mode 100644
index 0000000..5ed98f7
--- /dev/null
+++ b/sdks/other/perl/t/10_auto_paging.t
@@ -0,0 +1,94 @@
+#!/usr/bin/perl
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use strict;
+use warnings;
+use Usergrid::Client;
+use IO::Socket::INET;
+use Test::More;
+
+# TEST DATA
+my $hostname        = 'localhost';
+my $port            = '8080';
+my $api_url         = "http://$hostname:$port";
+my $organization    = 'test-organization';
+my $application     = 'test-app';
+my $username        = 'testuser';
+my $password        = 'Testuser123$';
+###########
+
+if (_check_port($hostname, $port)) {
+  plan tests => 3;
+} else {
+  plan skip_all => "server $api_url not reachable"
+}
+
+sub _check_port {
+  my ($hostname, $port) = @_;
+  new IO::Socket::INET ( PeerAddr => $hostname, PeerPort => $port,
+    Proto => 'tcp' ) || return 0;
+  return 1;
+}
+
+my ($user, $token, $book, $collection, $subset, $count);
+
+# Create the client object that will be used for all subsequent requests
+my $client = Usergrid::Client->new(
+  organization => $organization,
+  application  => $application,
+  api_url      => $api_url,
+  trace        => 0
+);
+
+# Create a test user
+$user = $client->add_entity("users", { username=>$username, password=>$password });
+
+$token = $client->login($username, $password);
+
+eval {
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->count() == 0, "count must be initially zero" );
+
+  for (my $i = 0; $i < 30; $i++) {
+    $client->add_entity("books", { name => "book $i", index => $i });
+  }
+
+  $collection = $client->get_collection("books");
+
+  ok ( $collection->get_last_entity()->get('name') eq 'book 9', "only return 10 entites per page by default");
+
+  $collection = $client->get_collection("books");
+
+  $collection->auto_page(1);
+
+  $count = 0;
+
+  while ($collection->has_next_entity()) {
+    $count += 1;
+    my $entity = $collection->get_next_entity();
+  }
+
+  ok ( $count == 30, "should return 30 entities in when auto paging" );
+};
+
+diag($@) if $@;
+
+# Cleanup
+$client->delete_collection("books", undef, 30);
+$client->delete_entity($user);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/other/php/LICENSE b/sdks/other/php/LICENSE
new file mode 100644
index 0000000..e06d208
--- /dev/null
+++ b/sdks/other/php/LICENSE
@@ -0,0 +1,202 @@
+Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "{}"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright {yyyy} {name of copyright owner}
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+


[35/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/Nukefile
----------------------------------------------------------------------
diff --git a/sdks/other/ios/Nukefile b/sdks/other/ios/Nukefile
new file mode 100644
index 0000000..7879116
--- /dev/null
+++ b/sdks/other/ios/Nukefile
@@ -0,0 +1,46 @@
+;;
+;; Licensed to the Apache Software Foundation (ASF) under one or more
+;; contributor license agreements.  See the NOTICE file distributed with
+;; this work for additional information regarding copyright ownership.
+;; The ASF licenses this file to You under the Apache License, Version 2.0
+;; (the "License"); you may not use this file except in compliance with
+;; the License.  You may obtain a copy of the License at
+;;
+;;     http://www.apache.org/licenses/LICENSE-2.0
+;;
+;; Unless required by applicable law or agreed to in writing, software
+;; distributed under the License is distributed on an "AS IS" BASIS,
+;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+;; See the License for the specific language governing permissions and
+;; limitations under the License.
+;;
+
+;;
+;; If you've installed Nu (http://github.com/timburks/nu),
+;; then you can build the Usergrid SDK as a Mac framework
+;; by typing "nuke" in this directory. Type "nuke install"
+;; to install it in /Library/Frameworks.
+;; 
+(set @m_files (filelist "^UGAPI/.*.m$"))
+(@m_files addObjectsFromSet:(filelist "^UGAPI/SBJSON/.*.m$"))
+(@m_files addObjectsFromSet:(filelist "^UGAPI/v2/.*.m$"))
+
+(set @arch '("x86_64"))
+
+;; framework description
+(set @framework "Usergrid")
+(set @framework_identifier "com.apigee.usergrid")
+
+(set @cc "clang")
+(set @cflags "-fobjc-arc -I UGAPI -I UGAPI/SBJSON -I UGAPI/v2")
+(set @ldflags  "-framework Foundation ")
+
+(compilation-tasks)
+(framework-tasks)
+
+(task "clobber" => "clean" is
+      (SH "rm -rf #{@framework_dir}"))
+
+(task "default" => "framework")
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/ios/README.md b/sdks/other/ios/README.md
new file mode 100644
index 0000000..7dd9fa3
--- /dev/null
+++ b/sdks/other/ios/README.md
@@ -0,0 +1,80 @@
+# iOS SDK
+
+##Version
+
+Current Version: **0.9.2**
+
+Change log:
+
+<https://github.com/apache/usergrid/blob/master/sdks/ios/changelog.md>
+
+##Overview
+This open source SDK simplifies writing iOS applications that connect to App Services (Usergrid). The repo is located here:
+
+<https://github.com/apache/usergrid/tree/master/sdks/ios>
+
+You can download the SDK as part of the Usergrid stack here:
+
+* Download as a tar.gz file: <http://usergrid.apache.org/releases/>
+
+To find out more about how to use the iOS SDK within Usergrid, see:
+
+<http://usergrid.apache.org/docs/sdks/ios-new.html>
+
+##Installing
+Once you have downloaded the SDK, add the UGAPI folder to your project by dragging and dropping it into your project. 
+
+**Note:** Make sure you check the "Copy items into destination group's folder", and also make sure the appropriate boxes are checked next to "Add to targets".
+
+##Getting started
+If you haven't done so, make sure you know your organization name and your application name. Your organization name will be the same as the username you signed up with.  
+
+Within your organization, you can have multiple application namespaces.  By default, an application named "Sandbox" has been created for you to use for testing, but you can also log into the [Admin Portal](http://apigee.com/usergrid) and create an application with any name you want.
+
+Once you have your application name, you will want to create a UGClient object like so: 
+
+	//configure the org and app
+	NSString * orgName = @"ApigeeOrg";
+	NSString * appName = @"MessageeApp";
+
+	//make new client
+	usergridClient = [[UGClient alloc]initWithOrganizationId: orgName withApplicationID: appName];
+
+Now use the usergridClient object to invoke other methods that access the API.  For example, to log a user in:
+
+	[usergridClient logInUser:username password:password];
+	UGUser *user = [usergridClient getLoggedInUser];
+
+Or, to create a user:
+
+	UGClientResponse *response = [usergridClient addUser:@"myusername" email:@"email@email.com" name:@"my name" password:@"mypassword"];
+    if (response.transactionState == 0) {
+    	//user created!
+    } 
+
+##Sample Code
+If you are ready to look at a fully functional app that uses this SDK, check out the example Apigee Messagee application. It is a twitter-type app that exercises many parts of the API including: Login / Authentication, GET and POST operations, activities (tweets), and social features such as following relationships. 
+
+The Messagee Xcode project is located here:
+
+<https://github.com/apigee/usergrid-sample-ios-messagee>
+
+##Running Tests
+
+The iOS SDK unit tests are written with Nu. You'll need to install the language itself to run the tests, and use the Nukefile to create a Usergrid.framework. For installation directions go [here](https://github.com/timburks/nu)
+
+To compile the Usergrid SDK as an Objective-C framework simple type `nuke` to build the framework and then `nuke install` to install it in the /Library/Frameworks path.
+
+To run the unit tests written for the SDK use the command `nuke test` this will run all tests.
+
+## Contributing
+We welcome your enhancements!
+
+Like [Usergrid](https://github.com/apache/usergrid/), the Usergrid iOS SDK is open source and licensed under the Apache License, Version 2.0.
+
+1. Fork it
+2. Create an issue in [JIRA](https://issues.apache.org/jira/browse/USERGRID/)
+3. Create your feature branch (`git checkout -b USERGRID-${JIRA_NUMBER}`)
+4. Commit your changes (`git commit -am '${JIRA_NUMBER} ${JIRA_TITLE}'`)
+5. Push your changes to the upstream branch (`git push origin my-new-feature`)
+6. Create new Pull Request (make sure you describe what you did and why your mod is needed)

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.h b/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.h
new file mode 100755
index 0000000..c9eeaa5
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.h
@@ -0,0 +1,79 @@
+/*
+ Copyright (C) 2009 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+#pragma mark JSON Writing
+
+/// Adds JSON generation to NSObject
+@interface NSObject (NSObject_SBJsonWriting)
+
+/**
+ @brief Encodes the receiver into a JSON string
+ 
+ Although defined as a category on NSObject it is only defined for NSArray and NSDictionary.
+ 
+ @return the receiver encoded in JSON, or nil on error.
+ 
+ @see @ref objc2json
+ */
+- (NSString *)JSONRepresentation;
+
+@end
+
+
+#pragma mark JSON Parsing
+
+/// Adds JSON parsing methods to NSString
+@interface NSString (NSString_SBJsonParsing)
+
+/**
+ @brief Decodes the receiver's JSON text
+ 
+ @return the NSDictionary or NSArray represented by the receiver, or nil on error.
+ 
+ @see @ref json2objc
+ */
+- (id)JSONValue;
+
+@end
+
+/// Adds JSON parsing methods to NSData
+@interface NSData (NSData_SBJsonParsing)
+
+/**
+ @brief Decodes the receiver's JSON data
+ 
+ @return the NSDictionary or NSArray represented by the receiver, or nil on error.
+ 
+ @see @ref json2objc
+ */
+- (id)JSONValue;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.m b/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.m
new file mode 100755
index 0000000..62b0987
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/NSObject+SBJson.m
@@ -0,0 +1,72 @@
+/*
+ Copyright (C) 2009 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "NSObject+SBJson.h"
+#import "SBJsonWriter.h"
+#import "SBJsonParser.h"
+
+@implementation NSObject (NSObject_SBJsonWriting)
+
+- (NSString *)JSONRepresentation {
+    SBJsonWriter *writer = [[SBJsonWriter alloc] init];    
+    NSString *json = [writer stringWithObject:self];
+    if (!json)
+        NSLog(@"-JSONRepresentation failed. Error is: %@", writer.error);
+    return json;
+}
+
+@end
+
+
+
+@implementation NSString (NSString_SBJsonParsing)
+
+- (id)JSONValue {
+    SBJsonParser *parser = [[SBJsonParser alloc] init];
+    id repr = [parser objectWithString:self];
+    if (!repr)
+        NSLog(@"-JSONValue failed. Error is: %@", parser.error);
+    return repr;
+}
+
+@end
+
+
+
+@implementation NSData (NSData_SBJsonParsing)
+
+- (id)JSONValue {
+    SBJsonParser *parser = [[SBJsonParser alloc] init];
+    id repr = [parser objectWithData:self];
+    if (!repr)
+        NSLog(@"-JSONValue failed. Error is: %@", parser.error);
+    return repr;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJson.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJson.h b/sdks/other/ios/UGAPI/SBJson/SBJson.h
new file mode 100755
index 0000000..b25da4a
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJson.h
@@ -0,0 +1,84 @@
+/*
+ Copyright (C) 2009-2011 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/**
+ @page json2objc JSON to Objective-C
+ 
+ JSON is mapped to Objective-C types in the following way:
+ 
+ @li null    -> NSNull
+ @li string  -> NSString
+ @li array   -> NSMutableArray
+ @li object  -> NSMutableDictionary
+ @li true    -> NSNumber's -numberWithBool:YES
+ @li false   -> NSNumber's -numberWithBool:NO
+ @li integer up to 19 digits -> NSNumber's -numberWithLongLong:
+ @li all other numbers       -> NSDecimalNumber
+ 
+ Since Objective-C doesn't have a dedicated class for boolean values,
+ these turns into NSNumber instances. However, since these are
+ initialised with the -initWithBool: method they round-trip back to JSON
+ properly. In other words, they won't silently suddenly become 0 or 1;
+ they'll be represented as 'true' and 'false' again.
+ 
+ As an optimisation integers up to 19 digits in length (the max length
+ for signed long long integers) turn into NSNumber instances, while
+ complex ones turn into NSDecimalNumber instances. We can thus avoid any
+ loss of precision as JSON allows ridiculously large numbers.
+
+ @page objc2json Objective-C to JSON
+ 
+ Objective-C types are mapped to JSON types in the following way:
+ 
+ @li NSNull        -> null
+ @li NSString      -> string
+ @li NSArray       -> array
+ @li NSDictionary  -> object
+ @li NSNumber's -initWithBool:YES -> true
+ @li NSNumber's -initWithBool:NO  -> false
+ @li NSNumber      -> number
+ 
+ @note In JSON the keys of an object must be strings. NSDictionary
+ keys need not be, but attempting to convert an NSDictionary with
+ non-string keys into JSON will throw an exception.
+ 
+ NSNumber instances created with the -numberWithBool: method are
+ converted into the JSON boolean "true" and "false" values, and vice
+ versa. Any other NSNumber instances are converted to a JSON number the
+ way you would expect.
+
+ */
+
+#import "SBJsonParser.h"
+#import "SBJsonWriter.h"
+#import "SBJsonStreamParser.h"
+#import "SBJsonStreamParserAdapter.h"
+#import "SBJsonStreamWriter.h"
+#import "NSObject+SBJson.h"
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonParser.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonParser.h b/sdks/other/ios/UGAPI/SBJson/SBJsonParser.h
new file mode 100755
index 0000000..751122f
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonParser.h
@@ -0,0 +1,101 @@
+/*
+ Copyright (C) 2009 Stig Brautaset. All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+/**
+ @brief Parse JSON Strings and NSData objects
+
+ This uses SBJsonStreamParser internally.
+
+ @see @ref objc2json
+
+ */
+
+@interface SBJsonParser : NSObject
+
+/**
+ @brief The maximum recursing depth.
+
+ Defaults to 32. If the input is nested deeper than this the input will be deemed to be
+ malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
+ turn off this security feature by setting the maxDepth value to 0.
+ */
+@property NSUInteger maxDepth;
+
+/**
+ @brief Description of parse error
+
+ This method returns the trace of the last method that failed.
+ You need to check the return value of the call you're making to figure out
+ if the call actually failed, before you know call this method.
+
+ @return A string describing the error encountered, or nil if no error occured.
+
+ */
+@property(copy) NSString *error;
+
+/**
+ @brief Return the object represented by the given NSData object.
+
+ The data *must* be UTF8 encoded.
+ 
+ @param data An NSData containing UTF8 encoded data to parse.
+ @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
+
+ */
+- (id)objectWithData:(NSData*)data;
+
+/**
+ @brief Return the object represented by the given string
+
+ This method converts its input to an NSData object containing UTF8 and calls -objectWithData: with it.
+
+ @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
+ */
+- (id)objectWithString:(NSString *)repr;
+
+/**
+ @brief Return the object represented by the given string
+
+ This method calls objectWithString: internally. If an error occurs, and if @p error
+ is not nil, it creates an NSError object and returns this through its second argument.
+
+ @param jsonText the json string to parse
+ @param error pointer to an NSError object to populate on error
+
+ @return The NSArray or NSDictionary represented by the object, or nil if an error occured.
+ */
+
+- (id)objectWithString:(NSString*)jsonText
+                 error:(NSError**)error;
+
+@end
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonParser.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonParser.m b/sdks/other/ios/UGAPI/SBJson/SBJsonParser.m
new file mode 100755
index 0000000..d1b4b1e
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonParser.m
@@ -0,0 +1,100 @@
+/*
+ Copyright (C) 2009,2010 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonParser.h"
+#import "SBJsonStreamParser.h"
+#import "SBJsonStreamParserAdapter.h"
+#import "SBJsonStreamParserAccumulator.h"
+
+@implementation SBJsonParser
+
+@synthesize maxDepth;
+@synthesize error;
+
+- (id)init {
+    self = [super init];
+    if (self)
+        self.maxDepth = 32u;
+    return self;
+}
+
+
+#pragma mark Methods
+
+- (id)objectWithData:(NSData *)data {
+
+    if (!data) {
+        self.error = @"Input was 'nil'";
+        return nil;
+    }
+
+	SBJsonStreamParserAccumulator *accumulator = [[SBJsonStreamParserAccumulator alloc] init];
+    
+    SBJsonStreamParserAdapter *adapter = [[SBJsonStreamParserAdapter alloc] init];
+    adapter.delegate = accumulator;
+	
+	SBJsonStreamParser *parser = [[SBJsonStreamParser alloc] init];
+	parser.maxDepth = self.maxDepth;
+	parser.delegate = adapter;
+	
+	switch ([parser parse:data]) {
+		case SBJsonStreamParserComplete:
+            return accumulator.value;
+			break;
+			
+		case SBJsonStreamParserWaitingForData:
+		    self.error = @"Unexpected end of input";
+			break;
+
+		case SBJsonStreamParserError:
+		    self.error = parser.error;
+			break;
+	}
+	
+	return nil;
+}
+
+- (id)objectWithString:(NSString *)repr {
+	return [self objectWithData:[repr dataUsingEncoding:NSUTF8StringEncoding]];
+}
+
+- (id)objectWithString:(NSString*)repr error:(NSError**)error_ {
+	id tmp = [self objectWithString:repr];
+    if (tmp)
+        return tmp;
+    
+    if (error_) {
+		NSDictionary *ui = [NSDictionary dictionaryWithObjectsAndKeys:error, NSLocalizedDescriptionKey, nil];
+        *error_ = [NSError errorWithDomain:@"org.brautaset.SBJsonParser.ErrorDomain" code:0 userInfo:ui];
+	}
+	
+    return nil;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.h
new file mode 100755
index 0000000..2530eca
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.h
@@ -0,0 +1,161 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+@class SBJsonTokeniser;
+@class SBJsonStreamParser;
+@class SBJsonStreamParserState;
+
+typedef enum {
+	SBJsonStreamParserComplete,
+	SBJsonStreamParserWaitingForData,
+	SBJsonStreamParserError,
+} SBJsonStreamParserStatus;
+
+
+/**
+ @brief Delegate for interacting directly with the stream parser
+ 
+ You will most likely find it much more convenient to implement the
+ SBJsonStreamParserAdapterDelegate protocol instead.
+ */
+@protocol SBJsonStreamParserDelegate
+
+/// Called when object start is found
+- (void)parserFoundObjectStart:(SBJsonStreamParser*)parser;
+
+/// Called when object key is found
+- (void)parser:(SBJsonStreamParser*)parser foundObjectKey:(NSString*)key;
+
+/// Called when object end is found
+- (void)parserFoundObjectEnd:(SBJsonStreamParser*)parser;
+
+/// Called when array start is found
+- (void)parserFoundArrayStart:(SBJsonStreamParser*)parser;
+
+/// Called when array end is found
+- (void)parserFoundArrayEnd:(SBJsonStreamParser*)parser;
+
+/// Called when a boolean value is found
+- (void)parser:(SBJsonStreamParser*)parser foundBoolean:(BOOL)x;
+
+/// Called when a null value is found
+- (void)parserFoundNull:(SBJsonStreamParser*)parser;
+
+/// Called when a number is found
+- (void)parser:(SBJsonStreamParser*)parser foundNumber:(NSNumber*)num;
+
+/// Called when a string is found
+- (void)parser:(SBJsonStreamParser*)parser foundString:(NSString*)string;
+
+@end
+
+
+/**
+ @brief Parse a stream of JSON data.
+ 
+ Using this class directly you can reduce the apparent latency for each
+ download/parse cycle of documents over a slow connection. You can start
+ parsing *and return chunks of the parsed document* before the entire
+ document is downloaded.
+ 
+ Using this class is also useful to parse huge documents on disk
+ bit by bit so you don't have to keep them all in memory. 
+ 
+ @see SBJsonStreamParserAdapter for more information.
+ 
+ @see @ref objc2json
+ 
+ */
+@interface SBJsonStreamParser : NSObject {
+@private
+	SBJsonTokeniser *tokeniser;
+}
+
+@property (nonatomic, unsafe_unretained) SBJsonStreamParserState *state; // Private
+@property (nonatomic, readonly, strong) NSMutableArray *stateStack; // Private
+
+/**
+ @brief Expect multiple documents separated by whitespace
+
+ Normally the @p -parse: method returns SBJsonStreamParserComplete when it's found a complete JSON document.
+ Attempting to parse any more data at that point is considered an error. ("Garbage after JSON".)
+ 
+ If you set this property to true the parser will never return SBJsonStreamParserComplete. Rather,
+ once an object is completed it will expect another object to immediately follow, separated
+ only by (optional) whitespace.
+
+ @see The TweetStream app in the Examples
+ */
+@property BOOL supportMultipleDocuments;
+
+/**
+ @brief Delegate to receive messages
+
+ The object set here receives a series of messages as the parser breaks down the JSON stream
+ into valid tokens.
+
+ @note
+ Usually this should be an instance of SBJsonStreamParserAdapter, but you can
+ substitute your own implementation of the SBJsonStreamParserDelegate protocol if you need to. 
+ */
+@property (unsafe_unretained) id<SBJsonStreamParserDelegate> delegate;
+
+/**
+ @brief The max parse depth
+ 
+ If the input is nested deeper than this the parser will halt parsing and return an error.
+
+ Defaults to 32. 
+ */
+@property NSUInteger maxDepth;
+
+/// Holds the error after SBJsonStreamParserError was returned
+@property (copy) NSString *error;
+
+/**
+ @brief Parse some JSON
+ 
+ The JSON is assumed to be UTF8 encoded. This can be a full JSON document, or a part of one.
+
+ @param data An NSData object containing the next chunk of JSON
+
+ @return 
+ @li SBJsonStreamParserComplete if a full document was found
+ @li SBJsonStreamParserWaitingForData if a partial document was found and more data is required to complete it
+ @li SBJsonStreamParserError if an error occured. (See the error property for details in this case.)
+ 
+ */
+- (SBJsonStreamParserStatus)parse:(NSData*)data;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.m
new file mode 100755
index 0000000..134e34a
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParser.m
@@ -0,0 +1,255 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+
+ Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+
+ Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+ Neither the name of the the author nor the names of its contributors
+ may be used to endorse or promote products derived from this software
+ without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamParser.h"
+#import "SBJsonTokeniser.h"
+#import "SBJsonStreamParserState.h"
+#import <limits.h>
+
+@implementation SBJsonStreamParser
+
+@synthesize supportMultipleDocuments;
+@synthesize error;
+@synthesize delegate;
+@synthesize maxDepth;
+@synthesize state;
+@synthesize stateStack;
+
+#pragma mark Housekeeping
+
+- (id)init {
+	self = [super init];
+	if (self) {
+		maxDepth = 32u;
+        stateStack = [[NSMutableArray alloc] initWithCapacity:maxDepth];
+        state = [SBJsonStreamParserStateStart sharedInstance];
+		tokeniser = [[SBJsonTokeniser alloc] init];
+	}
+	return self;
+}
+
+- (void)dealloc {
+    self.state = nil;
+}
+
+#pragma mark Methods
+
+- (NSString*)tokenName:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_array_start:
+			return @"start of array";
+			break;
+
+		case sbjson_token_array_end:
+			return @"end of array";
+			break;
+
+		case sbjson_token_number:
+			return @"number";
+			break;
+
+		case sbjson_token_string:
+			return @"string";
+			break;
+
+		case sbjson_token_true:
+		case sbjson_token_false:
+			return @"boolean";
+			break;
+
+		case sbjson_token_null:
+			return @"null";
+			break;
+
+		case sbjson_token_keyval_separator:
+			return @"key-value separator";
+			break;
+
+		case sbjson_token_separator:
+			return @"value separator";
+			break;
+
+		case sbjson_token_object_start:
+			return @"start of object";
+			break;
+
+		case sbjson_token_object_end:
+			return @"end of object";
+			break;
+
+		case sbjson_token_eof:
+		case sbjson_token_error:
+			break;
+	}
+	NSAssert(NO, @"Should not get here");
+	return @"<aaiiie!>";
+}
+
+- (void)maxDepthError {
+    self.error = [NSString stringWithFormat:@"Input depth exceeds max depth of %lu", maxDepth];
+    self.state = [SBJsonStreamParserStateError sharedInstance];
+}
+
+- (void)handleObjectStart {
+	if (stateStack.count >= maxDepth) {
+        [self maxDepthError];
+        return;
+	}
+
+    [delegate parserFoundObjectStart:self];
+    [stateStack addObject:state];
+    self.state = [SBJsonStreamParserStateObjectStart sharedInstance];
+}
+
+- (void)handleObjectEnd: (sbjson_token_t) tok  {
+    self.state = [stateStack lastObject];
+    [stateStack removeLastObject];
+    [state parser:self shouldTransitionTo:tok];
+    [delegate parserFoundObjectEnd:self];
+}
+
+- (void)handleArrayStart {
+	if (stateStack.count >= maxDepth) {
+        [self maxDepthError];
+        return;
+    }
+	
+	[delegate parserFoundArrayStart:self];
+    [stateStack addObject:state];
+    self.state = [SBJsonStreamParserStateArrayStart sharedInstance];
+}
+
+- (void)handleArrayEnd: (sbjson_token_t) tok  {
+    self.state = [stateStack lastObject];
+    [stateStack removeLastObject];
+    [state parser:self shouldTransitionTo:tok];
+    [delegate parserFoundArrayEnd:self];
+}
+
+- (void) handleTokenNotExpectedHere: (sbjson_token_t) tok  {
+    NSString *tokenName = [self tokenName:tok];
+    NSString *stateName = [state name];
+
+    self.error = [NSString stringWithFormat:@"Token '%@' not expected %@", tokenName, stateName];
+    self.state = [SBJsonStreamParserStateError sharedInstance];
+}
+
+- (SBJsonStreamParserStatus)parse:(NSData *)data_ {
+    @autoreleasepool {
+        [tokeniser appendData:data_];
+        
+        for (;;) {
+            
+            if ([state isError])
+                return SBJsonStreamParserError;
+            
+            NSObject *token;
+            sbjson_token_t tok = [tokeniser getToken:&token];
+            switch (tok) {
+                case sbjson_token_eof:
+                    return [state parserShouldReturn:self];
+                    break;
+                    
+                case sbjson_token_error:
+                    self.state = [SBJsonStreamParserStateError sharedInstance];
+                    self.error = tokeniser.error;
+                    return SBJsonStreamParserError;
+                    break;
+                    
+                default:
+                    
+                    if (![state parser:self shouldAcceptToken:tok]) {
+                        [self handleTokenNotExpectedHere: tok];
+                        return SBJsonStreamParserError;
+                    }
+                    
+                    switch (tok) {
+                        case sbjson_token_object_start:
+                            [self handleObjectStart];
+                            break;
+                            
+                        case sbjson_token_object_end:
+                            [self handleObjectEnd: tok];
+                            break;
+                            
+                        case sbjson_token_array_start:
+                            [self handleArrayStart];
+                            break;
+                            
+                        case sbjson_token_array_end:
+                            [self handleArrayEnd: tok];
+                            break;
+                            
+                        case sbjson_token_separator:
+                        case sbjson_token_keyval_separator:
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        case sbjson_token_true:
+                            [delegate parser:self foundBoolean:YES];
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        case sbjson_token_false:
+                            [delegate parser:self foundBoolean:NO];
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        case sbjson_token_null:
+                            [delegate parserFoundNull:self];
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        case sbjson_token_number:
+                            [delegate parser:self foundNumber:(NSNumber*)token];
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        case sbjson_token_string:
+                            if ([state needKey])
+                                [delegate parser:self foundObjectKey:(NSString*)token];
+                            else
+                                [delegate parser:self foundString:(NSString*)token];
+                            [state parser:self shouldTransitionTo:tok];
+                            break;
+                            
+                        default:
+                            break;
+                    }
+                    break;
+            }
+        }
+        return SBJsonStreamParserComplete;
+    }
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
new file mode 100755
index 0000000..141d6ee
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.h
@@ -0,0 +1,37 @@
+/*
+ Copyright (C) 2011 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+#import "SBJsonStreamParserAdapter.h"
+
+@interface SBJsonStreamParserAccumulator : NSObject <SBJsonStreamParserAdapterDelegate>
+
+@property (copy) id value;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
new file mode 100755
index 0000000..1d39ceb
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAccumulator.m
@@ -0,0 +1,47 @@
+/*
+ Copyright (C) 2011 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamParserAccumulator.h"
+
+@implementation SBJsonStreamParserAccumulator
+
+@synthesize value;
+
+
+#pragma mark SBJsonStreamParserAdapterDelegate
+
+- (void)parser:(SBJsonStreamParser*)parser foundArray:(NSArray *)array {
+	value = array;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser foundObject:(NSDictionary *)dict {
+	value = dict;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
new file mode 100755
index 0000000..942bc01
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.h
@@ -0,0 +1,148 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+#import "SBJsonStreamParser.h"
+
+typedef enum {
+	SBJsonStreamParserAdapterNone,
+	SBJsonStreamParserAdapterArray,
+	SBJsonStreamParserAdapterObject,
+} SBJsonStreamParserAdapterType;
+
+/**
+ @brief Delegate for getting objects & arrays from the stream parser adapter
+ 
+ @see The TweetStream example project.
+ */
+@protocol SBJsonStreamParserAdapterDelegate
+
+/**
+ @brief Called if a JSON array is found
+ 
+ This method is called if a JSON array is found.
+ 
+ */
+- (void)parser:(SBJsonStreamParser*)parser foundArray:(NSArray*)array;
+
+/**
+ @brief Called when a JSON object is found
+
+ This method is called if a JSON object is found.
+ */
+- (void)parser:(SBJsonStreamParser*)parser foundObject:(NSDictionary*)dict;
+
+@end
+
+/**
+ @brief SBJsonStreamParserDelegate protocol adapter
+ 
+ Rather than implementing the SBJsonStreamParserDelegate protocol yourself you will
+ most likely find it much more convenient to use an instance of this class and
+ implement the SBJsonStreamParserAdapterDelegate protocol instead.
+ 
+ The default behaviour is that the delegate only receives one call from
+ either the -parser:foundArray: or -parser:foundObject: method when the
+ document is fully parsed. However, if your inputs contains multiple JSON
+ documents and you set the parser's -supportMultipleDocuments property to YES
+ you will get one call for each full method.
+ 
+ @code
+ SBJsonStreamParserAdapter *adapter = [[[SBJsonStreamParserAdapter alloc] init] autorelease];
+ adapter.delegate = self;
+ 
+ SBJsonStreamParser *parser = [[[SBJsonStreamParser alloc] init] autorelease];
+ parser.delegate = adapter;
+ parser.supportMultipleDocuments = YES;
+
+ // Note that this input contains multiple top-level JSON documents
+ NSData *json = [@"[]{}[]{}" dataWithEncoding:NSUTF8StringEncoding]; 
+ [parser parse:data];
+ @endcode
+ 
+ In the above example @p self will have the following sequence of methods called on it:
+ 
+ @li -parser:foundArray:
+ @li -parser:foundObject:
+ @li -parser:foundArray:
+ @li -parser:foundObject:
+
+ Often you won't have control over the input you're parsing, so can't make use of
+ this feature. But, all is not lost: this class will let you get the same effect by 
+ allowing you to skip one or more of the outer enclosing objects. Thus, the next
+ example results in the same sequence of -parser:foundArray: / -parser:foundObject:
+ being called on your delegate.
+ 
+ @code
+ SBJsonStreamParserAdapter *adapter = [[[SBJsonStreamParserAdapter alloc] init] autorelease];
+ adapter.delegate = self;
+ adapter.levelsToSkip = 1;
+ 
+ SBJsonStreamParser *parser = [[[SBJsonStreamParser alloc] init] autorelease];
+ parser.delegate = adapter;
+ 
+ // Note that this input contains A SINGLE top-level document
+ NSData *json = [@"[[],{},[],{}]" dataWithEncoding:NSUTF8StringEncoding]; 
+ [parser parse:data];
+ @endcode
+ 
+*/
+@interface SBJsonStreamParserAdapter : NSObject <SBJsonStreamParserDelegate> {
+@private
+	NSUInteger depth;
+    NSMutableArray *array;
+	NSMutableDictionary *dict;
+	NSMutableArray *keyStack;
+	NSMutableArray *stack;
+	
+	SBJsonStreamParserAdapterType currentType;
+}
+
+/**
+ @brief How many levels to skip
+ 
+ This is useful for parsing huge JSON documents, or documents coming in over a very slow link.
+ 
+ If you set this to N it will skip the outer N levels and call the -parser:foundArray:
+ or -parser:foundObject: methods for each of the inner objects, as appropriate.
+ 
+ @see The StreamParserIntegrationTest.m file for examples
+*/
+@property NSUInteger levelsToSkip;
+
+/**
+ @brief Your delegate object
+ Set this to the object you want to receive the SBJsonStreamParserAdapterDelegate messages.
+ */
+@property (unsafe_unretained) id<SBJsonStreamParserAdapterDelegate> delegate;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
new file mode 100755
index 0000000..e77b534
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserAdapter.m
@@ -0,0 +1,164 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamParserAdapter.h"
+
+@interface SBJsonStreamParserAdapter ()
+
+- (void)pop;
+- (void)parser:(SBJsonStreamParser*)parser found:(id)obj;
+
+@end
+
+
+
+@implementation SBJsonStreamParserAdapter
+
+@synthesize delegate;
+@synthesize levelsToSkip;
+
+#pragma mark Housekeeping
+
+- (id)init {
+	self = [super init];
+	if (self) {
+		keyStack = [[NSMutableArray alloc] initWithCapacity:32];
+		stack = [[NSMutableArray alloc] initWithCapacity:32];
+		
+		currentType = SBJsonStreamParserAdapterNone;
+	}
+	return self;
+}	
+
+
+#pragma mark Private methods
+
+- (void)pop {
+	[stack removeLastObject];
+	array = nil;
+	dict = nil;
+	currentType = SBJsonStreamParserAdapterNone;
+	
+	id value = [stack lastObject];
+	
+	if ([value isKindOfClass:[NSArray class]]) {
+		array = value;
+		currentType = SBJsonStreamParserAdapterArray;
+	} else if ([value isKindOfClass:[NSDictionary class]]) {
+		dict = value;
+		currentType = SBJsonStreamParserAdapterObject;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser found:(id)obj {
+	NSParameterAssert(obj);
+	
+	switch (currentType) {
+		case SBJsonStreamParserAdapterArray:
+			[array addObject:obj];
+			break;
+
+		case SBJsonStreamParserAdapterObject:
+			NSParameterAssert(keyStack.count);
+			[dict setObject:obj forKey:[keyStack lastObject]];
+			[keyStack removeLastObject];
+			break;
+			
+		case SBJsonStreamParserAdapterNone:
+			if ([obj isKindOfClass:[NSArray class]]) {
+				[delegate parser:parser foundArray:obj];
+			} else {
+				[delegate parser:parser foundObject:obj];
+			}				
+			break;
+
+		default:
+			break;
+	}
+}
+
+
+#pragma mark Delegate methods
+
+- (void)parserFoundObjectStart:(SBJsonStreamParser*)parser {
+	if (++depth > self.levelsToSkip) {
+		dict = [NSMutableDictionary new];
+		[stack addObject:dict];
+		currentType = SBJsonStreamParserAdapterObject;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser foundObjectKey:(NSString*)key_ {
+	[keyStack addObject:key_];
+}
+
+- (void)parserFoundObjectEnd:(SBJsonStreamParser*)parser {
+	if (depth-- > self.levelsToSkip) {
+		id value = dict;
+		[self pop];
+		[self parser:parser found:value];
+	}
+}
+
+- (void)parserFoundArrayStart:(SBJsonStreamParser*)parser {
+	if (++depth > self.levelsToSkip) {
+		array = [NSMutableArray new];
+		[stack addObject:array];
+		currentType = SBJsonStreamParserAdapterArray;
+	}
+}
+
+- (void)parserFoundArrayEnd:(SBJsonStreamParser*)parser {
+	if (depth-- > self.levelsToSkip) {
+		id value = array;
+		[self pop];
+		[self parser:parser found:value];
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser foundBoolean:(BOOL)x {
+	[self parser:parser found:[NSNumber numberWithBool:x]];
+}
+
+- (void)parserFoundNull:(SBJsonStreamParser*)parser {
+	[self parser:parser found:[NSNull null]];
+}
+
+- (void)parser:(SBJsonStreamParser*)parser foundNumber:(NSNumber*)num {
+	[self parser:parser found:num];
+}
+
+- (void)parser:(SBJsonStreamParser*)parser foundString:(NSString*)string {
+	[self parser:parser found:string];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.h
new file mode 100755
index 0000000..ea893cb
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.h
@@ -0,0 +1,83 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+#import "SBJsonTokeniser.h"
+#import "SBJsonStreamParser.h"
+
+@interface SBJsonStreamParserState : NSObject
++ (id)sharedInstance;
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token;
+- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser;
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok;
+- (BOOL)needKey;
+- (BOOL)isError;
+
+- (NSString*)name;
+
+@end
+
+@interface SBJsonStreamParserStateStart : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateComplete : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateError : SBJsonStreamParserState
+@end
+
+
+@interface SBJsonStreamParserStateObjectStart : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateObjectGotKey : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateObjectSeparator : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateObjectGotValue : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateObjectNeedKey : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateArrayStart : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateArrayGotValue : SBJsonStreamParserState
+@end
+
+@interface SBJsonStreamParserStateArrayNeedValue : SBJsonStreamParserState
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.m
new file mode 100755
index 0000000..a24c6f6
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamParserState.m
@@ -0,0 +1,355 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamParserState.h"
+#import "SBJsonStreamParser.h"
+
+#define SINGLETON \
++ (id)sharedInstance { \
+    static id state; \
+    if (!state) state = [[self alloc] init]; \
+    return state; \
+}
+
+@implementation SBJsonStreamParserState
+
++ (id)sharedInstance { return nil; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	return NO;
+}
+
+- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
+	return SBJsonStreamParserWaitingForData;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {}
+
+- (BOOL)needKey {
+	return NO;
+}
+
+- (NSString*)name {
+	return @"<aaiie!>";
+}
+
+- (BOOL)isError {
+    return NO;
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateStart
+
+SINGLETON
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	return token == sbjson_token_array_start || token == sbjson_token_object_start;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+
+	SBJsonStreamParserState *state = nil;
+	switch (tok) {
+		case sbjson_token_array_start:
+			state = [SBJsonStreamParserStateArrayStart sharedInstance];
+			break;
+
+		case sbjson_token_object_start:
+			state = [SBJsonStreamParserStateObjectStart sharedInstance];
+			break;
+
+		case sbjson_token_array_end:
+		case sbjson_token_object_end:
+			if (parser.supportMultipleDocuments)
+				state = parser.state;
+			else
+				state = [SBJsonStreamParserStateComplete sharedInstance];
+			break;
+
+		case sbjson_token_eof:
+			return;
+
+		default:
+			state = [SBJsonStreamParserStateError sharedInstance];
+			break;
+	}
+
+
+	parser.state = state;
+}
+
+- (NSString*)name { return @"before outer-most array or object"; }
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateComplete
+
+SINGLETON
+
+- (NSString*)name { return @"after outer-most array or object"; }
+
+- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
+	return SBJsonStreamParserComplete;
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateError
+
+SINGLETON
+
+- (NSString*)name { return @"in error"; }
+
+- (SBJsonStreamParserStatus)parserShouldReturn:(SBJsonStreamParser*)parser {
+	return SBJsonStreamParserError;
+}
+
+- (BOOL)isError {
+    return YES;
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateObjectStart
+
+SINGLETON
+
+- (NSString*)name { return @"at beginning of object"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_object_end:
+		case sbjson_token_string:
+			return YES;
+			break;
+		default:
+			return NO;
+			break;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateObjectGotKey sharedInstance];
+}
+
+- (BOOL)needKey {
+	return YES;
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateObjectGotKey
+
+SINGLETON
+
+- (NSString*)name { return @"after object key"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	return token == sbjson_token_keyval_separator;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateObjectSeparator sharedInstance];
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateObjectSeparator
+
+SINGLETON
+
+- (NSString*)name { return @"as object value"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_object_start:
+		case sbjson_token_array_start:
+		case sbjson_token_true:
+		case sbjson_token_false:
+		case sbjson_token_null:
+		case sbjson_token_number:
+		case sbjson_token_string:
+			return YES;
+			break;
+
+		default:
+			return NO;
+			break;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateObjectGotValue sharedInstance];
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateObjectGotValue
+
+SINGLETON
+
+- (NSString*)name { return @"after object value"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_object_end:
+		case sbjson_token_separator:
+			return YES;
+			break;
+		default:
+			return NO;
+			break;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateObjectNeedKey sharedInstance];
+}
+
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateObjectNeedKey
+
+SINGLETON
+
+- (NSString*)name { return @"in place of object key"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+    return sbjson_token_string == token;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateObjectGotKey sharedInstance];
+}
+
+- (BOOL)needKey {
+	return YES;
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateArrayStart
+
+SINGLETON
+
+- (NSString*)name { return @"at array start"; }
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_object_end:
+		case sbjson_token_keyval_separator:
+		case sbjson_token_separator:
+			return NO;
+			break;
+
+		default:
+			return YES;
+			break;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateArrayGotValue sharedInstance];
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateArrayGotValue
+
+SINGLETON
+
+- (NSString*)name { return @"after array value"; }
+
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	return token == sbjson_token_array_end || token == sbjson_token_separator;
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	if (tok == sbjson_token_separator)
+		parser.state = [SBJsonStreamParserStateArrayNeedValue sharedInstance];
+}
+
+@end
+
+#pragma mark -
+
+@implementation SBJsonStreamParserStateArrayNeedValue
+
+SINGLETON
+
+- (NSString*)name { return @"as array value"; }
+
+
+- (BOOL)parser:(SBJsonStreamParser*)parser shouldAcceptToken:(sbjson_token_t)token {
+	switch (token) {
+		case sbjson_token_array_end:
+		case sbjson_token_keyval_separator:
+		case sbjson_token_object_end:
+		case sbjson_token_separator:
+			return NO;
+			break;
+
+		default:
+			return YES;
+			break;
+	}
+}
+
+- (void)parser:(SBJsonStreamParser*)parser shouldTransitionTo:(sbjson_token_t)tok {
+	parser.state = [SBJsonStreamParserStateArrayGotValue sharedInstance];
+}
+
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.h
new file mode 100755
index 0000000..a46b7a1
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.h
@@ -0,0 +1,195 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+ 
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+  
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+ 
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import <Foundation/Foundation.h>
+
+/// Enable JSON writing for non-native objects
+@interface NSObject (SBProxyForJson)
+
+/**
+ @brief Allows generation of JSON for otherwise unsupported classes.
+ 
+ If you have a custom class that you want to create a JSON representation
+ for you can implement this method in your class. It should return a
+ representation of your object defined in terms of objects that can be
+ translated into JSON. For example, a Person object might implement it like this:
+ 
+ @code
+ - (id)proxyForJson {
+	return [NSDictionary dictionaryWithObjectsAndKeys:
+	name, @"name",
+	phone, @"phone",
+	email, @"email",
+	nil];
+ }
+ @endcode
+ 
+ */
+- (id)proxyForJson;
+
+@end
+
+@class SBJsonStreamWriter;
+
+@protocol SBJsonStreamWriterDelegate
+
+- (void)writer:(SBJsonStreamWriter*)writer appendBytes:(const void *)bytes length:(NSUInteger)length;
+
+@end
+
+@class SBJsonStreamWriterState;
+
+/**
+ @brief The Stream Writer class.
+ 
+ Accepts a stream of messages and writes JSON of these to its delegate object.
+ 
+ This class provides a range of high-, mid- and low-level methods. You can mix
+ and match calls to these. For example, you may want to call -writeArrayOpen
+ to start an array and then repeatedly call -writeObject: with various objects
+ before finishing off with a -writeArrayClose call.
+  
+ @see @ref json2objc
+
+ */
+
+@interface SBJsonStreamWriter : NSObject {
+    NSMutableDictionary *cache;
+}
+
+@property (nonatomic, unsafe_unretained) SBJsonStreamWriterState *state; // Internal
+@property (nonatomic, readonly, strong) NSMutableArray *stateStack; // Internal 
+
+/**
+ @brief delegate to receive JSON output
+ Delegate that will receive messages with output.
+ */
+@property (unsafe_unretained) id<SBJsonStreamWriterDelegate> delegate;
+
+/**
+ @brief The maximum recursing depth.
+ 
+ Defaults to 512. If the input is nested deeper than this the input will be deemed to be
+ malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
+ turn off this security feature by setting the maxDepth value to 0.
+ */
+@property NSUInteger maxDepth;
+
+/**
+ @brief Whether we are generating human-readable (multiline) JSON.
+ 
+ Set whether or not to generate human-readable JSON. The default is NO, which produces
+ JSON without any whitespace between tokens. If set to YES, generates human-readable
+ JSON with linebreaks after each array value and dictionary key/value pair, indented two
+ spaces per nesting level.
+ */
+@property BOOL humanReadable;
+
+/**
+ @brief Whether or not to sort the dictionary keys in the output.
+ 
+ If this is set to YES, the dictionary keys in the JSON output will be in sorted order.
+ (This is useful if you need to compare two structures, for example.) The default is NO.
+ */
+@property BOOL sortKeys;
+
+/**
+ @brief An optional comparator to be used if sortKeys is YES.
+ 
+ If this is nil, sorting will be done via @selector(compare:).
+ */
+@property (copy) NSComparator sortKeysComparator;
+
+/// Contains the error description after an error has occured.
+@property (copy) NSString *error;
+
+/** 
+ Write an NSDictionary to the JSON stream.
+ @return YES if successful, or NO on failure
+ */
+- (BOOL)writeObject:(NSDictionary*)dict;
+
+/**
+ Write an NSArray to the JSON stream.
+ @return YES if successful, or NO on failure
+ */
+- (BOOL)writeArray:(NSArray *)array;
+
+/** 
+ Start writing an Object to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeObjectOpen;
+
+/**
+ Close the current object being written
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeObjectClose;
+
+/** Start writing an Array to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeArrayOpen;
+
+/** Close the current Array being written
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeArrayClose;
+
+/** Write a null to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeNull;
+
+/** Write a boolean to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeBool:(BOOL)x;
+
+/** Write a Number to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeNumber:(NSNumber*)n;
+
+/** Write a String to the stream
+ @return YES if successful, or NO on failure
+*/
+- (BOOL)writeString:(NSString*)s;
+
+@end
+
+@interface SBJsonStreamWriter (Private)
+- (BOOL)writeValue:(id)v;
+- (void)appendBytes:(const void *)bytes length:(NSUInteger)length;
+@end
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.m
new file mode 100755
index 0000000..1cdd26d
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriter.m
@@ -0,0 +1,374 @@
+/*
+ Copyright (c) 2010, Stig Brautaset.
+ All rights reserved.
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are
+ met:
+
+   Redistributions of source code must retain the above copyright
+   notice, this list of conditions and the following disclaimer.
+
+   Redistributions in binary form must reproduce the above copyright
+   notice, this list of conditions and the following disclaimer in the
+   documentation and/or other materials provided with the distribution.
+
+   Neither the name of the the author nor the names of its contributors
+   may be used to endorse or promote products derived from this software
+   without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+ PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamWriter.h"
+#import "SBJsonStreamWriterState.h"
+
+static NSNumber *kNotANumber;
+static NSNumber *kTrue;
+static NSNumber *kFalse;
+static NSNumber *kPositiveInfinity;
+static NSNumber *kNegativeInfinity;
+
+
+@implementation SBJsonStreamWriter
+
+@synthesize error;
+@synthesize maxDepth;
+@synthesize state;
+@synthesize stateStack;
+@synthesize humanReadable;
+@synthesize sortKeys;
+@synthesize sortKeysComparator;
+
++ (void)initialize {
+	kNotANumber = [NSDecimalNumber notANumber];
+    kPositiveInfinity = [NSNumber numberWithDouble:+INFINITY];
+    kNegativeInfinity = [NSNumber numberWithDouble:-INFINITY];
+    kTrue = [NSNumber numberWithBool:YES];
+    kFalse = [NSNumber numberWithBool:NO];
+}
+
+#pragma mark Housekeeping
+
+@synthesize delegate;
+
+- (id)init {
+	self = [super init];
+	if (self) {
+		maxDepth = 32u;
+        stateStack = [[NSMutableArray alloc] initWithCapacity:maxDepth];
+        state = [SBJsonStreamWriterStateStart sharedInstance];
+        cache = [[NSMutableDictionary alloc] initWithCapacity:32];
+    }
+	return self;
+}
+
+- (void)dealloc {
+    self.state = nil;
+}
+
+#pragma mark Methods
+
+- (void)appendBytes:(const void *)bytes length:(NSUInteger)length {
+    [delegate writer:self appendBytes:bytes length:length];
+}
+
+- (BOOL)writeObject:(NSDictionary *)dict {
+	if (![self writeObjectOpen])
+		return NO;
+
+	NSArray *keys = [dict allKeys];
+	
+	if (sortKeys) {
+		if (sortKeysComparator) {
+			keys = [keys sortedArrayWithOptions:NSSortStable usingComparator:sortKeysComparator];
+		}
+		else{
+			keys = [keys sortedArrayUsingSelector:@selector(compare:)];
+		}
+	}
+
+	for (id k in keys) {
+		if (![k isKindOfClass:[NSString class]]) {
+			self.error = [NSString stringWithFormat:@"JSON object key must be string: %@", k];
+			return NO;
+		}
+
+		if (![self writeString:k])
+			return NO;
+		if (![self writeValue:[dict objectForKey:k]])
+			return NO;
+	}
+
+	return [self writeObjectClose];
+}
+
+- (BOOL)writeArray:(NSArray*)array {
+	if (![self writeArrayOpen])
+		return NO;
+	for (id v in array)
+		if (![self writeValue:v])
+			return NO;
+	return [self writeArrayClose];
+}
+
+
+- (BOOL)writeObjectOpen {
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable && stateStack.count) [state appendWhitespace:self];
+
+    [stateStack addObject:state];
+    self.state = [SBJsonStreamWriterStateObjectStart sharedInstance];
+
+	if (maxDepth && stateStack.count > maxDepth) {
+		self.error = @"Nested too deep";
+		return NO;
+	}
+
+	[delegate writer:self appendBytes:"{" length:1];
+	return YES;
+}
+
+- (BOOL)writeObjectClose {
+	if ([state isInvalidState:self]) return NO;
+
+    SBJsonStreamWriterState *prev = state;
+
+    self.state = [stateStack lastObject];
+    [stateStack removeLastObject];
+
+	if (humanReadable) [prev appendWhitespace:self];
+	[delegate writer:self appendBytes:"}" length:1];
+
+	[state transitionState:self];
+	return YES;
+}
+
+- (BOOL)writeArrayOpen {
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable && stateStack.count) [state appendWhitespace:self];
+
+    [stateStack addObject:state];
+	self.state = [SBJsonStreamWriterStateArrayStart sharedInstance];
+
+	if (maxDepth && stateStack.count > maxDepth) {
+		self.error = @"Nested too deep";
+		return NO;
+	}
+
+	[delegate writer:self appendBytes:"[" length:1];
+	return YES;
+}
+
+- (BOOL)writeArrayClose {
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+
+    SBJsonStreamWriterState *prev = state;
+
+    self.state = [stateStack lastObject];
+    [stateStack removeLastObject];
+
+	if (humanReadable) [prev appendWhitespace:self];
+	[delegate writer:self appendBytes:"]" length:1];
+
+	[state transitionState:self];
+	return YES;
+}
+
+- (BOOL)writeNull {
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable) [state appendWhitespace:self];
+
+	[delegate writer:self appendBytes:"null" length:4];
+	[state transitionState:self];
+	return YES;
+}
+
+- (BOOL)writeBool:(BOOL)x {
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable) [state appendWhitespace:self];
+
+	if (x)
+		[delegate writer:self appendBytes:"true" length:4];
+	else
+		[delegate writer:self appendBytes:"false" length:5];
+	[state transitionState:self];
+	return YES;
+}
+
+
+- (BOOL)writeValue:(id)o {
+	if ([o isKindOfClass:[NSDictionary class]]) {
+		return [self writeObject:o];
+
+	} else if ([o isKindOfClass:[NSArray class]]) {
+		return [self writeArray:o];
+
+	} else if ([o isKindOfClass:[NSString class]]) {
+		[self writeString:o];
+		return YES;
+
+	} else if ([o isKindOfClass:[NSNumber class]]) {
+		return [self writeNumber:o];
+
+	} else if ([o isKindOfClass:[NSNull class]]) {
+		return [self writeNull];
+
+	} else if ([o respondsToSelector:@selector(proxyForJson)]) {
+		return [self writeValue:[o proxyForJson]];
+
+	}
+
+	self.error = [NSString stringWithFormat:@"JSON serialisation not supported for %@", [o class]];
+	return NO;
+}
+
+static const char *strForChar(int c) {
+	switch (c) {
+		case 0: return "\\u0000"; break;
+		case 1: return "\\u0001"; break;
+		case 2: return "\\u0002"; break;
+		case 3: return "\\u0003"; break;
+		case 4: return "\\u0004"; break;
+		case 5: return "\\u0005"; break;
+		case 6: return "\\u0006"; break;
+		case 7: return "\\u0007"; break;
+		case 8: return "\\b"; break;
+		case 9: return "\\t"; break;
+		case 10: return "\\n"; break;
+		case 11: return "\\u000b"; break;
+		case 12: return "\\f"; break;
+		case 13: return "\\r"; break;
+		case 14: return "\\u000e"; break;
+		case 15: return "\\u000f"; break;
+		case 16: return "\\u0010"; break;
+		case 17: return "\\u0011"; break;
+		case 18: return "\\u0012"; break;
+		case 19: return "\\u0013"; break;
+		case 20: return "\\u0014"; break;
+		case 21: return "\\u0015"; break;
+		case 22: return "\\u0016"; break;
+		case 23: return "\\u0017"; break;
+		case 24: return "\\u0018"; break;
+		case 25: return "\\u0019"; break;
+		case 26: return "\\u001a"; break;
+		case 27: return "\\u001b"; break;
+		case 28: return "\\u001c"; break;
+		case 29: return "\\u001d"; break;
+		case 30: return "\\u001e"; break;
+		case 31: return "\\u001f"; break;
+		case 34: return "\\\""; break;
+		case 92: return "\\\\"; break;
+	}
+	NSLog(@"FUTFUTFUT: -->'%c'<---", c);
+	return "FUTFUTFUT";
+}
+
+- (BOOL)writeString:(NSString*)string {
+	if ([state isInvalidState:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable) [state appendWhitespace:self];
+
+	NSMutableData *buf = [cache objectForKey:string];
+	if (!buf) {
+
+        NSUInteger len = [string lengthOfBytesUsingEncoding:NSUTF8StringEncoding];
+        const char *utf8 = [string UTF8String];
+        NSUInteger written = 0, i = 0;
+
+        buf = [NSMutableData dataWithCapacity:(NSUInteger)(len * 1.1f)];
+        [buf appendBytes:"\"" length:1];
+
+        for (i = 0; i < len; i++) {
+            int c = utf8[i];
+            BOOL isControlChar = c >= 0 && c < 32;
+            if (isControlChar || c == '"' || c == '\\') {
+                if (i - written)
+                    [buf appendBytes:utf8 + written length:i - written];
+                written = i + 1;
+
+                const char *t = strForChar(c);
+                [buf appendBytes:t length:strlen(t)];
+            }
+        }
+
+        if (i - written)
+            [buf appendBytes:utf8 + written length:i - written];
+
+        [buf appendBytes:"\"" length:1];
+        [cache setObject:buf forKey:string];
+    }
+
+	[delegate writer:self appendBytes:[buf bytes] length:[buf length]];
+	[state transitionState:self];
+	return YES;
+}
+
+- (BOOL)writeNumber:(NSNumber*)number {
+	if (number == kTrue || number == kFalse)
+		return [self writeBool:[number boolValue]];
+
+	if ([state isInvalidState:self]) return NO;
+	if ([state expectingKey:self]) return NO;
+	[state appendSeparator:self];
+	if (humanReadable) [state appendWhitespace:self];
+
+	if ([kPositiveInfinity isEqualToNumber:number]) {
+		self.error = @"+Infinity is not a valid number in JSON";
+		return NO;
+
+	} else if ([kNegativeInfinity isEqualToNumber:number]) {
+		self.error = @"-Infinity is not a valid number in JSON";
+		return NO;
+
+	} else if ([kNotANumber isEqualToNumber:number]) {
+		self.error = @"NaN is not a valid number in JSON";
+		return NO;
+	}
+
+	const char *objcType = [number objCType];
+	char num[128];
+	size_t len;
+
+	switch (objcType[0]) {
+		case 'c': case 'i': case 's': case 'l': case 'q':
+			len = snprintf(num, sizeof num, "%lld", [number longLongValue]);
+			break;
+		case 'C': case 'I': case 'S': case 'L': case 'Q':
+			len = snprintf(num, sizeof num, "%llu", [number unsignedLongLongValue]);
+			break;
+		case 'f': case 'd': default:
+			if ([number isKindOfClass:[NSDecimalNumber class]]) {
+				char const *utf8 = [[number stringValue] UTF8String];
+				[delegate writer:self appendBytes:utf8 length: strlen(utf8)];
+				[state transitionState:self];
+				return YES;
+			}
+			len = snprintf(num, sizeof num, "%.17g", [number doubleValue]);
+			break;
+	}
+	[delegate writer:self appendBytes:num length: len];
+	[state transitionState:self];
+	return YES;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
new file mode 100755
index 0000000..b12d0d5
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.h
@@ -0,0 +1,36 @@
+/*
+ Copyright (C) 2011 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamWriter.h"
+
+@interface SBJsonStreamWriterAccumulator : NSObject <SBJsonStreamWriterDelegate>
+
+@property (readonly, copy) NSMutableData* data;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
new file mode 100755
index 0000000..be65190
--- /dev/null
+++ b/sdks/other/ios/UGAPI/SBJson/SBJsonStreamWriterAccumulator.m
@@ -0,0 +1,52 @@
+/*
+ Copyright (C) 2011 Stig Brautaset. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions are met:
+ 
+ * Redistributions of source code must retain the above copyright notice, this
+   list of conditions and the following disclaimer.
+ 
+ * Redistributions in binary form must reproduce the above copyright notice,
+   this list of conditions and the following disclaimer in the documentation
+   and/or other materials provided with the distribution.
+ 
+ * Neither the name of the author nor the names of its contributors may be used
+   to endorse or promote products derived from this software without specific
+   prior written permission.
+ 
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#import "SBJsonStreamWriterAccumulator.h"
+
+
+@implementation SBJsonStreamWriterAccumulator
+
+@synthesize data;
+
+- (id)init {
+    self = [super init];
+    if (self) {
+        data = [[NSMutableData alloc] initWithCapacity:8096u];
+    }
+    return self;
+}
+
+
+#pragma mark SBJsonStreamWriterDelegate
+
+- (void)writer:(SBJsonStreamWriter *)writer appendBytes:(const void *)bytes length:(NSUInteger)length {
+    [data appendBytes:bytes length:length];
+}
+
+@end


[27/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties.xcodeproj/project.pbxproj b/sdks/other/ios/samples/parties/parties.xcodeproj/project.pbxproj
new file mode 100644
index 0000000..6bad677
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties.xcodeproj/project.pbxproj
@@ -0,0 +1,481 @@
+// !$*UTF8*$!
+{
+	archiveVersion = 1;
+	classes = {
+	};
+	objectVersion = 46;
+	objects = {
+
+/* Begin PBXBuildFile section */
+		22C1D70617357FC8006202F6 /* MapKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22C1D70517357FC8006202F6 /* MapKit.framework */; };
+		22C1D708173580ED006202F6 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22C1D707173580ED006202F6 /* CoreLocation.framework */; };
+		22CDB04A173607580015D864 /* Icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 22CDB049173607580015D864 /* Icon.png */; };
+		22FC71211730705D00153630 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71201730705D00153630 /* UIKit.framework */; };
+		22FC71231730705D00153630 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71221730705D00153630 /* Foundation.framework */; };
+		22FC71251730705D00153630 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71241730705D00153630 /* CoreGraphics.framework */; };
+		22FC712B1730705D00153630 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71291730705D00153630 /* InfoPlist.strings */; };
+		22FC712D1730705D00153630 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC712C1730705D00153630 /* main.m */; };
+		22FC71311730705D00153630 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71301730705D00153630 /* AppDelegate.m */; };
+		22FC71331730705D00153630 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71321730705D00153630 /* Default.png */; };
+		22FC71351730705D00153630 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71341730705D00153630 /* Default@2x.png */; };
+		22FC71371730705D00153630 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71361730705D00153630 /* Default-568h@2x.png */; };
+		22FC71701730709800153630 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71401730709800153630 /* NSObject+SBJson.m */; };
+		22FC71711730709800153630 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71431730709800153630 /* SBJsonParser.m */; };
+		22FC71721730709800153630 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71451730709800153630 /* SBJsonStreamParser.m */; };
+		22FC71731730709800153630 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */; };
+		22FC71741730709800153630 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */; };
+		22FC71751730709800153630 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714B1730709800153630 /* SBJsonStreamParserState.m */; };
+		22FC71761730709800153630 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714D1730709800153630 /* SBJsonStreamWriter.m */; };
+		22FC71771730709800153630 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */; };
+		22FC71781730709800153630 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71511730709800153630 /* SBJsonStreamWriterState.m */; };
+		22FC71791730709800153630 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71531730709800153630 /* SBJsonTokeniser.m */; };
+		22FC717A1730709800153630 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71551730709800153630 /* SBJsonUTF8Stream.m */; };
+		22FC717B1730709800153630 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71571730709800153630 /* SBJsonWriter.m */; };
+		22FC717C1730709800153630 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71591730709800153630 /* UGActivity.m */; };
+		22FC717D1730709800153630 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC715B1730709800153630 /* UGClient.m */; };
+		22FC717E1730709800153630 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC715E1730709800153630 /* UGClientResponse.m */; };
+		22FC717F1730709800153630 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71601730709800153630 /* UGHTTPManager.m */; };
+		22FC71801730709800153630 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71621730709800153630 /* UGMultiStepAction.m */; };
+		22FC71811730709800153630 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71641730709800153630 /* UGQuery.m */; };
+		22FC71821730709800153630 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71661730709800153630 /* UGUser.m */; };
+		22FC71831730709800153630 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71691730709800153630 /* UGConnection.m */; };
+		22FC71841730709800153630 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716B1730709800153630 /* UGHTTPClient.m */; };
+		22FC71851730709800153630 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716D1730709800153630 /* UGHTTPHelpers.m */; };
+		22FC71861730709800153630 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716F1730709800153630 /* UGHTTPResult.m */; };
+		22FC7189173070DF00153630 /* PartiesViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC7188173070DF00153630 /* PartiesViewController.m */; };
+		22FC718C173075D300153630 /* PartyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC718B173075D300153630 /* PartyViewController.m */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+		22C1D70517357FC8006202F6 /* MapKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MapKit.framework; path = System/Library/Frameworks/MapKit.framework; sourceTree = SDKROOT; };
+		22C1D707173580ED006202F6 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; };
+		22CDB049173607580015D864 /* Icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Icon.png; sourceTree = "<group>"; };
+		22FC711D1730705D00153630 /* parties.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = parties.app; sourceTree = BUILT_PRODUCTS_DIR; };
+		22FC71201730705D00153630 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+		22FC71221730705D00153630 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+		22FC71241730705D00153630 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+		22FC71281730705D00153630 /* parties-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "parties-Info.plist"; sourceTree = "<group>"; };
+		22FC712A1730705D00153630 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+		22FC712C1730705D00153630 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+		22FC712E1730705D00153630 /* parties-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "parties-Prefix.pch"; sourceTree = "<group>"; };
+		22FC712F1730705D00153630 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
+		22FC71301730705D00153630 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
+		22FC71321730705D00153630 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
+		22FC71341730705D00153630 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
+		22FC71361730705D00153630 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
+		22FC713F1730709800153630 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
+		22FC71401730709800153630 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
+		22FC71411730709800153630 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
+		22FC71421730709800153630 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
+		22FC71431730709800153630 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
+		22FC71441730709800153630 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
+		22FC71451730709800153630 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
+		22FC71461730709800153630 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
+		22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
+		22FC71481730709800153630 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
+		22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
+		22FC714A1730709800153630 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
+		22FC714B1730709800153630 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
+		22FC714C1730709800153630 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
+		22FC714D1730709800153630 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
+		22FC714E1730709800153630 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
+		22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
+		22FC71501730709800153630 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
+		22FC71511730709800153630 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
+		22FC71521730709800153630 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
+		22FC71531730709800153630 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
+		22FC71541730709800153630 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
+		22FC71551730709800153630 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
+		22FC71561730709800153630 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
+		22FC71571730709800153630 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
+		22FC71581730709800153630 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
+		22FC71591730709800153630 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
+		22FC715A1730709800153630 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
+		22FC715B1730709800153630 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
+		22FC715C1730709800153630 /* UGClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
+		22FC715D1730709800153630 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
+		22FC715E1730709800153630 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
+		22FC715F1730709800153630 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
+		22FC71601730709800153630 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
+		22FC71611730709800153630 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
+		22FC71621730709800153630 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
+		22FC71631730709800153630 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
+		22FC71641730709800153630 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
+		22FC71651730709800153630 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
+		22FC71661730709800153630 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
+		22FC71681730709800153630 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
+		22FC71691730709800153630 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
+		22FC716A1730709800153630 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
+		22FC716B1730709800153630 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
+		22FC716C1730709800153630 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
+		22FC716D1730709800153630 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
+		22FC716E1730709800153630 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
+		22FC716F1730709800153630 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
+		22FC7187173070DF00153630 /* PartiesViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PartiesViewController.h; sourceTree = "<group>"; };
+		22FC7188173070DF00153630 /* PartiesViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PartiesViewController.m; sourceTree = "<group>"; };
+		22FC718A173075D300153630 /* PartyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PartyViewController.h; sourceTree = "<group>"; };
+		22FC718B173075D300153630 /* PartyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PartyViewController.m; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+		22FC711A1730705D00153630 /* Frameworks */ = {
+			isa = PBXFrameworksBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22C1D708173580ED006202F6 /* CoreLocation.framework in Frameworks */,
+				22C1D70617357FC8006202F6 /* MapKit.framework in Frameworks */,
+				22FC71211730705D00153630 /* UIKit.framework in Frameworks */,
+				22FC71231730705D00153630 /* Foundation.framework in Frameworks */,
+				22FC71251730705D00153630 /* CoreGraphics.framework in Frameworks */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+		22FC71141730705D00153630 = {
+			isa = PBXGroup;
+			children = (
+				22C1D707173580ED006202F6 /* CoreLocation.framework */,
+				22C1D70517357FC8006202F6 /* MapKit.framework */,
+				22FC713D1730709800153630 /* UGAPI */,
+				22FC71261730705D00153630 /* parties */,
+				22FC711F1730705D00153630 /* Frameworks */,
+				22FC711E1730705D00153630 /* Products */,
+			);
+			sourceTree = "<group>";
+		};
+		22FC711E1730705D00153630 /* Products */ = {
+			isa = PBXGroup;
+			children = (
+				22FC711D1730705D00153630 /* parties.app */,
+			);
+			name = Products;
+			sourceTree = "<group>";
+		};
+		22FC711F1730705D00153630 /* Frameworks */ = {
+			isa = PBXGroup;
+			children = (
+				22FC71201730705D00153630 /* UIKit.framework */,
+				22FC71221730705D00153630 /* Foundation.framework */,
+				22FC71241730705D00153630 /* CoreGraphics.framework */,
+			);
+			name = Frameworks;
+			sourceTree = "<group>";
+		};
+		22FC71261730705D00153630 /* parties */ = {
+			isa = PBXGroup;
+			children = (
+				22FC712F1730705D00153630 /* AppDelegate.h */,
+				22FC71301730705D00153630 /* AppDelegate.m */,
+				22FC71271730705D00153630 /* Supporting Files */,
+				22FC7187173070DF00153630 /* PartiesViewController.h */,
+				22FC7188173070DF00153630 /* PartiesViewController.m */,
+				22FC718A173075D300153630 /* PartyViewController.h */,
+				22FC718B173075D300153630 /* PartyViewController.m */,
+			);
+			path = parties;
+			sourceTree = "<group>";
+		};
+		22FC71271730705D00153630 /* Supporting Files */ = {
+			isa = PBXGroup;
+			children = (
+				22CDB049173607580015D864 /* Icon.png */,
+				22FC71281730705D00153630 /* parties-Info.plist */,
+				22FC71291730705D00153630 /* InfoPlist.strings */,
+				22FC712C1730705D00153630 /* main.m */,
+				22FC712E1730705D00153630 /* parties-Prefix.pch */,
+				22FC71321730705D00153630 /* Default.png */,
+				22FC71341730705D00153630 /* Default@2x.png */,
+				22FC71361730705D00153630 /* Default-568h@2x.png */,
+			);
+			name = "Supporting Files";
+			sourceTree = "<group>";
+		};
+		22FC713D1730709800153630 /* UGAPI */ = {
+			isa = PBXGroup;
+			children = (
+				22FC713E1730709800153630 /* SBJson */,
+				22FC71581730709800153630 /* UGActivity.h */,
+				22FC71591730709800153630 /* UGActivity.m */,
+				22FC715A1730709800153630 /* UGClient.h */,
+				22FC715B1730709800153630 /* UGClient.m */,
+				22FC715C1730709800153630 /* UGClientDelegate.h */,
+				22FC715D1730709800153630 /* UGClientResponse.h */,
+				22FC715E1730709800153630 /* UGClientResponse.m */,
+				22FC715F1730709800153630 /* UGHTTPManager.h */,
+				22FC71601730709800153630 /* UGHTTPManager.m */,
+				22FC71611730709800153630 /* UGMultiStepAction.h */,
+				22FC71621730709800153630 /* UGMultiStepAction.m */,
+				22FC71631730709800153630 /* UGQuery.h */,
+				22FC71641730709800153630 /* UGQuery.m */,
+				22FC71651730709800153630 /* UGUser.h */,
+				22FC71661730709800153630 /* UGUser.m */,
+				22FC71671730709800153630 /* v2 */,
+			);
+			name = UGAPI;
+			path = ../../UGAPI;
+			sourceTree = "<group>";
+		};
+		22FC713E1730709800153630 /* SBJson */ = {
+			isa = PBXGroup;
+			children = (
+				22FC713F1730709800153630 /* NSObject+SBJson.h */,
+				22FC71401730709800153630 /* NSObject+SBJson.m */,
+				22FC71411730709800153630 /* SBJson.h */,
+				22FC71421730709800153630 /* SBJsonParser.h */,
+				22FC71431730709800153630 /* SBJsonParser.m */,
+				22FC71441730709800153630 /* SBJsonStreamParser.h */,
+				22FC71451730709800153630 /* SBJsonStreamParser.m */,
+				22FC71461730709800153630 /* SBJsonStreamParserAccumulator.h */,
+				22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */,
+				22FC71481730709800153630 /* SBJsonStreamParserAdapter.h */,
+				22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */,
+				22FC714A1730709800153630 /* SBJsonStreamParserState.h */,
+				22FC714B1730709800153630 /* SBJsonStreamParserState.m */,
+				22FC714C1730709800153630 /* SBJsonStreamWriter.h */,
+				22FC714D1730709800153630 /* SBJsonStreamWriter.m */,
+				22FC714E1730709800153630 /* SBJsonStreamWriterAccumulator.h */,
+				22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */,
+				22FC71501730709800153630 /* SBJsonStreamWriterState.h */,
+				22FC71511730709800153630 /* SBJsonStreamWriterState.m */,
+				22FC71521730709800153630 /* SBJsonTokeniser.h */,
+				22FC71531730709800153630 /* SBJsonTokeniser.m */,
+				22FC71541730709800153630 /* SBJsonUTF8Stream.h */,
+				22FC71551730709800153630 /* SBJsonUTF8Stream.m */,
+				22FC71561730709800153630 /* SBJsonWriter.h */,
+				22FC71571730709800153630 /* SBJsonWriter.m */,
+			);
+			path = SBJson;
+			sourceTree = "<group>";
+		};
+		22FC71671730709800153630 /* v2 */ = {
+			isa = PBXGroup;
+			children = (
+				22FC71681730709800153630 /* UGConnection.h */,
+				22FC71691730709800153630 /* UGConnection.m */,
+				22FC716A1730709800153630 /* UGHTTPClient.h */,
+				22FC716B1730709800153630 /* UGHTTPClient.m */,
+				22FC716C1730709800153630 /* UGHTTPHelpers.h */,
+				22FC716D1730709800153630 /* UGHTTPHelpers.m */,
+				22FC716E1730709800153630 /* UGHTTPResult.h */,
+				22FC716F1730709800153630 /* UGHTTPResult.m */,
+			);
+			path = v2;
+			sourceTree = "<group>";
+		};
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+		22FC711C1730705D00153630 /* parties */ = {
+			isa = PBXNativeTarget;
+			buildConfigurationList = 22FC713A1730705D00153630 /* Build configuration list for PBXNativeTarget "parties" */;
+			buildPhases = (
+				22FC71191730705D00153630 /* Sources */,
+				22FC711A1730705D00153630 /* Frameworks */,
+				22FC711B1730705D00153630 /* Resources */,
+			);
+			buildRules = (
+			);
+			dependencies = (
+			);
+			name = parties;
+			productName = parties;
+			productReference = 22FC711D1730705D00153630 /* parties.app */;
+			productType = "com.apple.product-type.application";
+		};
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+		22FC71151730705D00153630 /* Project object */ = {
+			isa = PBXProject;
+			attributes = {
+				LastUpgradeCheck = 0460;
+				ORGANIZATIONNAME = Apigee;
+			};
+			buildConfigurationList = 22FC71181730705D00153630 /* Build configuration list for PBXProject "parties" */;
+			compatibilityVersion = "Xcode 3.2";
+			developmentRegion = English;
+			hasScannedForEncodings = 0;
+			knownRegions = (
+				en,
+			);
+			mainGroup = 22FC71141730705D00153630;
+			productRefGroup = 22FC711E1730705D00153630 /* Products */;
+			projectDirPath = "";
+			projectRoot = "";
+			targets = (
+				22FC711C1730705D00153630 /* parties */,
+			);
+		};
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+		22FC711B1730705D00153630 /* Resources */ = {
+			isa = PBXResourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22FC712B1730705D00153630 /* InfoPlist.strings in Resources */,
+				22FC71331730705D00153630 /* Default.png in Resources */,
+				22FC71351730705D00153630 /* Default@2x.png in Resources */,
+				22FC71371730705D00153630 /* Default-568h@2x.png in Resources */,
+				22CDB04A173607580015D864 /* Icon.png in Resources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+		22FC71191730705D00153630 /* Sources */ = {
+			isa = PBXSourcesBuildPhase;
+			buildActionMask = 2147483647;
+			files = (
+				22FC712D1730705D00153630 /* main.m in Sources */,
+				22FC71311730705D00153630 /* AppDelegate.m in Sources */,
+				22FC71701730709800153630 /* NSObject+SBJson.m in Sources */,
+				22FC71711730709800153630 /* SBJsonParser.m in Sources */,
+				22FC71721730709800153630 /* SBJsonStreamParser.m in Sources */,
+				22FC71731730709800153630 /* SBJsonStreamParserAccumulator.m in Sources */,
+				22FC71741730709800153630 /* SBJsonStreamParserAdapter.m in Sources */,
+				22FC71751730709800153630 /* SBJsonStreamParserState.m in Sources */,
+				22FC71761730709800153630 /* SBJsonStreamWriter.m in Sources */,
+				22FC71771730709800153630 /* SBJsonStreamWriterAccumulator.m in Sources */,
+				22FC71781730709800153630 /* SBJsonStreamWriterState.m in Sources */,
+				22FC71791730709800153630 /* SBJsonTokeniser.m in Sources */,
+				22FC717A1730709800153630 /* SBJsonUTF8Stream.m in Sources */,
+				22FC717B1730709800153630 /* SBJsonWriter.m in Sources */,
+				22FC717C1730709800153630 /* UGActivity.m in Sources */,
+				22FC717D1730709800153630 /* UGClient.m in Sources */,
+				22FC717E1730709800153630 /* UGClientResponse.m in Sources */,
+				22FC717F1730709800153630 /* UGHTTPManager.m in Sources */,
+				22FC71801730709800153630 /* UGMultiStepAction.m in Sources */,
+				22FC71811730709800153630 /* UGQuery.m in Sources */,
+				22FC71821730709800153630 /* UGUser.m in Sources */,
+				22FC71831730709800153630 /* UGConnection.m in Sources */,
+				22FC71841730709800153630 /* UGHTTPClient.m in Sources */,
+				22FC71851730709800153630 /* UGHTTPHelpers.m in Sources */,
+				22FC71861730709800153630 /* UGHTTPResult.m in Sources */,
+				22FC7189173070DF00153630 /* PartiesViewController.m in Sources */,
+				22FC718C173075D300153630 /* PartyViewController.m in Sources */,
+			);
+			runOnlyForDeploymentPostprocessing = 0;
+		};
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+		22FC71291730705D00153630 /* InfoPlist.strings */ = {
+			isa = PBXVariantGroup;
+			children = (
+				22FC712A1730705D00153630 /* en */,
+			);
+			name = InfoPlist.strings;
+			sourceTree = "<group>";
+		};
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+		22FC71381730705D00153630 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = NO;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_DYNAMIC_NO_PIC = NO;
+				GCC_OPTIMIZATION_LEVEL = 0;
+				GCC_PREPROCESSOR_DEFINITIONS = (
+					"DEBUG=1",
+					"$(inherited)",
+				);
+				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				ONLY_ACTIVE_ARCH = YES;
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+			};
+			name = Debug;
+		};
+		22FC71391730705D00153630 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				ALWAYS_SEARCH_USER_PATHS = NO;
+				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+				CLANG_CXX_LIBRARY = "libc++";
+				CLANG_ENABLE_OBJC_ARC = YES;
+				CLANG_WARN_CONSTANT_CONVERSION = YES;
+				CLANG_WARN_EMPTY_BODY = YES;
+				CLANG_WARN_ENUM_CONVERSION = YES;
+				CLANG_WARN_INT_CONVERSION = YES;
+				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+				COPY_PHASE_STRIP = YES;
+				GCC_C_LANGUAGE_STANDARD = gnu99;
+				GCC_WARN_ABOUT_RETURN_TYPE = YES;
+				GCC_WARN_UNINITIALIZED_AUTOS = YES;
+				GCC_WARN_UNUSED_VARIABLE = YES;
+				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+				SDKROOT = iphoneos;
+				TARGETED_DEVICE_FAMILY = "1,2";
+				VALIDATE_PRODUCT = YES;
+			};
+			name = Release;
+		};
+		22FC713B1730705D00153630 /* Debug */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "parties/parties-Prefix.pch";
+				INFOPLIST_FILE = "parties/parties-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Debug;
+		};
+		22FC713C1730705D00153630 /* Release */ = {
+			isa = XCBuildConfiguration;
+			buildSettings = {
+				GCC_PRECOMPILE_PREFIX_HEADER = YES;
+				GCC_PREFIX_HEADER = "parties/parties-Prefix.pch";
+				INFOPLIST_FILE = "parties/parties-Info.plist";
+				PRODUCT_NAME = "$(TARGET_NAME)";
+				WRAPPER_EXTENSION = app;
+			};
+			name = Release;
+		};
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+		22FC71181730705D00153630 /* Build configuration list for PBXProject "parties" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				22FC71381730705D00153630 /* Debug */,
+				22FC71391730705D00153630 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+		22FC713A1730705D00153630 /* Build configuration list for PBXNativeTarget "parties" */ = {
+			isa = XCConfigurationList;
+			buildConfigurations = (
+				22FC713B1730705D00153630 /* Debug */,
+				22FC713C1730705D00153630 /* Release */,
+			);
+			defaultConfigurationIsVisible = 0;
+			defaultConfigurationName = Release;
+		};
+/* End XCConfigurationList section */
+	};
+	rootObject = 22FC71151730705D00153630 /* Project object */;
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/AppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/AppDelegate.h b/sdks/other/ios/samples/parties/parties/AppDelegate.h
new file mode 100644
index 0000000..1bc8193
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/AppDelegate.h
@@ -0,0 +1,26 @@
+//
+//  AppDelegate.h
+//  parties
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface AppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/AppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/AppDelegate.m b/sdks/other/ios/samples/parties/parties/AppDelegate.m
new file mode 100644
index 0000000..0e9103c
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/AppDelegate.m
@@ -0,0 +1,73 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  AppDelegate.m
+//  parties
+//
+//  Copyright (c) 2013 Apigee. All rights reserved.
+//
+
+#import "AppDelegate.h"
+#import "PartiesViewController.h"
+
+@implementation AppDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
+    UINavigationController *navigationController = [[UINavigationController alloc]
+                                                    initWithRootViewController:[[PartiesViewController alloc] init]];
+    navigationController.navigationBar.tintColor = [UIColor colorWithRed:255.0/255.0
+                                                                   green:067.0/255.0
+                                                                    blue:000.0/255.0
+                                                                   alpha:1];
+    self.window.rootViewController = navigationController;
+    self.window.backgroundColor = [UIColor whiteColor];
+    [self.window makeKeyAndVisible];
+
+    return YES;
+}
+
+- (void)applicationWillResignActive:(UIApplication *)application
+{
+    // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
+    // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
+}
+
+- (void)applicationDidEnterBackground:(UIApplication *)application
+{
+    // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 
+    // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
+}
+
+- (void)applicationWillEnterForeground:(UIApplication *)application
+{
+    // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
+}
+
+- (void)applicationDidBecomeActive:(UIApplication *)application
+{
+    // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
+}
+
+- (void)applicationWillTerminate:(UIApplication *)application
+{
+    // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/Default-568h@2x.png b/sdks/other/ios/samples/parties/parties/Default-568h@2x.png
new file mode 100644
index 0000000..0891b7a
Binary files /dev/null and b/sdks/other/ios/samples/parties/parties/Default-568h@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/Default.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/Default.png b/sdks/other/ios/samples/parties/parties/Default.png
new file mode 100644
index 0000000..4c8ca6f
Binary files /dev/null and b/sdks/other/ios/samples/parties/parties/Default.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/Default@2x.png b/sdks/other/ios/samples/parties/parties/Default@2x.png
new file mode 100644
index 0000000..35b84cf
Binary files /dev/null and b/sdks/other/ios/samples/parties/parties/Default@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/Icon.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/Icon.png b/sdks/other/ios/samples/parties/parties/Icon.png
new file mode 100644
index 0000000..ec8b407
Binary files /dev/null and b/sdks/other/ios/samples/parties/parties/Icon.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/PartiesViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/PartiesViewController.h b/sdks/other/ios/samples/parties/parties/PartiesViewController.h
new file mode 100644
index 0000000..2231ca1
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/PartiesViewController.h
@@ -0,0 +1,24 @@
+//
+//  PartiesViewController.h
+//  parties
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface PartiesViewController : UITableViewController
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/PartiesViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/PartiesViewController.m b/sdks/other/ios/samples/parties/parties/PartiesViewController.m
new file mode 100644
index 0000000..5abb2f5
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/PartiesViewController.m
@@ -0,0 +1,241 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  PartiesViewController.m
+//  parties
+//
+//  Copyright (c) 2013 Apigee. All rights reserved.
+//
+
+#import "PartiesViewController.h"
+#import "PartyViewController.h"
+
+#import "UGConnection.h"
+#import "UGHTTPClient.h"
+#import "UGHTTPResult.h"
+
+@interface PartiesViewController ()
+@property (nonatomic, strong) NSDictionary *content;
+@property (nonatomic, strong) NSArray *partiesByStartDate;
+@property (nonatomic, strong) NSMutableDictionary *images;
+@end
+
+@implementation PartiesViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+    self = [super initWithStyle:style];
+    if (self) {
+        self.images = [NSMutableDictionary dictionary];
+    }
+    return self;
+}
+
+- (void) setContent:(NSDictionary *)content
+{
+    _content = content;
+    
+    NSMutableDictionary *partiesByStartDateDictionary = [NSMutableDictionary dictionary];
+    for (NSDictionary *party in self.content[@"entities"]) {
+        NSString *startDate = [party objectForKey:@"startDate"];
+        NSArray *parts = [startDate componentsSeparatedByString:@" "];
+        NSString *datePart = [parts objectAtIndex:0];
+        NSMutableArray *arrayOfParties = [partiesByStartDateDictionary objectForKey:datePart];
+        if (!arrayOfParties) {
+            arrayOfParties = [NSMutableArray array];
+            [partiesByStartDateDictionary setObject:arrayOfParties forKey:datePart];
+        }
+        [arrayOfParties addObject:party];
+    }
+    NSArray *keys = [[partiesByStartDateDictionary allKeys] sortedArrayUsingComparator:^NSComparisonResult(id obj1, id obj2) {
+        return [obj1 compare:obj2];
+    }];
+    NSMutableArray *partiesByStartDate = [NSMutableArray array];
+    for (NSString *key in keys) {
+        [partiesByStartDate addObject:
+         @{@"date":key,
+         @"parties":[partiesByStartDateDictionary objectForKey:key]}];
+    }
+    self.partiesByStartDate = partiesByStartDate;
+    // NSLog(@"%@", self.partiesByStartDate);
+}
+
+- (void) fetchAssetForParty:(NSString *) partyName atIndexPath:(NSIndexPath *) indexPath
+{
+    UGConnection *connection = [UGConnection sharedConnection];
+    if ([connection isAuthenticated]) {
+        NSDictionary *query = [connection queryWithString:
+                               [NSString stringWithFormat:@"select * where path='/assets/%@'", partyName]
+                                                    limit:1
+                                                startUUID:nil
+                                                   cursor:nil
+                                                 reversed:NO];
+        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
+                                [connection getEntitiesInCollection:@"assets"
+                                                         usingQuery:query]];
+        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
+            id entities = [result.object objectForKey:@"entities"];
+            if ([entities count]) {
+                id entity = [entities objectAtIndex:0];
+                NSString *uuid = [entity objectForKey:@"uuid"];
+                UGHTTPClient *assetclient = [[UGHTTPClient alloc] initWithRequest:
+                                             [connection getDataForAsset:uuid]];
+                [assetclient connectWithCompletionHandler:^(UGHTTPResult *result) {
+                    UIImage *image = [UIImage imageWithData:result.data];
+                    [self.images setObject:image forKey:partyName];
+                    [self.tableView reloadRowsAtIndexPaths:[NSArray arrayWithObject:indexPath]
+                                          withRowAnimation:UITableViewRowAnimationNone];
+                }];
+            }
+        }];
+    }
+}
+
+- (void) reload {
+    UGConnection *connection = [UGConnection sharedConnection];
+    if ([connection isAuthenticated]) {
+        NSDictionary *query = [connection queryWithString:@"select * where conference = 'wwdc2013'"
+                                                    limit:1000
+                                                startUUID:nil
+                                                   cursor:nil
+                                                 reversed:NO];
+        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
+                                [connection getEntitiesInCollection:@"parties"
+                                                         usingQuery:query]];
+        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
+            self.content = result.object;
+            NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
+            [defaults setObject:result.object forKey:@"parties"];
+            [defaults synchronize];
+            [self.tableView reloadData];
+        }];
+    }
+}
+
+- (void) authenticate {
+    UGConnection *connection = [UGConnection sharedConnection];
+    if (![connection isAuthenticated]) {
+        [[[UGHTTPClient alloc] initWithRequest:
+          [connection getAccessTokenForApplicationWithUsername:@"radtastical"
+                                                      password:@"partyrock2013"]]
+         connectWithCompletionHandler:^(UGHTTPResult *result) {
+             [connection authenticateWithResult:result];
+             if ([connection isAuthenticated]) {
+                 if (self.content) {
+                     // trigger photo loads
+                     [self.tableView reloadData];
+                 } else {
+                     // load all party information
+                     [self reload];
+                 }
+             }
+         }];
+    }
+}
+
+- (void)loadView
+{
+    [super loadView];
+    self.navigationItem.title = @"Parties";
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithBarButtonSystemItem:UIBarButtonSystemItemRefresh
+                                             target:self
+                                             action:@selector(reload)];
+    self.tableView.rowHeight = 100;
+    
+    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
+    NSDictionary *parties = [defaults objectForKey:@"parties"];
+    if (parties) {
+        self.content = parties;
+    }
+    UGConnection *connection = [UGConnection sharedConnection];
+    connection.server = @"https://api.usergrid.com";
+    connection.organization = @"macmoe";
+    connection.application = @"partyapi";
+    [self authenticate];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return [self.partiesByStartDate count];
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    if (self.content) {
+        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:section];
+        NSArray *parties = [sectionInfo objectForKey:@"parties"];
+        return [parties count];
+    } else {
+        return 0;
+    }
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    return [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
+}
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (self.content) {
+        
+        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:[indexPath section]];
+        NSArray *parties = [sectionInfo objectForKey:@"parties"];
+        
+        id entity = parties[[indexPath row]];
+        cell.textLabel.text = entity[@"title"];
+        cell.textLabel.numberOfLines = 0;
+        cell.detailTextLabel.text = [NSString stringWithFormat:@"%@ %@", entity[@"venue"], entity[@"partytime"]];
+        cell.detailTextLabel.numberOfLines = 0;
+        
+        NSString *partyName = [entity objectForKey:@"name"];
+        UIImage *image = [self.images objectForKey:partyName];
+        if (image) {
+            cell.imageView.image = image;
+        } else {
+            cell.imageView.image = nil;
+            [self fetchAssetForParty:[entity objectForKey:@"name"] atIndexPath:indexPath];
+        }
+    }
+    cell.selectionStyle = UITableViewCellSelectionStyleNone;
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (self.content) {
+        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:[indexPath section]];
+        NSArray *parties = [sectionInfo objectForKey:@"parties"];
+        id entity = [parties objectAtIndex:[indexPath row]];
+        PartyViewController *partyViewController = [[PartyViewController alloc] init];
+        partyViewController.content = entity;
+        [self.navigationController pushViewController:partyViewController animated:YES];
+    }
+}
+
+- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
+{
+    NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:section];
+    return [sectionInfo objectForKey:@"date"];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/PartyViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/PartyViewController.h b/sdks/other/ios/samples/parties/parties/PartyViewController.h
new file mode 100644
index 0000000..100c4c9
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/PartyViewController.h
@@ -0,0 +1,24 @@
+//
+//  PartyViewController.h
+//  parties
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+#import <UIKit/UIKit.h>
+
+@interface PartyViewController : UITableViewController
+@property (nonatomic, strong) NSDictionary *content;
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/PartyViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/PartyViewController.m b/sdks/other/ios/samples/parties/parties/PartyViewController.m
new file mode 100644
index 0000000..dfedfce
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/PartyViewController.m
@@ -0,0 +1,166 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  PartyViewController.m
+//  parties
+//
+//  Copyright (c) 2013 Apigee. All rights reserved.
+//
+
+#import "PartyViewController.h"
+
+@interface PartyViewController ()
+
+@property (nonatomic, strong) UITableViewCell *mapCell;
+
+@end
+
+@implementation PartyViewController
+
+- (void)didReceiveMemoryWarning
+{
+    [super didReceiveMemoryWarning];
+}
+
+- (void) viewWillAppear:(BOOL)animated
+{
+    self.navigationItem.title = [self.content objectForKey:@"title"];
+}
+
+UIFont *font_with_size(CGFloat size) {
+    return [UIFont fontWithName:@"Helvetica-Bold" size:size];
+}
+
+NSAttributedString *carriage_return(CGFloat size) {
+    return [[NSAttributedString alloc] initWithString:[NSString stringWithFormat:@"\n"]
+                                           attributes:@{NSFontAttributeName:font_with_size(size)}];
+}
+
+NSMutableAttributedString *attributed_string(NSString *string, CGFloat size) {
+    return [[NSMutableAttributedString alloc] initWithString:string
+                                                  attributes:@{NSFontAttributeName:font_with_size(size)}];
+}
+
+- (NSMutableAttributedString *) attributedStringForIndexPath:(NSIndexPath *) indexPath
+{
+    if (([indexPath section] == 0) && ([indexPath row] == 1)) {
+        NSMutableAttributedString *attributedString = attributed_string([self.content objectForKey:@"title"], 30);
+        [attributedString appendAttributedString:carriage_return(18)];
+        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"venue"], 24)];
+        [attributedString appendAttributedString:carriage_return(24)];
+        
+        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"startDate"], 18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        
+        id address = [self.content objectForKey:@"address"];
+        [attributedString appendAttributedString:attributed_string([address objectForKey:@"street"], 18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        [attributedString appendAttributedString:attributed_string([address objectForKey:@"city"], 18)];
+        [attributedString appendAttributedString:attributed_string(@", ", 18)];
+        [attributedString appendAttributedString:attributed_string([address objectForKey:@"state"], 18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        
+        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"description"], 18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        [attributedString appendAttributedString:carriage_return(18)];
+        
+        return attributedString;
+    } else if (([indexPath section] == 1) && ([indexPath row] == 0)) {
+        NSMutableAttributedString *attributedString = attributed_string([self.content description], 12);
+        [attributedString appendAttributedString:carriage_return(12)];
+        return attributedString;
+    } else {
+        return nil;
+    }
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 2;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return (section == 0) ? 2 : 1;
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (([indexPath section] == 0) && ([indexPath row] == 0)) {
+        if (!self.mapCell) {
+            self.mapCell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Map"];
+            MKMapView *mapView = [[MKMapView alloc] initWithFrame:self.mapCell.bounds];
+            mapView.autoresizingMask = UIViewAutoresizingFlexibleWidth + UIViewAutoresizingFlexibleHeight;
+            [self.mapCell addSubview:mapView];
+            id location = [self.content objectForKey:@"location"];
+            double lat = [[location objectForKey:@"latitude"] floatValue];
+            double lng = [[location objectForKey:@"longitude"] floatValue];
+            [mapView setRegion:MKCoordinateRegionMake(CLLocationCoordinate2DMake(lat,lng),
+                                                      MKCoordinateSpanMake(0.002,0.002))];
+            CLLocationCoordinate2D annotationCoord;
+            annotationCoord.latitude = lat;
+            annotationCoord.longitude = lng;
+            MKPointAnnotation *annotationPoint = [[MKPointAnnotation alloc] init];
+            annotationPoint.coordinate = annotationCoord;
+            annotationPoint.title = [self.content objectForKey:@"title"];
+            annotationPoint.subtitle = [self.content objectForKey:@"venue"];
+            [mapView addAnnotation:annotationPoint];
+            mapView.scrollEnabled = NO;
+            mapView.zoomEnabled = NO;
+        }
+        return self.mapCell;
+    } else {
+        UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault
+                                                       reuseIdentifier:@"Cell"];
+        cell.selectionStyle = UITableViewCellSelectionStyleNone;
+        cell.textLabel.attributedText = [self attributedStringForIndexPath:indexPath];
+        cell.textLabel.numberOfLines = 0;
+        return cell;
+    }
+}
+
+- (CGFloat) tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    if (([indexPath section] == 0) && ([indexPath row] == 0)) {
+        return 200;
+    } else {
+        CGFloat w = tableView.bounds.size.width - 20; // use approximate margins
+        CGFloat h = 0;
+        NSMutableAttributedString *attributedString = [self attributedStringForIndexPath:indexPath];
+        CGRect bounds = [attributedString boundingRectWithSize:CGSizeMake(w,h)
+                                                       options:NSStringDrawingUsesFontLeading+NSStringDrawingUsesLineFragmentOrigin
+                                                       context:nil];
+        return bounds.size.height;
+    }
+}
+
+- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
+{
+    if (section == 0) {
+        return nil;
+    } else if (section == 1) {
+        return @"Party Entity Details";
+    }
+    return nil;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/en.lproj/InfoPlist.strings b/sdks/other/ios/samples/parties/parties/en.lproj/InfoPlist.strings
new file mode 100644
index 0000000..477b28f
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/en.lproj/InfoPlist.strings
@@ -0,0 +1,2 @@
+/* Localized versions of Info.plist keys */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/main.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/main.m b/sdks/other/ios/samples/parties/parties/main.m
new file mode 100644
index 0000000..516a18a
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/main.m
@@ -0,0 +1,35 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  main.m
+//  parties
+//
+//  Created by Tim Burks on 4/30/13.
+//  Copyright (c) 2013 Apigee. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+#import "AppDelegate.h"
+
+int main(int argc, char *argv[])
+{
+    @autoreleasepool {
+        return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
+    }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/parties-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/parties-Info.plist b/sdks/other/ios/samples/parties/parties/parties-Info.plist
new file mode 100644
index 0000000..f394f12
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/parties-Info.plist
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+-->
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/parties/parties/parties-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/parties/parties/parties-Prefix.pch b/sdks/other/ios/samples/parties/parties/parties-Prefix.pch
new file mode 100644
index 0000000..96b4d23
--- /dev/null
+++ b/sdks/other/ios/samples/parties/parties/parties-Prefix.pch
@@ -0,0 +1,15 @@
+//
+// Prefix header for all source files of the 'parties' target in the 'parties' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_3_0
+#warning "This project uses features only available in iOS SDK 3.0 and later."
+#endif
+
+#ifdef __OBJC__
+    #import <UIKit/UIKit.h>
+    #import <Foundation/Foundation.h>
+    #import <MapKit/MapKit.h>
+#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/test/test_client.nu
----------------------------------------------------------------------
diff --git a/sdks/other/ios/test/test_client.nu b/sdks/other/ios/test/test_client.nu
new file mode 100644
index 0000000..96fbd85
--- /dev/null
+++ b/sdks/other/ios/test/test_client.nu
@@ -0,0 +1,50 @@
+;;
+;; Licensed to the Apache Software Foundation (ASF) under one or more
+;; contributor license agreements.  See the NOTICE file distributed with
+;; this work for additional information regarding copyright ownership.
+;; The ASF licenses this file to You under the Apache License, Version 2.0
+;; (the "License"); you may not use this file except in compliance with
+;; the License.  You may obtain a copy of the License at
+;;
+;;     http://www.apache.org/licenses/LICENSE-2.0
+;;
+;; Unless required by applicable law or agreed to in writing, software
+;; distributed under the License is distributed on an "AS IS" BASIS,
+;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+;; See the License for the specific language governing permissions and
+;; limitations under the License.
+;;
+
+;; test_client.nu
+;;  Simple tests for Usergrid Client class.
+;;
+(load "Usergrid")
+
+(class TestClient is NuTestCase
+ 
+ (- testClientSigninAndGetUsers is
+    ;; create a client
+    (set client ((UGClient alloc) initWithOrganizationId:"1hotrod" withApplicationID:"fred"))
+    ;; sign in a test user
+    (set response (client logInUser:"alice" password:"test1test"))
+    (assert_equal 0 (response transactionState))
+    (set object ((response rawResponse) JSONValue))
+    (assert_true (object access_token:))
+    (assert_true (object expires_in:))
+    (set user (object user:))
+    (assert_true (user activated:))
+    (assert_equal "alice" (user name:))
+    (assert_equal "test1test" (user validate-password:))
+    ;; query for users
+    (set query (UGQuery new))
+    (set response (client getUsers:query))
+    (assert_equal 0 (response transactionState))
+    (set object ((response rawResponse) JSONValue))
+    (assert_equal "fred" (object applicationName:))
+    (assert_equal "get" (object action:))
+    (set entities (object entities:))
+    (assert_equal (object count:) (entities count)))
+
+ (- testSemVerOfClient is
+    ;; create a client
+    (assert_equal "0.1.1" (UGClient version))))

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/test/test_connection.nu
----------------------------------------------------------------------
diff --git a/sdks/other/ios/test/test_connection.nu b/sdks/other/ios/test/test_connection.nu
new file mode 100644
index 0000000..3d0e2e5
--- /dev/null
+++ b/sdks/other/ios/test/test_connection.nu
@@ -0,0 +1,119 @@
+;;
+;; Licensed to the Apache Software Foundation (ASF) under one or more
+;; contributor license agreements.  See the NOTICE file distributed with
+;; this work for additional information regarding copyright ownership.
+;; The ASF licenses this file to You under the Apache License, Version 2.0
+;; (the "License"); you may not use this file except in compliance with
+;; the License.  You may obtain a copy of the License at
+;;
+;;     http://www.apache.org/licenses/LICENSE-2.0
+;;
+;; Unless required by applicable law or agreed to in writing, software
+;; distributed under the License is distributed on an "AS IS" BASIS,
+;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+;; See the License for the specific language governing permissions and
+;; limitations under the License.
+;;
+
+;; test_connection.nu
+;;  Simple tests for Usergrid Connection class.
+;;
+(load "Usergrid")
+
+(set ORGANIZATION     "timburks")
+(set APPLICATION      "unittest")
+(set APPLICATION_UUID "6a87cc36-a328-11e2-836c-02e81af253c0")
+(set CLIENT_ID        "YXA6aofMNqMoEeKDbALoGvJTwA")
+(set CLIENT_SECRET    "YXA6oEdSD8zQyKxBKv_3xxZgvISM8C4")
+
+(function perform (request)
+          (set client ((UGHTTPClient alloc) initWithRequest:request))
+          (set result (client connect))
+          result)
+
+(class TestConnection is NuTestCase
+ ;; run this before every test
+ (- setup is
+    (set usergrid (UGConnection sharedConnection))
+    (usergrid setOrganization:ORGANIZATION)
+    (usergrid setApplication:APPLICATION))
+ 
+ (- testClientSignin is
+    (set usergrid (UGConnection sharedConnection))
+    ;; log in
+    (set request (usergrid getAccessTokenForApplicationWithClientID:CLIENT_ID
+                                                       clientSecret:CLIENT_SECRET))
+    (set result (perform request))
+    (set object (result object))
+    (assert_true (object access_token:))
+    ;; capture token
+    (usergrid authenticateWithResult:result)
+    (assert_true (usergrid isAuthenticated)))
+ 
+ (- testUserSignin is
+    (set usergrid (UGConnection sharedConnection))
+    ;; log in
+    (set request (usergrid getAccessTokenForApplicationWithUsername:"test1"
+                                                           password:"test1"))
+    (set result (perform request))
+    (set object (result object))
+    (assert_true (object access_token:))
+    ;; capture token
+    (usergrid authenticateWithResult:result)
+    (assert_true (usergrid isAuthenticated)))
+ 
+ (- testApplicationDetail is
+    (set usergrid (UGConnection sharedConnection))
+    ;; log in
+    (set request (usergrid getAccessTokenForApplicationWithUsername:"test2"
+                                                           password:"test2"))
+    (set result (perform request))
+    (usergrid authenticateWithResult:result)
+    ;; get application description
+    (set request (usergrid getApplication:APPLICATION inOrganization:ORGANIZATION))
+    (set result (perform request))
+    (set object (result object))
+    (assert_equal APPLICATION (object applicationName:))
+    (assert_equal ORGANIZATION (object organization:))
+    (assert_equal 1 ((object entities:) count))
+    (set collections ((((object entities:) 0) metadata:) collections:))
+    (assert_equal 8 (collections count)))
+ 
+ (- testAssets is
+    (set usergrid (UGConnection sharedConnection))
+    ;; log in
+    (usergrid authenticateWithResult:(perform (usergrid getAccessTokenForApplicationWithUsername:"test1" password:"test1")))
+    
+    ;; delete all assets
+    (perform (usergrid deleteEntitiesInCollection:"assets"))
+    (set results (perform (usergrid getEntitiesInCollection:"assets" limit:10)))
+    (set object (results object))
+    (assert_equal 0 (object count:))
+    
+    ;; add some assets
+    (set N 2)
+    (N times:
+       (do (i)
+           (set results (perform (usergrid createEntityInCollection:"assets" withValues:(dict name:"asset-#{i}"
+                                                                                            number:i
+                                                                                             owner:APPLICATION_UUID
+                                                                                              path:"asset-#{i}"))))
+           (set object (results object))
+           (set uuid (((object entities:) 0) uuid:))
+           (set results (perform (usergrid postData:("asset-#{i}" dataUsingEncoding:NSUTF8StringEncoding)
+                                           forAsset:uuid)))))
+    (set results (perform (usergrid getEntitiesInCollection:"assets" limit:10)))
+    (set object (results object))
+    (assert_equal N (object count:))
+    ((object entities:) eachWithIndex:
+     (do (asset i)
+         (set uuid (asset uuid:))
+         (set results (perform (usergrid getDataForAsset:uuid)))
+         (set asset-string (NSString stringWithData:(results data) encoding:NSUTF8StringEncoding))
+         (assert_equal i (asset number:))
+         (assert_equal (asset owner:) APPLICATION_UUID)
+         (assert_equal (asset path:) asset-string)
+         (assert_equal (asset name:) asset-string)))))
+
+
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/Build.PL
----------------------------------------------------------------------
diff --git a/sdks/other/perl/Build.PL b/sdks/other/perl/Build.PL
new file mode 100644
index 0000000..71bcf10
--- /dev/null
+++ b/sdks/other/perl/Build.PL
@@ -0,0 +1,46 @@
+
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+use 5.006;
+use strict;
+use warnings FATAL => 'all';
+use Module::Build;
+
+my $builder = Module::Build->new(
+    module_name         => 'Usergrid::Client',
+    license             => 'Apache_2_0',
+    abstract            => 'Client API for Apache Usergrid',
+    dist_author         => 'Anuradha Weeraman <an...@cpan.org>',
+    dist_version_from   => 'lib/Usergrid/Client.pm',
+    release_status      => 'stable',
+    configure_requires  => {
+        'Module::Build' => 0,
+    },
+    build_requires => {
+        'Test::More'    => 0,
+    },
+    requires => {
+        'Moose'                => 0,
+        'JSON'                 => 0,
+        'REST::Client'         => 0,
+        'URI::Template'        => 0,
+        'Log::Log4perl'        => 0,
+        'namespace::autoclean' => 0
+    },
+    add_to_cleanup      => [ 'Usergrid-Client-*' ]
+);
+
+$builder->create_build_script();

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/other/perl/LICENSE b/sdks/other/perl/LICENSE
new file mode 100644
index 0000000..e06d208
--- /dev/null
+++ b/sdks/other/perl/LICENSE
@@ -0,0 +1,202 @@
+Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "{}"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright {yyyy} {name of copyright owner}
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/perl/MANIFEST
----------------------------------------------------------------------
diff --git a/sdks/other/perl/MANIFEST b/sdks/other/perl/MANIFEST
new file mode 100644
index 0000000..4169300
--- /dev/null
+++ b/sdks/other/perl/MANIFEST
@@ -0,0 +1,23 @@
+.travis.yml
+Build.PL
+examples/books.pl
+lib/Usergrid/Client.pm
+lib/Usergrid/Collection.pm
+lib/Usergrid/Entity.pm
+lib/Usergrid/Request.pm
+LICENSE
+Makefile.PL
+MANIFEST			This list of files
+META.json
+META.yml
+README.md
+t/01_init.t
+t/02_login.t
+t/03_update.t
+t/04_collection.t
+t/05_query.t
+t/06_batch_update.t
+t/07_batch_delete.t
+t/08_connections.t
+t/09_paging.t
+t/10_auto_paging.t


[41/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGConnection.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGConnection.h b/sdks/ios/UGAPI/v2/UGConnection.h
deleted file mode 100644
index d44c8e9..0000000
--- a/sdks/ios/UGAPI/v2/UGConnection.h
+++ /dev/null
@@ -1,289 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-//
-//  UGConnection.h
-//  UGAPIApp
-//
-//  Created by Tim Burks on 3/30/13.
-//
-//
-#import <Foundation/Foundation.h>
-
-@class UGHTTPResult;
-
-@interface UGConnection : NSObject
-
-// These three properties tie a  UGConnection to a specific application instance
-@property (nonatomic, strong) NSString *server;
-@property (nonatomic, strong) NSString *organization;
-@property (nonatomic, strong) NSString *application;
-
-// As a convenience, a sharedConnection object is available,
-// but any number of UGConnection objects may be created and separately configured.
-+ (UGConnection *) sharedConnection;
-
-// Query helper: construct query dictionary from arguments
-- (NSMutableDictionary *) queryWithString:(NSString *) queryString
-                                    limit:(int) limit
-                                startUUID:(NSString *) startUUID
-                                   cursor:(NSString *) cursor
-                                 reversed:(BOOL) reversed;
-
-// Authentication helper: call this method with the result of a getAccessToken request.
-- (BOOL) authenticateWithResult:(UGHTTPResult *) result;
-
-// Authentication helper: use this to confirm that a connection has a usable access token.
-- (BOOL) isAuthenticated;
-
-//
-// Usergrid API methods
-//
-// The following calls return NSMutableURLRequest objects that can be used to make Usergrid API calls.
-// We recommend (but do not require) that they be made with instances of the UGHTTPClient class.
-//
-// The goal here is to directly expose the complete Usergrid API.
-//
-// This follows http://apigee.com/docs/usergrid/content/app-services-resources
-//
-
-// Access tokens http://apigee.com/docs/usergrid/content/accesstoken
-
-- (NSMutableURLRequest *) getAccessTokenForAdminWithUsername:(NSString *) username
-                                                    password:(NSString *) password;
-
-- (NSMutableURLRequest *) getAccessTokenForOrganizationWithClientID:(NSString *) clientID
-                                                       clientSecret:(NSString *) clientSecret;
-
-- (NSMutableURLRequest *) getAccessTokenForApplicationWithUsername:(NSString *) username
-                                                          password:(NSString *) password;
-
-- (NSMutableURLRequest *) getAccessTokenForApplicationWithClientID:(NSString *) clientID
-                                                      clientSecret:(NSString *) clientSecret;
-
-// Admin users http://apigee.com/docs/usergrid/content/admin-user
-
-- (NSMutableURLRequest *) createAdminUserWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) updateAdminUser:(NSString *) adminUserIdentifier
-                               withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) getAdminUser:(NSString *) adminUserIdentifier;
-
-- (NSMutableURLRequest *) setPasswordForAdminUser:(NSString *) adminUserIdentifier
-                                          toValue:(NSString *) password;
-
-- (NSMutableURLRequest *) initiatePasswordResetForAdminUser;
-
-- (NSMutableURLRequest *) completePasswordResetForAdminUserWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) activateAdminUser:(NSString *) adminUserIdentifier
-                                  withToken:(NSString *) token
-                   sendingConfirmationEmail:(BOOL) sendingConfirmationEmail;
-
-- (NSMutableURLRequest *) reactivateAdminUser:(NSString *) adminUserIdentifier;
-
-- (NSMutableURLRequest *) getActivityFeedForAdminUser:(NSString *) adminUserIdentifier;
-
-// Client authorization http://apigee.com/docs/usergrid/content/client-authorization
-
-- (NSMutableURLRequest *) authorizeClient:(NSString *) clientIdentifier withResponseType:(NSString *) responseType;
-
-// Organizations and Applications http://apigee.com/docs/usergrid/content/organization
-
-- (NSMutableURLRequest *) createOrganizationWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) getOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) activateOrganization:(NSString *) organizationIdentifier
-                                     withToken:(NSString *) token
-                      sendingConfirmationEmail:(BOOL) sendingConfirmationEmail;
-
-- (NSMutableURLRequest *) reactivateOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) generateClientCredentialsForOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getClientCredentialsForOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getActivityFeedForOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) createApplicationInOrganization:(NSString *) organizationIdentifier
-                                               withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deleteApplication:(NSString *) applicationIdentifier
-                             inOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) generateClientCredentialsForApplication:(NSString *) applicationIdentifier
-                                                   inOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getClientCredentialsForApplication:(NSString *) applicationIdentifier
-                                              inOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getApplicationsInOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) addAdminUser:(NSString *) adminUserIdentifier
-                        toOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getAdminUsersInOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) removeAdminUser:(NSString *) adminUserIdentifier
-                         fromOrganization:(NSString *) organizationIdentifier;
-
-- (NSMutableURLRequest *) getApplication:(NSString *) applicationIdentifier
-                          inOrganization:(NSString *) organizationIdentifier;
-
-// Activity http://apigee.com/docs/usergrid/content/activity
-
-- (NSMutableURLRequest *) createActivityForUser:(NSString *) userIdentifier
-                                     withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) createActivityForGroup:(NSString *) groupIdentifier
-                                      withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) createActivityForFollowersOfUser:(NSString *) userIdentifier
-                                                   inGroup:(NSString *) groupIdentifier
-                                                withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) getActivitiesForUser:(NSString *) userIdentifier;
-
-- (NSMutableURLRequest *) getActivitiesForGroup:(NSString *) groupIdentifier;
-
-- (NSMutableURLRequest *) getActivityFeedForUser:(NSString *) userIdentifier;
-
-- (NSMutableURLRequest *) getActivityFeedForGroup:(NSString *) groupIdentifier;
-
-// Assets
-
-- (NSMutableURLRequest *) getDataForAsset:(NSString *) assetIdentifier;
-
-- (NSMutableURLRequest *) postData:(NSData *) data
-                          forAsset:(NSString *) assetIdentifier;
-
-// Collections (aka General-purpose endpoints) http://apigee.com/docs/usergrid/content/general-purpose-endpoints
-
-- (NSMutableURLRequest *) createEntityInCollection:(NSString *) collection
-                                        withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) getEntity:(NSString *) entityIdentifier
-                       inCollection:(NSString *) collection;
-
-- (NSMutableURLRequest *) updateEntity:(NSString *) entityIdentifier
-                          inCollection:(NSString *) collection
-                            withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deleteEntity:(NSString *) entityIdentifier
-                          inCollection:(NSString *) collection;
-
-- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
-                                            limit:(int) limit;
-
-- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
-                                       usingQuery:(NSDictionary *) query;
-
-- (NSMutableURLRequest *) updateEntitiesInCollection:(NSString *) collection
-                                          usingQuery:(NSDictionary *) query
-                                          withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection;
-
-- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
-                                          usingQuery:(NSDictionary *) query;
-
-
-// Devices http://apigee.com/docs/usergrid/content/device
-
-// there are no device-specific methods
-
-// Events and Counters http://apigee.com/docs/usergrid/content/events-and-counters
-
-- (NSMutableURLRequest *) createEventWithValues:(NSDictionary *) values;
-
-// Groups http://apigee.com/docs/usergrid/content/group
-
-- (NSMutableURLRequest *) createGroupWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) addUser:(NSString *) userIdentifier
-                          toGroup:(NSString *) groupIdentifier;
-
-- (NSMutableURLRequest *) getGroup:(NSString *) groupIdentifier;
-
-- (NSMutableURLRequest *) updateGroup:(NSString *) groupIdentifier
-                           withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) userIdentifier
-                           fromGroup:(NSString *) groupIdentifier;
-
-- (NSMutableURLRequest *) deleteGroup:(NSString *) groupIdentifier;
-
-- (NSMutableURLRequest *) getUsersInGroup:(NSString *) groupIdentifier;
-
-// Roles http://apigee.com/docs/usergrid/content/role
-
-- (NSMutableURLRequest *) createRoleWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) getRoles;
-
-- (NSMutableURLRequest *) deleteRole:(NSString *) roleName;
-
-- (NSMutableURLRequest *) getPermissionsForRole:(NSString *) roleName;
-
-- (NSMutableURLRequest *) addPermissionsToRole:(NSString *) roleName
-                                    withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deletePermissionsFromRole:(NSString *) roleName
-                                       usingPattern:(NSString *) pattern;
-
-- (NSMutableURLRequest *) addUser:(NSString *)userIdentifier
-                           toRole:(NSString *)roleName;
-
-- (NSMutableURLRequest *) getUsersInRole:(NSString *) roleName;
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) userIdentifier
-                            fromRole:(NSString *) roleName;
-
-// Users http://apigee.com/docs/usergrid/content/user
-
-- (NSMutableURLRequest *) createUserWithValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) setPasswordForUser:(NSString *) username
-                                  toPassword:(NSString *) newPassword
-                                fromPassword:(NSString *) oldPassword;
-
-- (NSMutableURLRequest *) getUser:(NSString *) username;
-
-- (NSMutableURLRequest *) updateUser:(NSString *) username
-                          withValues:(NSDictionary *) values;
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) username;
-
-- (NSMutableURLRequest *) getUsersUsingQuery:(NSDictionary *) query;
-
-- (NSMutableURLRequest *) connectEntity:(NSString *) entity1
-                           inCollection:(NSString *) collection
-                               toEntity:(NSString *) entity2
-                    throughRelationship:(NSString *) relationship;
-
-- (NSMutableURLRequest *) disconnectEntity:(NSString *) entity1
-                              inCollection:(NSString *) collection
-                                fromEntity:(NSString *) entity2
-                       throughRelationship:(NSString *) relationship;
-
-- (NSMutableURLRequest *) getConnectionsToEntity:(NSString *) entity
-                                    inCollection:(NSString *) collection
-                             throughRelationship:(NSString *) relationship
-                                      usingQuery:(NSDictionary *) query;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGConnection.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGConnection.m b/sdks/ios/UGAPI/v2/UGConnection.m
deleted file mode 100644
index 48840b3..0000000
--- a/sdks/ios/UGAPI/v2/UGConnection.m
+++ /dev/null
@@ -1,938 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-//
-//  UGConnection.m
-//  UGAPIApp
-//
-//  Created by Tim Burks on 3/30/13.
-//
-//
-#import "UGHTTPHelpers.h"
-#import "UGHTTPResult.h"
-#import "UGConnection.h"
-
-static NSString *boolean_representation(BOOL value)
-{
-    return (value ? @"true" : @"false");
-}
-
-@interface UGConnection ()
-@property (nonatomic, strong) NSString *token;
-@property (nonatomic, strong) NSDate *tokenExpirationDate;
-@end
-
-@implementation UGConnection
-
-+ (UGConnection *) sharedConnection
-{
-    static UGConnection *connection = nil;
-    if (!connection) {
-        connection = [[UGConnection alloc] init];
-    }
-    return connection;
-}
-
-- (id) init {
-    if (self = [super init]) {
-        self.server = @"http://api.usergrid.com";
-    }
-    return self;
-}
-
-- (UGConnection *) copy
-{
-    UGConnection *copy = [super copy];
-    copy.server = self.server;
-    copy.organization = self.organization;
-    copy.application = self.application;
-    copy.token = self.token;
-    copy.tokenExpirationDate = self.tokenExpirationDate;
-    return copy;
-}
-
-#pragma mark - Internal helpers -
-
-- (NSString *) root
-{
-    return [NSString stringWithFormat:@"%@/%@/%@", self.server, self.organization, self.application];
-}
-
-- (NSMutableURLRequest *) authorizedRequestWithMethod:(NSString *) method
-                                                 path:(NSString *) path
-                                                 body:(NSData *) body
-{
-    NSMutableURLRequest *request = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:path]];
-    [request setHTTPMethod:method];
-    if (body) {
-        [request setHTTPBody:body];
-    }
-    if (self.token) {
-        [request setValue:[NSString stringWithFormat:@"Bearer %@", self.token] forHTTPHeaderField:@"Authorization"];
-    }
-    return request;
-}
-
-#pragma mark - External helpers -
-
-#pragma mark Queries
-
-- (NSMutableDictionary *) queryWithString:(NSString *) queryString
-                                    limit:(int) limit
-                                startUUID:(NSString *) startUUID
-                                   cursor:(NSString *) cursor
-                                 reversed:(BOOL) reversed
-{
-    NSMutableDictionary *query = [NSMutableDictionary dictionary];
-    if (queryString) {
-        query[@"ql"] = queryString;
-    }
-    if (limit > 0) {
-        query[@"limit"] = [NSNumber numberWithInt:limit];
-    }
-    if (startUUID) {
-        query[@"start"] = startUUID;
-    }
-    if (cursor) {
-        query[@"cursor"] = cursor;
-    }
-    if (reversed) {
-        query[@"reversed"] = @"true";
-    }
-    return query;
-}
-
-#pragma mark Authentication
-
-- (BOOL) authenticateWithResult:(UGHTTPResult *) result
-{
-    id results = result.object;
-    self.token = results[@"access_token"];
-    id expires = results[@"expires_in"];
-    self.tokenExpirationDate = [NSDate dateWithTimeIntervalSinceNow:[expires intValue]];
-    return [self isAuthenticated];
-}
-
-- (BOOL) isAuthenticated
-{
-    return (self.token &&
-            self.tokenExpirationDate &&
-            ([self.tokenExpirationDate compare:[NSDate date]] == NSOrderedDescending));
-}
-
-#pragma mark - Management API request generators -
-
-#pragma mark Access tokens
-// http://apigee.com/docs/usergrid/content/accesstoken
-
-- (NSMutableURLRequest *) getAccessTokenForAdminWithUsername:(NSString *) username
-                                                    password:(NSString *) password
-{
-    if (!username || !password) {
-        return nil;
-    }
-    NSDictionary *query = @{@"grant_type":@"password",
-                            @"username":username,
-                            @"password":password};
-    NSString *path = [NSMutableString stringWithFormat:@"%@/management/token?%@",
-                      self.server, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getAccessTokenForOrganizationWithClientID:(NSString *) clientID
-                                                       clientSecret:(NSString *) clientSecret
-{
-    if (!clientID || !clientSecret) {
-        return nil;
-    }
-    NSDictionary *query = @{@"grant_type":@"client_credentials",
-                            @"client_id":clientID,
-                            @"client_secret":clientSecret};
-    NSString *path = [NSMutableString stringWithFormat:@"%@/management/token?%@",
-                      self.server, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getAccessTokenForApplicationWithUsername:(NSString *) username
-                                                          password:(NSString *) password
-{
-    if (!username || !password) {
-        return nil;
-    }
-    NSDictionary *query = @{@"grant_type":@"password",
-                            @"username":username,
-                            @"password":password};
-    NSString *path = [NSMutableString stringWithFormat:@"%@/token?%@",
-                      self.root, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getAccessTokenForApplicationWithClientID:(NSString *) clientID
-                                                      clientSecret:(NSString *) clientSecret
-{
-    if (!clientID || !clientSecret) {
-        return nil;
-    }
-    NSDictionary *query = @{@"grant_type":@"client_credentials",
-                            @"client_id":clientID,
-                            @"client_secret":clientSecret};
-    NSString *path = [NSMutableString stringWithFormat:@"%@/token?%@",
-                      self.root, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Admin users
-// http://apigee.com/docs/usergrid/content/admin-user
-
-- (NSMutableURLRequest *) createAdminUserWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users",
-                      self.server];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) updateAdminUser:(NSString *) adminUserIdentifier
-                               withValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@",
-                      self.server, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) getAdminUser:(NSString *) adminUserIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@",
-                      self.server, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) setPasswordForAdminUser:(NSString *) adminUserIdentifier
-                                          toValue:(NSString *) password
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/password",
-                      self.server, adminUserIdentifier];
-    NSDictionary *values = @{@"password":password};
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) initiatePasswordResetForAdminUser
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/resetpw",
-                      self.server];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) completePasswordResetForAdminUserWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/resetpw",
-                      self.server];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) activateAdminUser:(NSString *) adminUserIdentifier
-                                  withToken:(NSString *) token
-                   sendingConfirmationEmail:(BOOL) sendingConfirmationEmail
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/activate",
-                      self.server, adminUserIdentifier];
-    NSDictionary *values = @{@"token":token,
-                             @"confirm_email":boolean_representation(sendingConfirmationEmail)};
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) reactivateAdminUser:(NSString *) adminUserIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/reactivate",
-                      self.server, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getActivityFeedForAdminUser:(NSString *) adminUserIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/users/%@/feed",
-                      self.server, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Client authorization
-// http://apigee.com/docs/usergrid/content/client-authorization
-
-- (NSMutableURLRequest *) authorizeClient:(NSString *) clientIdentifier withResponseType:(NSString *) responseType
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/authorize",
-                      self.server];
-    NSDictionary *values = @{@"response_type":responseType,
-                             @"client_id":clientIdentifier};
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-
-#pragma mark Organizations and Applications
-// http://apigee.com/docs/usergrid/content/organization
-
-- (NSMutableURLRequest *) createOrganizationWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations",
-                      self.server];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) getOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) activateOrganization:(NSString *) organizationIdentifier
-                                     withToken:(NSString *) token
-                      sendingConfirmationEmail:(BOOL) sendingConfirmationEmail
-{
-    NSDictionary *values = @{@"token":token,
-                             @"confirm_email":boolean_representation(sendingConfirmationEmail)};
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/activate?%@",
-                      self.server, organizationIdentifier, [values URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) reactivateOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/reactivate",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) generateClientCredentialsForOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/credentials",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getClientCredentialsForOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/credentials",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getActivityFeedForOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/feed",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) createApplicationInOrganization:(NSString *)organizationIdentifier withValues:(NSDictionary *)values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) deleteApplication:(NSString *) applicationIdentifier
-                             inOrganization:(NSString *)organizationIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications/%@",
-                      self.server, organizationIdentifier, applicationIdentifier];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) generateClientCredentialsForApplication:(NSString *) applicationIdentifier
-                                                   inOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/applications/%@/credentials",
-                      self.server, organizationIdentifier, applicationIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getClientCredentialsForApplication:(NSString *) applicationIdentifier
-                                              inOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/applications/%@/credentials",
-                      self.server, organizationIdentifier, applicationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getApplicationsInOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/management/organizations/%@/applications",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) addAdminUser:(NSString *) adminUserIdentifier
-                        toOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users/%@",
-                      self.server, organizationIdentifier, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getAdminUsersInOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users",
-                      self.server, organizationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) removeAdminUser:(NSString *) adminUserIdentifier
-                         fromOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSString stringWithFormat:@"%@/management/organizations/%@/users/%@",
-                      self.server, organizationIdentifier, adminUserIdentifier];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getApplication:(NSString *) applicationIdentifier
-                          inOrganization:(NSString *) organizationIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/%@/%@",
-                      self.server, organizationIdentifier, applicationIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark - Application API request generators -
-
-#pragma mark Activity
-// http://apigee.com/docs/usergrid/content/activity
-
-- (NSMutableURLRequest *) createActivityForUser:(NSString *) userIdentifier
-                                     withValues:(NSDictionary *) values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/activities",
-                      self.root, userIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) createActivityForGroup:(NSString *) groupIdentifier
-                                      withValues:(NSDictionary *) values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/activities",
-                      self.root, groupIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) createActivityForFollowersOfUser:(NSString *) userIdentifier
-                                                   inGroup:(NSString *) groupIdentifier
-                                                withValues:(NSDictionary *) values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/users/%@/activities",
-                      self.root, groupIdentifier, userIdentifier];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-
-}
-
-- (NSMutableURLRequest *) getActivitiesForUser:(NSString *) userIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/activities",
-                      self.root, userIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getActivitiesForGroup:(NSString *) groupIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/activities",
-                      self.root, groupIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getActivityFeedForUser:(NSString *) userIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/users/%@/feed",
-                      self.root, userIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getActivityFeedForGroup:(NSString *) groupIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/groups/%@/feed",
-                      self.root, groupIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Assets
-
-- (NSMutableURLRequest *) getDataForAsset:(NSString *) assetIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/assets/%@/data",
-                      self.root, assetIdentifier];
-    NSMutableURLRequest *request = [self authorizedRequestWithMethod:@"GET"
-                                                                path:path
-                                                                body:nil];
-    return request;
-}
-
-- (NSMutableURLRequest *) postData:(NSData *) data
-                          forAsset:(NSString *) assetIdentifier
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/assets/%@/data",
-                      self.root,
-                      assetIdentifier];
-    NSMutableURLRequest *request = [self authorizedRequestWithMethod:@"POST"
-                                                                path:path
-                                                                body:data];
-    [request setValue:@"application/octet-stream" forHTTPHeaderField:@"Content-Type"];
-    return request;
-}
-
-#pragma mark General-purpose endpoints
-// http://apigee.com/docs/usergrid/content/general-purpose-endpoints
-
-- (NSMutableURLRequest *) createEntityInCollection:(NSString *) collection
-                                        withValues:(NSDictionary *)values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/%@",
-                      self.root, collection];
-    NSError *error;
-    NSData *data = [NSJSONSerialization dataWithJSONObject:values options:0 error:&error];
-    if (!data) {
-        NSLog(@"%@", error);
-    }
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:data];
-}
-
-- (NSMutableURLRequest *) getEntity:(NSString *) entityIdentifier
-                       inCollection:(NSString *) collection
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/%@/%@",
-                      self.root, collection, entityIdentifier];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) updateEntity:(NSString *) entityIdentifier
-                          inCollection:(NSString *) collection
-                            withValues:(NSDictionary *) values {
-    NSString *path = [NSString stringWithFormat:@"%@/%@/%@", self.root, collection, entityIdentifier];
-    NSError *error;
-    NSData *data = [NSJSONSerialization dataWithJSONObject:values options:0 error:&error];
-    if (!data) {
-        NSLog(@"%@", error);
-    }
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:data];
-}
-
-- (NSMutableURLRequest *) deleteEntity:(NSString *) entityIdentifier
-                          inCollection:(NSString *) collection
-{
-    NSString *path = [NSString stringWithFormat:@"%@/%@/%@", self.root, collection, entityIdentifier];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
-                                            limit:(int) limit
-{
-    NSDictionary *query = [self queryWithString:@"select *"
-                                          limit:limit
-                                      startUUID:nil
-                                         cursor:nil
-                                       reversed:NO];
-    return [self getEntitiesInCollection:collection
-                              usingQuery:query];
-}
-
-- (NSMutableURLRequest *) getEntitiesInCollection:(NSString *) collection
-                                       usingQuery:(NSDictionary *) query
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/%@?%@",
-                      self.root,
-                      collection,
-                      [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) updateEntitiesInCollection:(NSString *) collection
-                                          usingQuery:(NSDictionary *) query
-                                          withValues:(NSDictionary *) values
-{
-    NSString *path = [NSMutableString stringWithFormat:@"%@/%@?%@",
-                      self.root,
-                      collection,
-                      [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
-{
-    NSDictionary *query = [self queryWithString:@"select *"
-                                          limit:0
-                                      startUUID:nil
-                                         cursor:nil
-                                       reversed:NO];
-    return [self deleteEntitiesInCollection:collection
-                                 usingQuery:query];
-}
-
-- (NSMutableURLRequest *) deleteEntitiesInCollection:(NSString *) collection
-                                          usingQuery:(NSDictionary *) query
-{
-    NSString *path = [NSString stringWithFormat:@"%@/%@?%@", self.root, collection, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Devices
-// http://apigee.com/docs/usergrid/content/device
-
-#pragma mark Events and Counters
-// http://apigee.com/docs/usergrid/content/events-and-counters
-
-- (NSMutableURLRequest *) createEventWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/events", self.root];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-#pragma mark Groups
-// http://apigee.com/docs/usergrid/content/group
-
-- (NSMutableURLRequest *) createGroupWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups", self.root];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) addUser:(NSString *) user
-                          toGroup:(NSString *) group
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users/%@",
-                      self.root, group, user];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getGroup:(NSString *) groupName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@", self.root, groupName];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) updateGroup:(NSString *) groupName
-                           withValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@",
-                      self.root, groupName];
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) user
-                           fromGroup:(NSString *) groupName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users/%@",
-                      self.root, groupName, user];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) deleteGroup:(NSString *) groupName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@",
-                      self.root, groupName];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getUsersInGroup:(NSString *) groupName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/groups/%@/users",
-                      self.root, groupName];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Roles
-// http://apigee.com/docs/usergrid/content/role
-
-- (NSMutableURLRequest *) createRoleWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles", self.root];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) getRoles
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles", self.root];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) deleteRole:(NSString *) roleName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@",
-                      self.root, roleName];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getPermissionsForRole:(NSString *) roleName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@",
-                      self.root, roleName];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) addPermissionsToRole:(NSString *) roleName
-                                    withValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/permissions",
-                      self.root, roleName];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) deletePermissionsFromRole:(NSString *) roleName
-                                       usingPattern:(NSString *) pattern
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/permissions?pattern=%@",
-                      self.root, roleName, pattern];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) addUser:(NSString *)user
-                           toRole:(NSString *)roleName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users/%@",
-                      self.root, roleName, user];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getUsersInRole:(NSString *) roleName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users",
-                      self.root, roleName];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) user
-                            fromRole:(NSString *) roleName
-{
-    NSString *path = [NSString stringWithFormat:@"%@/roles/%@/users/%@",
-                      self.root, roleName, user];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-#pragma mark Users
-// http://apigee.com/docs/usergrid/content/user
-
-- (NSMutableURLRequest *) createUserWithValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/users", self.root];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) setPasswordForUser:(NSString *) username
-                                  toPassword:(NSString *) newPassword
-                                fromPassword:(NSString *) oldPassword
-{
-    NSDictionary *query = @{@"newpassword":newPassword,
-                            @"oldpassword":oldPassword};
-    NSString *path = [NSString stringWithFormat:@"%@/users/%@/password",
-                      self.root, username];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:[query URLQueryData]];
-}
-
-- (NSMutableURLRequest *) getUser:(NSString *) username
-{
-    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
-                      self.root, username];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) updateUser:(NSString *) username
-                          withValues:(NSDictionary *) values
-{
-    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
-                      self.root, username];
-    return [self authorizedRequestWithMethod:@"PUT"
-                                        path:path
-                                        body:[values URLQueryData]];
-}
-
-- (NSMutableURLRequest *) deleteUser:(NSString *) username
-{
-    NSString *path = [NSString stringWithFormat:@"%@/users/%@",
-                      self.root, username];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getUsersUsingQuery:(NSDictionary *) query
-{
-    NSString *path = [NSString stringWithFormat:@"%@/users?%@",
-                      self.root, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) connectEntity:(NSString *) entity1
-                           inCollection:(NSString *) collection
-                               toEntity:(NSString *) entity2
-                    throughRelationship:(NSString *) relationship
-{
-    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@/%@",
-                      self.root, collection, entity1, relationship, entity2];
-    return [self authorizedRequestWithMethod:@"POST"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) disconnectEntity:(NSString *) entity1
-                              inCollection:(NSString *) collection
-                                fromEntity:(NSString *) entity2
-                       throughRelationship:(NSString *) relationship
-{
-    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@/%@",
-                      self.root, collection, entity1, relationship, entity2];
-    return [self authorizedRequestWithMethod:@"DELETE"
-                                        path:path
-                                        body:nil];
-}
-
-- (NSMutableURLRequest *) getConnectionsToEntity:(NSString *) entity
-                                    inCollection:(NSString *) collection
-                             throughRelationship:(NSString *) relationship
-                                      usingQuery:(NSDictionary *) query
-{
-    NSString *path = [NSString stringWithFormat:@"%@/%@/%@/%@?%@",
-                      self.root, collection, entity, relationship, [query URLQueryString]];
-    return [self authorizedRequestWithMethod:@"GET"
-                                        path:path
-                                        body:nil];
-}
-
-@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPClient.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPClient.h b/sdks/ios/UGAPI/v2/UGHTTPClient.h
deleted file mode 100644
index 64fe9be..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPClient.h
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#import <Foundation/Foundation.h>
-
-@class UGHTTPResult;
-
-typedef void (^UGHTTPCompletionHandler)(UGHTTPResult *result);
-typedef void (^UGHTTPProgressHandler)(CGFloat progress);
-
-@interface UGHTTPClient : NSObject
-#if TARGET_OS_IPHONE
-<NSURLConnectionDataDelegate>
-#endif
-
-@property (nonatomic, copy) UGHTTPCompletionHandler completionHandler;
-@property (nonatomic, copy) UGHTTPProgressHandler progressHandler;
-@property (readonly) CGFloat progress;
-@property (readonly) BOOL isRunning;
-
-- (id) initWithRequest:(NSMutableURLRequest *) request;
-
-- (UGHTTPResult *) connect;
-
-- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler;
-
-- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler
-                      progressHandler:(UGHTTPProgressHandler) progressHandler;
-
-- (void) cancel;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPClient.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPClient.m b/sdks/ios/UGAPI/v2/UGHTTPClient.m
deleted file mode 100644
index 38aee42..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPClient.m
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-
-@interface UGHTTPClient ()
-@property (nonatomic, strong) NSMutableURLRequest *request;
-@property (nonatomic, strong) NSMutableData *data;
-@property (nonatomic, strong) NSHTTPURLResponse *response;
-@property (nonatomic, strong) NSURLConnection *connection;
-@end
-
-@implementation UGHTTPClient
-
-static int activityCount = 0;
-
-+ (void) retainNetworkActivityIndicator {
-    activityCount++;
-#if TARGET_OS_IPHONE
-    [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:YES];
-#endif
-}
-
-+ (void) releaseNetworkActivityIndicator {
-    activityCount--;
-#if TARGET_OS_IPHONE
-    if (activityCount == 0) {
-        [[UIApplication sharedApplication] setNetworkActivityIndicatorVisible:NO];
-    }
-#endif
-}
-
-- (id) initWithRequest:(NSMutableURLRequest *)request
-{
-    if (self = [super init]) {
-        self.request = request;
-    }
-    return self;
-}
-
-- (UGHTTPResult *) connect {
-    NSHTTPURLResponse *response;
-    NSError *error;
-    UGHTTPResult *result = [[UGHTTPResult alloc] init];
-    result.data = [NSURLConnection sendSynchronousRequest:self.request returningResponse:&response error:&error];
-    result.response = response;
-    result.error = error;
-    if (self.completionHandler) {
-        self.completionHandler(result);
-    }
-    return result;
-}
-
-- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler)completionHandler
-                      progressHandler:(UGHTTPProgressHandler)progressHandler
-{
-   	[self.request setCachePolicy:NSURLRequestReloadIgnoringLocalCacheData];
-    self.data = nil;
-    self.response = nil;
-	self.completionHandler = completionHandler;
-    self.progressHandler = progressHandler;
-	self.connection = [[NSURLConnection alloc] initWithRequest:self.request delegate:self];
-    [isa retainNetworkActivityIndicator];
-}
-
-- (void) connectWithCompletionHandler:(UGHTTPCompletionHandler) completionHandler
-{
-    [self connectWithCompletionHandler:completionHandler progressHandler:nil];
-}
-
-- (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSHTTPURLResponse *)response
-{
-	self.response = response;
-    if (self.progressHandler) {
-        self.progressHandler(0.0);
-    }
-}
-
-- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)newData
-{
-    if (!self.data) {
-        self.data = [NSMutableData dataWithData:newData];
-    } else {
-        [self.data appendData:newData];
-    }
-    if (self.progressHandler) {
-        long long expectedLength = [self.response expectedContentLength];
-        if (expectedLength > 0) {
-            CGFloat progress = ((CGFloat) [self.data length]) / expectedLength;
-            self.progressHandler(progress);
-        }
-    }
-}
-
-- (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
-{
-    if (self.completionHandler) {
-        UGHTTPResult *result = [[UGHTTPResult alloc] init];
-        result.response = self.response;
-        result.data = self.data;
-        result.error = error;
-        self.completionHandler(result);
-    }
-	self.connection = nil;
-    self.data = nil;
-    [isa releaseNetworkActivityIndicator];
-}
-
-- (void)connectionDidFinishLoading:(NSURLConnection *)connection
-{
-    if (self.progressHandler) {
-        self.progressHandler(1.0);
-    }
-    if (self.completionHandler) {
-        UGHTTPResult *result = [[UGHTTPResult alloc] init];
-        result.response = self.response;
-        result.data = self.data;
-        result.error = nil;
-        //[self.data writeToFile:@"/tmp/data" atomically:NO];
-        self.completionHandler(result);
-    }
-    self.connection = nil;
-    self.data = nil;
-    [isa releaseNetworkActivityIndicator];
-}
-
-- (void) cancel {
-    if (self.connection) {
-        [self.connection cancel];
-    }
-    self.connection = nil;
-}
-
-- (BOOL) isRunning {
-    return (self.connection != nil);
-}
-
-- (CGFloat) progress {
-    long long expectedLength = [self.response expectedContentLength];
-    if (expectedLength > 0) {
-        return ((CGFloat) [self.data length]) / expectedLength;
-    } else {
-        return 0.0;
-    }
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPHelpers.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPHelpers.h b/sdks/ios/UGAPI/v2/UGHTTPHelpers.h
deleted file mode 100644
index 64c678a..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPHelpers.h
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
- //
-//  UGHTTPHelpers.h
-//  UGHTTP
-//
-//  Created by Tim Burks on 2/24/12.
-//
-#import <Foundation/Foundation.h>
-
-@interface NSString (UGHTTPHelpers)
-- (NSString *) URLEncodedString;
-- (NSString *) URLDecodedString;
-- (NSDictionary *) URLQueryDictionary;
-@end
-
-@interface NSData (UGHTTPHelpers)
-- (NSDictionary *) URLQueryDictionary;
-@end
-
-@interface NSDictionary (UGHTTPHelpers)
-- (NSString *) URLQueryString;
-- (NSData *) URLQueryData;
-@end
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPHelpers.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPHelpers.m b/sdks/ios/UGAPI/v2/UGHTTPHelpers.m
deleted file mode 100644
index 9bad1b9..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPHelpers.m
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-//
-//  UGHTTPHelpers.m
-//  UGHTTP
-//
-//  Created by Tim Burks on 2/24/12.
-//
-
-#import "UGHTTPHelpers.h"
-#import <wctype.h>
-
-static unichar char_to_int(unichar c)
-{
-    switch (c) {
-        case '0': return 0;
-        case '1': return 1;
-        case '2': return 2;
-        case '3': return 3;
-        case '4': return 4;
-        case '5': return 5;
-        case '6': return 6;
-        case '7': return 7;
-        case '8': return 8;
-        case '9': return 9;
-        case 'A': case 'a': return 10;
-        case 'B': case 'b': return 11;
-        case 'C': case 'c': return 12;
-        case 'D': case 'd': return 13;
-        case 'E': case 'e': return 14;
-        case 'F': case 'f': return 15;
-    }
-    return 0;                                     // not good
-}
-
-static char int_to_char[] = "0123456789ABCDEF";
-
-@implementation NSString (UGHTTPHelpers)
-
-- (NSString *) URLEncodedString
-{
-    NSMutableString *result = [NSMutableString string];
-    int i = 0;
-    const char *source = [self cStringUsingEncoding:NSUTF8StringEncoding];
-    unsigned long max = strlen(source);
-    while (i < max) {
-        unsigned char c = source[i++];
-        if (c == ' ') {
-            [result appendString:@"%20"];
-        }
-        else if (iswalpha(c) || iswdigit(c) || (c == '-') || (c == '.') || (c == '_') || (c == '~')) {
-            [result appendFormat:@"%c", c];
-        }
-        else {
-            [result appendString:[NSString stringWithFormat:@"%%%c%c", int_to_char[(c/16)%16], int_to_char[c%16]]];
-        }
-    }
-    return result;
-}
-
-- (NSString *) URLDecodedString
-{
-    int i = 0;
-    NSUInteger max = [self length];
-    char *buffer = (char *) malloc ((max + 1) * sizeof(char));
-    int j = 0;
-    while (i < max) {
-        char c = [self characterAtIndex:i++];
-        switch (c) {
-            case '+':
-                buffer[j++] = ' ';
-                break;
-            case '%':
-                buffer[j++] =
-                char_to_int([self characterAtIndex:i])*16
-                + char_to_int([self characterAtIndex:i+1]);
-                i = i + 2;
-                break;
-            default:
-                buffer[j++] = c;
-                break;
-        }
-    }
-    buffer[j] = 0;
-    NSString *result = [NSMutableString stringWithCString:buffer encoding:NSUTF8StringEncoding];
-    if (!result) result = [NSMutableString stringWithCString:buffer encoding:NSASCIIStringEncoding];
-    free(buffer);
-    return result;
-}
-
-- (NSDictionary *) URLQueryDictionary
-{
-    NSMutableDictionary *result = [NSMutableDictionary dictionary];
-    NSArray *pairs = [self componentsSeparatedByString:@"&"];
-    int i;
-    NSUInteger max = [pairs count];
-    for (i = 0; i < max; i++) {
-        NSArray *pair = [[pairs objectAtIndex:i] componentsSeparatedByString:@"="];
-        if ([pair count] == 2) {
-            NSString *key = [[pair objectAtIndex:0] URLDecodedString];
-            NSString *value = [[pair objectAtIndex:1] URLDecodedString];
-            [result setObject:value forKey:key];
-        }
-    }
-    return result;
-}
-
-@end
-
-@implementation NSDictionary (UGHTTPHelpers)
-
-- (NSString *) URLQueryString
-{
-    NSMutableString *result = [NSMutableString string];
-    NSEnumerator *keyEnumerator = [[[self allKeys] sortedArrayUsingSelector:@selector(compare:)] objectEnumerator];
-    id key;
-    while ((key = [keyEnumerator nextObject])) {
-        id value = [self objectForKey:key];
-        if (![value isKindOfClass:[NSString class]]) {
-            if ([value respondsToSelector:@selector(stringValue)]) {
-                value = [value stringValue];
-            }
-        }
-        if ([value isKindOfClass:[NSString class]]) {
-            if ([result length] > 0) [result appendString:@"&"];
-            [result appendString:[NSString stringWithFormat:@"%@=%@",
-                                  [key URLEncodedString],
-                                  [value URLEncodedString]]];
-        }
-    }
-    return [NSString stringWithString:result];
-}
-
-- (NSData *) URLQueryData
-{
-    return [[self URLQueryString] dataUsingEncoding:NSUTF8StringEncoding];
-}
-
-@end
-
-@implementation NSData (UGHTTPHelpers)
-
-- (NSDictionary *) URLQueryDictionary {
-    return [[[NSString alloc] initWithData:self encoding:NSUTF8StringEncoding] URLQueryDictionary];
-}
-
-@end
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPResult.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPResult.h b/sdks/ios/UGAPI/v2/UGHTTPResult.h
deleted file mode 100644
index e8faf9b..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPResult.h
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-//
-//  UGHTTPResult.h
-//  UGAPIApp
-//
-//  Created by Tim Burks on 4/3/13.
-//
-//
-
-#import <Foundation/Foundation.h>
-
-@interface UGHTTPResult : NSObject
-@property (nonatomic, strong) NSHTTPURLResponse *response;
-@property (nonatomic, strong) NSData *data;
-@property (nonatomic, strong) NSError *error;
-@property (nonatomic, strong) id object;
-@property (nonatomic, readonly) NSString *UTF8String;
-
-@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/v2/UGHTTPResult.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/v2/UGHTTPResult.m b/sdks/ios/UGAPI/v2/UGHTTPResult.m
deleted file mode 100644
index 2e0e115..0000000
--- a/sdks/ios/UGAPI/v2/UGHTTPResult.m
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-//
-//  UGHTTPResult.m
-//  UGAPIApp
-//
-//  Created by Tim Burks on 4/3/13.
-//
-//
-
-#import "UGHTTPResult.h"
-
-@implementation UGHTTPResult
-
-- (id) object {
-    if (!_object && !_error) {
-        NSError *error;
-        // NSLog(@"JSON %@", [[NSString alloc] initWithData:_data encoding:NSUTF8StringEncoding]);
-        _object = [NSJSONSerialization JSONObjectWithData:_data options:0 error:&error];
-        _error = error;
-        if (_error) {
-            NSLog(@"JSON ERROR: %@", [error description]);
-        }
-    }
-    return _object;
-}
-
-- (NSString *) UTF8String {
-    return [[NSString alloc] initWithData:self.data encoding:NSUTF8StringEncoding];
-}
-
-@end
\ No newline at end of file


[36/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties.xcodeproj/project.pbxproj
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties.xcodeproj/project.pbxproj b/sdks/ios/samples/parties/parties.xcodeproj/project.pbxproj
deleted file mode 100644
index 6bad677..0000000
--- a/sdks/ios/samples/parties/parties.xcodeproj/project.pbxproj
+++ /dev/null
@@ -1,481 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 46;
-	objects = {
-
-/* Begin PBXBuildFile section */
-		22C1D70617357FC8006202F6 /* MapKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22C1D70517357FC8006202F6 /* MapKit.framework */; };
-		22C1D708173580ED006202F6 /* CoreLocation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22C1D707173580ED006202F6 /* CoreLocation.framework */; };
-		22CDB04A173607580015D864 /* Icon.png in Resources */ = {isa = PBXBuildFile; fileRef = 22CDB049173607580015D864 /* Icon.png */; };
-		22FC71211730705D00153630 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71201730705D00153630 /* UIKit.framework */; };
-		22FC71231730705D00153630 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71221730705D00153630 /* Foundation.framework */; };
-		22FC71251730705D00153630 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 22FC71241730705D00153630 /* CoreGraphics.framework */; };
-		22FC712B1730705D00153630 /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71291730705D00153630 /* InfoPlist.strings */; };
-		22FC712D1730705D00153630 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC712C1730705D00153630 /* main.m */; };
-		22FC71311730705D00153630 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71301730705D00153630 /* AppDelegate.m */; };
-		22FC71331730705D00153630 /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71321730705D00153630 /* Default.png */; };
-		22FC71351730705D00153630 /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71341730705D00153630 /* Default@2x.png */; };
-		22FC71371730705D00153630 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 22FC71361730705D00153630 /* Default-568h@2x.png */; };
-		22FC71701730709800153630 /* NSObject+SBJson.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71401730709800153630 /* NSObject+SBJson.m */; };
-		22FC71711730709800153630 /* SBJsonParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71431730709800153630 /* SBJsonParser.m */; };
-		22FC71721730709800153630 /* SBJsonStreamParser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71451730709800153630 /* SBJsonStreamParser.m */; };
-		22FC71731730709800153630 /* SBJsonStreamParserAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */; };
-		22FC71741730709800153630 /* SBJsonStreamParserAdapter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */; };
-		22FC71751730709800153630 /* SBJsonStreamParserState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714B1730709800153630 /* SBJsonStreamParserState.m */; };
-		22FC71761730709800153630 /* SBJsonStreamWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714D1730709800153630 /* SBJsonStreamWriter.m */; };
-		22FC71771730709800153630 /* SBJsonStreamWriterAccumulator.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */; };
-		22FC71781730709800153630 /* SBJsonStreamWriterState.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71511730709800153630 /* SBJsonStreamWriterState.m */; };
-		22FC71791730709800153630 /* SBJsonTokeniser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71531730709800153630 /* SBJsonTokeniser.m */; };
-		22FC717A1730709800153630 /* SBJsonUTF8Stream.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71551730709800153630 /* SBJsonUTF8Stream.m */; };
-		22FC717B1730709800153630 /* SBJsonWriter.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71571730709800153630 /* SBJsonWriter.m */; };
-		22FC717C1730709800153630 /* UGActivity.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71591730709800153630 /* UGActivity.m */; };
-		22FC717D1730709800153630 /* UGClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC715B1730709800153630 /* UGClient.m */; };
-		22FC717E1730709800153630 /* UGClientResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC715E1730709800153630 /* UGClientResponse.m */; };
-		22FC717F1730709800153630 /* UGHTTPManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71601730709800153630 /* UGHTTPManager.m */; };
-		22FC71801730709800153630 /* UGMultiStepAction.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71621730709800153630 /* UGMultiStepAction.m */; };
-		22FC71811730709800153630 /* UGQuery.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71641730709800153630 /* UGQuery.m */; };
-		22FC71821730709800153630 /* UGUser.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71661730709800153630 /* UGUser.m */; };
-		22FC71831730709800153630 /* UGConnection.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC71691730709800153630 /* UGConnection.m */; };
-		22FC71841730709800153630 /* UGHTTPClient.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716B1730709800153630 /* UGHTTPClient.m */; };
-		22FC71851730709800153630 /* UGHTTPHelpers.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716D1730709800153630 /* UGHTTPHelpers.m */; };
-		22FC71861730709800153630 /* UGHTTPResult.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC716F1730709800153630 /* UGHTTPResult.m */; };
-		22FC7189173070DF00153630 /* PartiesViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC7188173070DF00153630 /* PartiesViewController.m */; };
-		22FC718C173075D300153630 /* PartyViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22FC718B173075D300153630 /* PartyViewController.m */; };
-/* End PBXBuildFile section */
-
-/* Begin PBXFileReference section */
-		22C1D70517357FC8006202F6 /* MapKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MapKit.framework; path = System/Library/Frameworks/MapKit.framework; sourceTree = SDKROOT; };
-		22C1D707173580ED006202F6 /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; };
-		22CDB049173607580015D864 /* Icon.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Icon.png; sourceTree = "<group>"; };
-		22FC711D1730705D00153630 /* parties.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = parties.app; sourceTree = BUILT_PRODUCTS_DIR; };
-		22FC71201730705D00153630 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
-		22FC71221730705D00153630 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
-		22FC71241730705D00153630 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
-		22FC71281730705D00153630 /* parties-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "parties-Info.plist"; sourceTree = "<group>"; };
-		22FC712A1730705D00153630 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
-		22FC712C1730705D00153630 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
-		22FC712E1730705D00153630 /* parties-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "parties-Prefix.pch"; sourceTree = "<group>"; };
-		22FC712F1730705D00153630 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; };
-		22FC71301730705D00153630 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; };
-		22FC71321730705D00153630 /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
-		22FC71341730705D00153630 /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
-		22FC71361730705D00153630 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
-		22FC713F1730709800153630 /* NSObject+SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSObject+SBJson.h"; sourceTree = "<group>"; };
-		22FC71401730709800153630 /* NSObject+SBJson.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSObject+SBJson.m"; sourceTree = "<group>"; };
-		22FC71411730709800153630 /* SBJson.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJson.h; sourceTree = "<group>"; };
-		22FC71421730709800153630 /* SBJsonParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonParser.h; sourceTree = "<group>"; };
-		22FC71431730709800153630 /* SBJsonParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonParser.m; sourceTree = "<group>"; };
-		22FC71441730709800153630 /* SBJsonStreamParser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParser.h; sourceTree = "<group>"; };
-		22FC71451730709800153630 /* SBJsonStreamParser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParser.m; sourceTree = "<group>"; };
-		22FC71461730709800153630 /* SBJsonStreamParserAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAccumulator.h; sourceTree = "<group>"; };
-		22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAccumulator.m; sourceTree = "<group>"; };
-		22FC71481730709800153630 /* SBJsonStreamParserAdapter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserAdapter.h; sourceTree = "<group>"; };
-		22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserAdapter.m; sourceTree = "<group>"; };
-		22FC714A1730709800153630 /* SBJsonStreamParserState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamParserState.h; sourceTree = "<group>"; };
-		22FC714B1730709800153630 /* SBJsonStreamParserState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamParserState.m; sourceTree = "<group>"; };
-		22FC714C1730709800153630 /* SBJsonStreamWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriter.h; sourceTree = "<group>"; };
-		22FC714D1730709800153630 /* SBJsonStreamWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriter.m; sourceTree = "<group>"; };
-		22FC714E1730709800153630 /* SBJsonStreamWriterAccumulator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterAccumulator.h; sourceTree = "<group>"; };
-		22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterAccumulator.m; sourceTree = "<group>"; };
-		22FC71501730709800153630 /* SBJsonStreamWriterState.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonStreamWriterState.h; sourceTree = "<group>"; };
-		22FC71511730709800153630 /* SBJsonStreamWriterState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonStreamWriterState.m; sourceTree = "<group>"; };
-		22FC71521730709800153630 /* SBJsonTokeniser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonTokeniser.h; sourceTree = "<group>"; };
-		22FC71531730709800153630 /* SBJsonTokeniser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonTokeniser.m; sourceTree = "<group>"; };
-		22FC71541730709800153630 /* SBJsonUTF8Stream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonUTF8Stream.h; sourceTree = "<group>"; };
-		22FC71551730709800153630 /* SBJsonUTF8Stream.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonUTF8Stream.m; sourceTree = "<group>"; };
-		22FC71561730709800153630 /* SBJsonWriter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SBJsonWriter.h; sourceTree = "<group>"; };
-		22FC71571730709800153630 /* SBJsonWriter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SBJsonWriter.m; sourceTree = "<group>"; };
-		22FC71581730709800153630 /* UGActivity.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGActivity.h; sourceTree = "<group>"; };
-		22FC71591730709800153630 /* UGActivity.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGActivity.m; sourceTree = "<group>"; };
-		22FC715A1730709800153630 /* UGClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClient.h; sourceTree = "<group>"; };
-		22FC715B1730709800153630 /* UGClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClient.m; sourceTree = "<group>"; };
-		22FC715C1730709800153630 /* UGClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientDelegate.h; sourceTree = "<group>"; };
-		22FC715D1730709800153630 /* UGClientResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGClientResponse.h; sourceTree = "<group>"; };
-		22FC715E1730709800153630 /* UGClientResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGClientResponse.m; sourceTree = "<group>"; };
-		22FC715F1730709800153630 /* UGHTTPManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPManager.h; sourceTree = "<group>"; };
-		22FC71601730709800153630 /* UGHTTPManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPManager.m; sourceTree = "<group>"; };
-		22FC71611730709800153630 /* UGMultiStepAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGMultiStepAction.h; sourceTree = "<group>"; };
-		22FC71621730709800153630 /* UGMultiStepAction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGMultiStepAction.m; sourceTree = "<group>"; };
-		22FC71631730709800153630 /* UGQuery.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGQuery.h; sourceTree = "<group>"; };
-		22FC71641730709800153630 /* UGQuery.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGQuery.m; sourceTree = "<group>"; };
-		22FC71651730709800153630 /* UGUser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGUser.h; sourceTree = "<group>"; };
-		22FC71661730709800153630 /* UGUser.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGUser.m; sourceTree = "<group>"; };
-		22FC71681730709800153630 /* UGConnection.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGConnection.h; sourceTree = "<group>"; };
-		22FC71691730709800153630 /* UGConnection.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGConnection.m; sourceTree = "<group>"; };
-		22FC716A1730709800153630 /* UGHTTPClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPClient.h; sourceTree = "<group>"; };
-		22FC716B1730709800153630 /* UGHTTPClient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPClient.m; sourceTree = "<group>"; };
-		22FC716C1730709800153630 /* UGHTTPHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPHelpers.h; sourceTree = "<group>"; };
-		22FC716D1730709800153630 /* UGHTTPHelpers.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPHelpers.m; sourceTree = "<group>"; };
-		22FC716E1730709800153630 /* UGHTTPResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UGHTTPResult.h; sourceTree = "<group>"; };
-		22FC716F1730709800153630 /* UGHTTPResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UGHTTPResult.m; sourceTree = "<group>"; };
-		22FC7187173070DF00153630 /* PartiesViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PartiesViewController.h; sourceTree = "<group>"; };
-		22FC7188173070DF00153630 /* PartiesViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PartiesViewController.m; sourceTree = "<group>"; };
-		22FC718A173075D300153630 /* PartyViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PartyViewController.h; sourceTree = "<group>"; };
-		22FC718B173075D300153630 /* PartyViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PartyViewController.m; sourceTree = "<group>"; };
-/* End PBXFileReference section */
-
-/* Begin PBXFrameworksBuildPhase section */
-		22FC711A1730705D00153630 /* Frameworks */ = {
-			isa = PBXFrameworksBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22C1D708173580ED006202F6 /* CoreLocation.framework in Frameworks */,
-				22C1D70617357FC8006202F6 /* MapKit.framework in Frameworks */,
-				22FC71211730705D00153630 /* UIKit.framework in Frameworks */,
-				22FC71231730705D00153630 /* Foundation.framework in Frameworks */,
-				22FC71251730705D00153630 /* CoreGraphics.framework in Frameworks */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXFrameworksBuildPhase section */
-
-/* Begin PBXGroup section */
-		22FC71141730705D00153630 = {
-			isa = PBXGroup;
-			children = (
-				22C1D707173580ED006202F6 /* CoreLocation.framework */,
-				22C1D70517357FC8006202F6 /* MapKit.framework */,
-				22FC713D1730709800153630 /* UGAPI */,
-				22FC71261730705D00153630 /* parties */,
-				22FC711F1730705D00153630 /* Frameworks */,
-				22FC711E1730705D00153630 /* Products */,
-			);
-			sourceTree = "<group>";
-		};
-		22FC711E1730705D00153630 /* Products */ = {
-			isa = PBXGroup;
-			children = (
-				22FC711D1730705D00153630 /* parties.app */,
-			);
-			name = Products;
-			sourceTree = "<group>";
-		};
-		22FC711F1730705D00153630 /* Frameworks */ = {
-			isa = PBXGroup;
-			children = (
-				22FC71201730705D00153630 /* UIKit.framework */,
-				22FC71221730705D00153630 /* Foundation.framework */,
-				22FC71241730705D00153630 /* CoreGraphics.framework */,
-			);
-			name = Frameworks;
-			sourceTree = "<group>";
-		};
-		22FC71261730705D00153630 /* parties */ = {
-			isa = PBXGroup;
-			children = (
-				22FC712F1730705D00153630 /* AppDelegate.h */,
-				22FC71301730705D00153630 /* AppDelegate.m */,
-				22FC71271730705D00153630 /* Supporting Files */,
-				22FC7187173070DF00153630 /* PartiesViewController.h */,
-				22FC7188173070DF00153630 /* PartiesViewController.m */,
-				22FC718A173075D300153630 /* PartyViewController.h */,
-				22FC718B173075D300153630 /* PartyViewController.m */,
-			);
-			path = parties;
-			sourceTree = "<group>";
-		};
-		22FC71271730705D00153630 /* Supporting Files */ = {
-			isa = PBXGroup;
-			children = (
-				22CDB049173607580015D864 /* Icon.png */,
-				22FC71281730705D00153630 /* parties-Info.plist */,
-				22FC71291730705D00153630 /* InfoPlist.strings */,
-				22FC712C1730705D00153630 /* main.m */,
-				22FC712E1730705D00153630 /* parties-Prefix.pch */,
-				22FC71321730705D00153630 /* Default.png */,
-				22FC71341730705D00153630 /* Default@2x.png */,
-				22FC71361730705D00153630 /* Default-568h@2x.png */,
-			);
-			name = "Supporting Files";
-			sourceTree = "<group>";
-		};
-		22FC713D1730709800153630 /* UGAPI */ = {
-			isa = PBXGroup;
-			children = (
-				22FC713E1730709800153630 /* SBJson */,
-				22FC71581730709800153630 /* UGActivity.h */,
-				22FC71591730709800153630 /* UGActivity.m */,
-				22FC715A1730709800153630 /* UGClient.h */,
-				22FC715B1730709800153630 /* UGClient.m */,
-				22FC715C1730709800153630 /* UGClientDelegate.h */,
-				22FC715D1730709800153630 /* UGClientResponse.h */,
-				22FC715E1730709800153630 /* UGClientResponse.m */,
-				22FC715F1730709800153630 /* UGHTTPManager.h */,
-				22FC71601730709800153630 /* UGHTTPManager.m */,
-				22FC71611730709800153630 /* UGMultiStepAction.h */,
-				22FC71621730709800153630 /* UGMultiStepAction.m */,
-				22FC71631730709800153630 /* UGQuery.h */,
-				22FC71641730709800153630 /* UGQuery.m */,
-				22FC71651730709800153630 /* UGUser.h */,
-				22FC71661730709800153630 /* UGUser.m */,
-				22FC71671730709800153630 /* v2 */,
-			);
-			name = UGAPI;
-			path = ../../UGAPI;
-			sourceTree = "<group>";
-		};
-		22FC713E1730709800153630 /* SBJson */ = {
-			isa = PBXGroup;
-			children = (
-				22FC713F1730709800153630 /* NSObject+SBJson.h */,
-				22FC71401730709800153630 /* NSObject+SBJson.m */,
-				22FC71411730709800153630 /* SBJson.h */,
-				22FC71421730709800153630 /* SBJsonParser.h */,
-				22FC71431730709800153630 /* SBJsonParser.m */,
-				22FC71441730709800153630 /* SBJsonStreamParser.h */,
-				22FC71451730709800153630 /* SBJsonStreamParser.m */,
-				22FC71461730709800153630 /* SBJsonStreamParserAccumulator.h */,
-				22FC71471730709800153630 /* SBJsonStreamParserAccumulator.m */,
-				22FC71481730709800153630 /* SBJsonStreamParserAdapter.h */,
-				22FC71491730709800153630 /* SBJsonStreamParserAdapter.m */,
-				22FC714A1730709800153630 /* SBJsonStreamParserState.h */,
-				22FC714B1730709800153630 /* SBJsonStreamParserState.m */,
-				22FC714C1730709800153630 /* SBJsonStreamWriter.h */,
-				22FC714D1730709800153630 /* SBJsonStreamWriter.m */,
-				22FC714E1730709800153630 /* SBJsonStreamWriterAccumulator.h */,
-				22FC714F1730709800153630 /* SBJsonStreamWriterAccumulator.m */,
-				22FC71501730709800153630 /* SBJsonStreamWriterState.h */,
-				22FC71511730709800153630 /* SBJsonStreamWriterState.m */,
-				22FC71521730709800153630 /* SBJsonTokeniser.h */,
-				22FC71531730709800153630 /* SBJsonTokeniser.m */,
-				22FC71541730709800153630 /* SBJsonUTF8Stream.h */,
-				22FC71551730709800153630 /* SBJsonUTF8Stream.m */,
-				22FC71561730709800153630 /* SBJsonWriter.h */,
-				22FC71571730709800153630 /* SBJsonWriter.m */,
-			);
-			path = SBJson;
-			sourceTree = "<group>";
-		};
-		22FC71671730709800153630 /* v2 */ = {
-			isa = PBXGroup;
-			children = (
-				22FC71681730709800153630 /* UGConnection.h */,
-				22FC71691730709800153630 /* UGConnection.m */,
-				22FC716A1730709800153630 /* UGHTTPClient.h */,
-				22FC716B1730709800153630 /* UGHTTPClient.m */,
-				22FC716C1730709800153630 /* UGHTTPHelpers.h */,
-				22FC716D1730709800153630 /* UGHTTPHelpers.m */,
-				22FC716E1730709800153630 /* UGHTTPResult.h */,
-				22FC716F1730709800153630 /* UGHTTPResult.m */,
-			);
-			path = v2;
-			sourceTree = "<group>";
-		};
-/* End PBXGroup section */
-
-/* Begin PBXNativeTarget section */
-		22FC711C1730705D00153630 /* parties */ = {
-			isa = PBXNativeTarget;
-			buildConfigurationList = 22FC713A1730705D00153630 /* Build configuration list for PBXNativeTarget "parties" */;
-			buildPhases = (
-				22FC71191730705D00153630 /* Sources */,
-				22FC711A1730705D00153630 /* Frameworks */,
-				22FC711B1730705D00153630 /* Resources */,
-			);
-			buildRules = (
-			);
-			dependencies = (
-			);
-			name = parties;
-			productName = parties;
-			productReference = 22FC711D1730705D00153630 /* parties.app */;
-			productType = "com.apple.product-type.application";
-		};
-/* End PBXNativeTarget section */
-
-/* Begin PBXProject section */
-		22FC71151730705D00153630 /* Project object */ = {
-			isa = PBXProject;
-			attributes = {
-				LastUpgradeCheck = 0460;
-				ORGANIZATIONNAME = Apigee;
-			};
-			buildConfigurationList = 22FC71181730705D00153630 /* Build configuration list for PBXProject "parties" */;
-			compatibilityVersion = "Xcode 3.2";
-			developmentRegion = English;
-			hasScannedForEncodings = 0;
-			knownRegions = (
-				en,
-			);
-			mainGroup = 22FC71141730705D00153630;
-			productRefGroup = 22FC711E1730705D00153630 /* Products */;
-			projectDirPath = "";
-			projectRoot = "";
-			targets = (
-				22FC711C1730705D00153630 /* parties */,
-			);
-		};
-/* End PBXProject section */
-
-/* Begin PBXResourcesBuildPhase section */
-		22FC711B1730705D00153630 /* Resources */ = {
-			isa = PBXResourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22FC712B1730705D00153630 /* InfoPlist.strings in Resources */,
-				22FC71331730705D00153630 /* Default.png in Resources */,
-				22FC71351730705D00153630 /* Default@2x.png in Resources */,
-				22FC71371730705D00153630 /* Default-568h@2x.png in Resources */,
-				22CDB04A173607580015D864 /* Icon.png in Resources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXResourcesBuildPhase section */
-
-/* Begin PBXSourcesBuildPhase section */
-		22FC71191730705D00153630 /* Sources */ = {
-			isa = PBXSourcesBuildPhase;
-			buildActionMask = 2147483647;
-			files = (
-				22FC712D1730705D00153630 /* main.m in Sources */,
-				22FC71311730705D00153630 /* AppDelegate.m in Sources */,
-				22FC71701730709800153630 /* NSObject+SBJson.m in Sources */,
-				22FC71711730709800153630 /* SBJsonParser.m in Sources */,
-				22FC71721730709800153630 /* SBJsonStreamParser.m in Sources */,
-				22FC71731730709800153630 /* SBJsonStreamParserAccumulator.m in Sources */,
-				22FC71741730709800153630 /* SBJsonStreamParserAdapter.m in Sources */,
-				22FC71751730709800153630 /* SBJsonStreamParserState.m in Sources */,
-				22FC71761730709800153630 /* SBJsonStreamWriter.m in Sources */,
-				22FC71771730709800153630 /* SBJsonStreamWriterAccumulator.m in Sources */,
-				22FC71781730709800153630 /* SBJsonStreamWriterState.m in Sources */,
-				22FC71791730709800153630 /* SBJsonTokeniser.m in Sources */,
-				22FC717A1730709800153630 /* SBJsonUTF8Stream.m in Sources */,
-				22FC717B1730709800153630 /* SBJsonWriter.m in Sources */,
-				22FC717C1730709800153630 /* UGActivity.m in Sources */,
-				22FC717D1730709800153630 /* UGClient.m in Sources */,
-				22FC717E1730709800153630 /* UGClientResponse.m in Sources */,
-				22FC717F1730709800153630 /* UGHTTPManager.m in Sources */,
-				22FC71801730709800153630 /* UGMultiStepAction.m in Sources */,
-				22FC71811730709800153630 /* UGQuery.m in Sources */,
-				22FC71821730709800153630 /* UGUser.m in Sources */,
-				22FC71831730709800153630 /* UGConnection.m in Sources */,
-				22FC71841730709800153630 /* UGHTTPClient.m in Sources */,
-				22FC71851730709800153630 /* UGHTTPHelpers.m in Sources */,
-				22FC71861730709800153630 /* UGHTTPResult.m in Sources */,
-				22FC7189173070DF00153630 /* PartiesViewController.m in Sources */,
-				22FC718C173075D300153630 /* PartyViewController.m in Sources */,
-			);
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-/* End PBXSourcesBuildPhase section */
-
-/* Begin PBXVariantGroup section */
-		22FC71291730705D00153630 /* InfoPlist.strings */ = {
-			isa = PBXVariantGroup;
-			children = (
-				22FC712A1730705D00153630 /* en */,
-			);
-			name = InfoPlist.strings;
-			sourceTree = "<group>";
-		};
-/* End PBXVariantGroup section */
-
-/* Begin XCBuildConfiguration section */
-		22FC71381730705D00153630 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = NO;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				GCC_PREPROCESSOR_DEFINITIONS = (
-					"DEBUG=1",
-					"$(inherited)",
-				);
-				GCC_SYMBOLS_PRIVATE_EXTERN = NO;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				ONLY_ACTIVE_ARCH = YES;
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-			};
-			name = Debug;
-		};
-		22FC71391730705D00153630 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				ALWAYS_SEARCH_USER_PATHS = NO;
-				CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
-				CLANG_CXX_LIBRARY = "libc++";
-				CLANG_ENABLE_OBJC_ARC = YES;
-				CLANG_WARN_CONSTANT_CONVERSION = YES;
-				CLANG_WARN_EMPTY_BODY = YES;
-				CLANG_WARN_ENUM_CONVERSION = YES;
-				CLANG_WARN_INT_CONVERSION = YES;
-				CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
-				"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
-				COPY_PHASE_STRIP = YES;
-				GCC_C_LANGUAGE_STANDARD = gnu99;
-				GCC_WARN_ABOUT_RETURN_TYPE = YES;
-				GCC_WARN_UNINITIALIZED_AUTOS = YES;
-				GCC_WARN_UNUSED_VARIABLE = YES;
-				IPHONEOS_DEPLOYMENT_TARGET = 6.1;
-				OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
-				SDKROOT = iphoneos;
-				TARGETED_DEVICE_FAMILY = "1,2";
-				VALIDATE_PRODUCT = YES;
-			};
-			name = Release;
-		};
-		22FC713B1730705D00153630 /* Debug */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "parties/parties-Prefix.pch";
-				INFOPLIST_FILE = "parties/parties-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Debug;
-		};
-		22FC713C1730705D00153630 /* Release */ = {
-			isa = XCBuildConfiguration;
-			buildSettings = {
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = "parties/parties-Prefix.pch";
-				INFOPLIST_FILE = "parties/parties-Info.plist";
-				PRODUCT_NAME = "$(TARGET_NAME)";
-				WRAPPER_EXTENSION = app;
-			};
-			name = Release;
-		};
-/* End XCBuildConfiguration section */
-
-/* Begin XCConfigurationList section */
-		22FC71181730705D00153630 /* Build configuration list for PBXProject "parties" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				22FC71381730705D00153630 /* Debug */,
-				22FC71391730705D00153630 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-		22FC713A1730705D00153630 /* Build configuration list for PBXNativeTarget "parties" */ = {
-			isa = XCConfigurationList;
-			buildConfigurations = (
-				22FC713B1730705D00153630 /* Debug */,
-				22FC713C1730705D00153630 /* Release */,
-			);
-			defaultConfigurationIsVisible = 0;
-			defaultConfigurationName = Release;
-		};
-/* End XCConfigurationList section */
-	};
-	rootObject = 22FC71151730705D00153630 /* Project object */;
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/AppDelegate.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/AppDelegate.h b/sdks/ios/samples/parties/parties/AppDelegate.h
deleted file mode 100644
index 1bc8193..0000000
--- a/sdks/ios/samples/parties/parties/AppDelegate.h
+++ /dev/null
@@ -1,26 +0,0 @@
-//
-//  AppDelegate.h
-//  parties
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface AppDelegate : UIResponder <UIApplicationDelegate>
-
-@property (strong, nonatomic) UIWindow *window;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/AppDelegate.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/AppDelegate.m b/sdks/ios/samples/parties/parties/AppDelegate.m
deleted file mode 100644
index 0e9103c..0000000
--- a/sdks/ios/samples/parties/parties/AppDelegate.m
+++ /dev/null
@@ -1,73 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  AppDelegate.m
-//  parties
-//
-//  Copyright (c) 2013 Apigee. All rights reserved.
-//
-
-#import "AppDelegate.h"
-#import "PartiesViewController.h"
-
-@implementation AppDelegate
-
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
-{
-    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
-    UINavigationController *navigationController = [[UINavigationController alloc]
-                                                    initWithRootViewController:[[PartiesViewController alloc] init]];
-    navigationController.navigationBar.tintColor = [UIColor colorWithRed:255.0/255.0
-                                                                   green:067.0/255.0
-                                                                    blue:000.0/255.0
-                                                                   alpha:1];
-    self.window.rootViewController = navigationController;
-    self.window.backgroundColor = [UIColor whiteColor];
-    [self.window makeKeyAndVisible];
-
-    return YES;
-}
-
-- (void)applicationWillResignActive:(UIApplication *)application
-{
-    // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
-    // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
-}
-
-- (void)applicationDidEnterBackground:(UIApplication *)application
-{
-    // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. 
-    // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
-}
-
-- (void)applicationWillEnterForeground:(UIApplication *)application
-{
-    // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
-}
-
-- (void)applicationDidBecomeActive:(UIApplication *)application
-{
-    // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
-}
-
-- (void)applicationWillTerminate:(UIApplication *)application
-{
-    // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/Default-568h@2x.png b/sdks/ios/samples/parties/parties/Default-568h@2x.png
deleted file mode 100644
index 0891b7a..0000000
Binary files a/sdks/ios/samples/parties/parties/Default-568h@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/Default.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/Default.png b/sdks/ios/samples/parties/parties/Default.png
deleted file mode 100644
index 4c8ca6f..0000000
Binary files a/sdks/ios/samples/parties/parties/Default.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/Default@2x.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/Default@2x.png b/sdks/ios/samples/parties/parties/Default@2x.png
deleted file mode 100644
index 35b84cf..0000000
Binary files a/sdks/ios/samples/parties/parties/Default@2x.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/Icon.png
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/Icon.png b/sdks/ios/samples/parties/parties/Icon.png
deleted file mode 100644
index ec8b407..0000000
Binary files a/sdks/ios/samples/parties/parties/Icon.png and /dev/null differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/PartiesViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/PartiesViewController.h b/sdks/ios/samples/parties/parties/PartiesViewController.h
deleted file mode 100644
index 2231ca1..0000000
--- a/sdks/ios/samples/parties/parties/PartiesViewController.h
+++ /dev/null
@@ -1,24 +0,0 @@
-//
-//  PartiesViewController.h
-//  parties
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface PartiesViewController : UITableViewController
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/PartiesViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/PartiesViewController.m b/sdks/ios/samples/parties/parties/PartiesViewController.m
deleted file mode 100644
index 5abb2f5..0000000
--- a/sdks/ios/samples/parties/parties/PartiesViewController.m
+++ /dev/null
@@ -1,241 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  PartiesViewController.m
-//  parties
-//
-//  Copyright (c) 2013 Apigee. All rights reserved.
-//
-
-#import "PartiesViewController.h"
-#import "PartyViewController.h"
-
-#import "UGConnection.h"
-#import "UGHTTPClient.h"
-#import "UGHTTPResult.h"
-
-@interface PartiesViewController ()
-@property (nonatomic, strong) NSDictionary *content;
-@property (nonatomic, strong) NSArray *partiesByStartDate;
-@property (nonatomic, strong) NSMutableDictionary *images;
-@end
-
-@implementation PartiesViewController
-
-- (id)initWithStyle:(UITableViewStyle)style
-{
-    self = [super initWithStyle:style];
-    if (self) {
-        self.images = [NSMutableDictionary dictionary];
-    }
-    return self;
-}
-
-- (void) setContent:(NSDictionary *)content
-{
-    _content = content;
-    
-    NSMutableDictionary *partiesByStartDateDictionary = [NSMutableDictionary dictionary];
-    for (NSDictionary *party in self.content[@"entities"]) {
-        NSString *startDate = [party objectForKey:@"startDate"];
-        NSArray *parts = [startDate componentsSeparatedByString:@" "];
-        NSString *datePart = [parts objectAtIndex:0];
-        NSMutableArray *arrayOfParties = [partiesByStartDateDictionary objectForKey:datePart];
-        if (!arrayOfParties) {
-            arrayOfParties = [NSMutableArray array];
-            [partiesByStartDateDictionary setObject:arrayOfParties forKey:datePart];
-        }
-        [arrayOfParties addObject:party];
-    }
-    NSArray *keys = [[partiesByStartDateDictionary allKeys] sortedArrayUsingComparator:^NSComparisonResult(id obj1, id obj2) {
-        return [obj1 compare:obj2];
-    }];
-    NSMutableArray *partiesByStartDate = [NSMutableArray array];
-    for (NSString *key in keys) {
-        [partiesByStartDate addObject:
-         @{@"date":key,
-         @"parties":[partiesByStartDateDictionary objectForKey:key]}];
-    }
-    self.partiesByStartDate = partiesByStartDate;
-    // NSLog(@"%@", self.partiesByStartDate);
-}
-
-- (void) fetchAssetForParty:(NSString *) partyName atIndexPath:(NSIndexPath *) indexPath
-{
-    UGConnection *connection = [UGConnection sharedConnection];
-    if ([connection isAuthenticated]) {
-        NSDictionary *query = [connection queryWithString:
-                               [NSString stringWithFormat:@"select * where path='/assets/%@'", partyName]
-                                                    limit:1
-                                                startUUID:nil
-                                                   cursor:nil
-                                                 reversed:NO];
-        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
-                                [connection getEntitiesInCollection:@"assets"
-                                                         usingQuery:query]];
-        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
-            id entities = [result.object objectForKey:@"entities"];
-            if ([entities count]) {
-                id entity = [entities objectAtIndex:0];
-                NSString *uuid = [entity objectForKey:@"uuid"];
-                UGHTTPClient *assetclient = [[UGHTTPClient alloc] initWithRequest:
-                                             [connection getDataForAsset:uuid]];
-                [assetclient connectWithCompletionHandler:^(UGHTTPResult *result) {
-                    UIImage *image = [UIImage imageWithData:result.data];
-                    [self.images setObject:image forKey:partyName];
-                    [self.tableView reloadRowsAtIndexPaths:[NSArray arrayWithObject:indexPath]
-                                          withRowAnimation:UITableViewRowAnimationNone];
-                }];
-            }
-        }];
-    }
-}
-
-- (void) reload {
-    UGConnection *connection = [UGConnection sharedConnection];
-    if ([connection isAuthenticated]) {
-        NSDictionary *query = [connection queryWithString:@"select * where conference = 'wwdc2013'"
-                                                    limit:1000
-                                                startUUID:nil
-                                                   cursor:nil
-                                                 reversed:NO];
-        UGHTTPClient *client = [[UGHTTPClient alloc] initWithRequest:
-                                [connection getEntitiesInCollection:@"parties"
-                                                         usingQuery:query]];
-        [client connectWithCompletionHandler:^(UGHTTPResult *result) {
-            self.content = result.object;
-            NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
-            [defaults setObject:result.object forKey:@"parties"];
-            [defaults synchronize];
-            [self.tableView reloadData];
-        }];
-    }
-}
-
-- (void) authenticate {
-    UGConnection *connection = [UGConnection sharedConnection];
-    if (![connection isAuthenticated]) {
-        [[[UGHTTPClient alloc] initWithRequest:
-          [connection getAccessTokenForApplicationWithUsername:@"radtastical"
-                                                      password:@"partyrock2013"]]
-         connectWithCompletionHandler:^(UGHTTPResult *result) {
-             [connection authenticateWithResult:result];
-             if ([connection isAuthenticated]) {
-                 if (self.content) {
-                     // trigger photo loads
-                     [self.tableView reloadData];
-                 } else {
-                     // load all party information
-                     [self reload];
-                 }
-             }
-         }];
-    }
-}
-
-- (void)loadView
-{
-    [super loadView];
-    self.navigationItem.title = @"Parties";
-    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
-                                             initWithBarButtonSystemItem:UIBarButtonSystemItemRefresh
-                                             target:self
-                                             action:@selector(reload)];
-    self.tableView.rowHeight = 100;
-    
-    NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
-    NSDictionary *parties = [defaults objectForKey:@"parties"];
-    if (parties) {
-        self.content = parties;
-    }
-    UGConnection *connection = [UGConnection sharedConnection];
-    connection.server = @"https://api.usergrid.com";
-    connection.organization = @"macmoe";
-    connection.application = @"partyapi";
-    [self authenticate];
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return [self.partiesByStartDate count];
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    if (self.content) {
-        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:section];
-        NSArray *parties = [sectionInfo objectForKey:@"parties"];
-        return [parties count];
-    } else {
-        return 0;
-    }
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    return [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
-}
-
-#pragma mark - Table view delegate
-
-- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (self.content) {
-        
-        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:[indexPath section]];
-        NSArray *parties = [sectionInfo objectForKey:@"parties"];
-        
-        id entity = parties[[indexPath row]];
-        cell.textLabel.text = entity[@"title"];
-        cell.textLabel.numberOfLines = 0;
-        cell.detailTextLabel.text = [NSString stringWithFormat:@"%@ %@", entity[@"venue"], entity[@"partytime"]];
-        cell.detailTextLabel.numberOfLines = 0;
-        
-        NSString *partyName = [entity objectForKey:@"name"];
-        UIImage *image = [self.images objectForKey:partyName];
-        if (image) {
-            cell.imageView.image = image;
-        } else {
-            cell.imageView.image = nil;
-            [self fetchAssetForParty:[entity objectForKey:@"name"] atIndexPath:indexPath];
-        }
-    }
-    cell.selectionStyle = UITableViewCellSelectionStyleNone;
-}
-
-- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (self.content) {
-        NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:[indexPath section]];
-        NSArray *parties = [sectionInfo objectForKey:@"parties"];
-        id entity = [parties objectAtIndex:[indexPath row]];
-        PartyViewController *partyViewController = [[PartyViewController alloc] init];
-        partyViewController.content = entity;
-        [self.navigationController pushViewController:partyViewController animated:YES];
-    }
-}
-
-- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
-{
-    NSDictionary *sectionInfo = [self.partiesByStartDate objectAtIndex:section];
-    return [sectionInfo objectForKey:@"date"];
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/PartyViewController.h
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/PartyViewController.h b/sdks/ios/samples/parties/parties/PartyViewController.h
deleted file mode 100644
index 100c4c9..0000000
--- a/sdks/ios/samples/parties/parties/PartyViewController.h
+++ /dev/null
@@ -1,24 +0,0 @@
-//
-//  PartyViewController.h
-//  parties
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-
-#import <UIKit/UIKit.h>
-
-@interface PartyViewController : UITableViewController
-@property (nonatomic, strong) NSDictionary *content;
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/PartyViewController.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/PartyViewController.m b/sdks/ios/samples/parties/parties/PartyViewController.m
deleted file mode 100644
index dfedfce..0000000
--- a/sdks/ios/samples/parties/parties/PartyViewController.m
+++ /dev/null
@@ -1,166 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  PartyViewController.m
-//  parties
-//
-//  Copyright (c) 2013 Apigee. All rights reserved.
-//
-
-#import "PartyViewController.h"
-
-@interface PartyViewController ()
-
-@property (nonatomic, strong) UITableViewCell *mapCell;
-
-@end
-
-@implementation PartyViewController
-
-- (void)didReceiveMemoryWarning
-{
-    [super didReceiveMemoryWarning];
-}
-
-- (void) viewWillAppear:(BOOL)animated
-{
-    self.navigationItem.title = [self.content objectForKey:@"title"];
-}
-
-UIFont *font_with_size(CGFloat size) {
-    return [UIFont fontWithName:@"Helvetica-Bold" size:size];
-}
-
-NSAttributedString *carriage_return(CGFloat size) {
-    return [[NSAttributedString alloc] initWithString:[NSString stringWithFormat:@"\n"]
-                                           attributes:@{NSFontAttributeName:font_with_size(size)}];
-}
-
-NSMutableAttributedString *attributed_string(NSString *string, CGFloat size) {
-    return [[NSMutableAttributedString alloc] initWithString:string
-                                                  attributes:@{NSFontAttributeName:font_with_size(size)}];
-}
-
-- (NSMutableAttributedString *) attributedStringForIndexPath:(NSIndexPath *) indexPath
-{
-    if (([indexPath section] == 0) && ([indexPath row] == 1)) {
-        NSMutableAttributedString *attributedString = attributed_string([self.content objectForKey:@"title"], 30);
-        [attributedString appendAttributedString:carriage_return(18)];
-        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"venue"], 24)];
-        [attributedString appendAttributedString:carriage_return(24)];
-        
-        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"startDate"], 18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        
-        id address = [self.content objectForKey:@"address"];
-        [attributedString appendAttributedString:attributed_string([address objectForKey:@"street"], 18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        [attributedString appendAttributedString:attributed_string([address objectForKey:@"city"], 18)];
-        [attributedString appendAttributedString:attributed_string(@", ", 18)];
-        [attributedString appendAttributedString:attributed_string([address objectForKey:@"state"], 18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        
-        [attributedString appendAttributedString:attributed_string([self.content objectForKey:@"description"], 18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        [attributedString appendAttributedString:carriage_return(18)];
-        
-        return attributedString;
-    } else if (([indexPath section] == 1) && ([indexPath row] == 0)) {
-        NSMutableAttributedString *attributedString = attributed_string([self.content description], 12);
-        [attributedString appendAttributedString:carriage_return(12)];
-        return attributedString;
-    } else {
-        return nil;
-    }
-}
-
-#pragma mark - Table view data source
-
-- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
-{
-    return 2;
-}
-
-- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
-{
-    return (section == 0) ? 2 : 1;
-}
-
-- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (([indexPath section] == 0) && ([indexPath row] == 0)) {
-        if (!self.mapCell) {
-            self.mapCell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Map"];
-            MKMapView *mapView = [[MKMapView alloc] initWithFrame:self.mapCell.bounds];
-            mapView.autoresizingMask = UIViewAutoresizingFlexibleWidth + UIViewAutoresizingFlexibleHeight;
-            [self.mapCell addSubview:mapView];
-            id location = [self.content objectForKey:@"location"];
-            double lat = [[location objectForKey:@"latitude"] floatValue];
-            double lng = [[location objectForKey:@"longitude"] floatValue];
-            [mapView setRegion:MKCoordinateRegionMake(CLLocationCoordinate2DMake(lat,lng),
-                                                      MKCoordinateSpanMake(0.002,0.002))];
-            CLLocationCoordinate2D annotationCoord;
-            annotationCoord.latitude = lat;
-            annotationCoord.longitude = lng;
-            MKPointAnnotation *annotationPoint = [[MKPointAnnotation alloc] init];
-            annotationPoint.coordinate = annotationCoord;
-            annotationPoint.title = [self.content objectForKey:@"title"];
-            annotationPoint.subtitle = [self.content objectForKey:@"venue"];
-            [mapView addAnnotation:annotationPoint];
-            mapView.scrollEnabled = NO;
-            mapView.zoomEnabled = NO;
-        }
-        return self.mapCell;
-    } else {
-        UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault
-                                                       reuseIdentifier:@"Cell"];
-        cell.selectionStyle = UITableViewCellSelectionStyleNone;
-        cell.textLabel.attributedText = [self attributedStringForIndexPath:indexPath];
-        cell.textLabel.numberOfLines = 0;
-        return cell;
-    }
-}
-
-- (CGFloat) tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
-{
-    if (([indexPath section] == 0) && ([indexPath row] == 0)) {
-        return 200;
-    } else {
-        CGFloat w = tableView.bounds.size.width - 20; // use approximate margins
-        CGFloat h = 0;
-        NSMutableAttributedString *attributedString = [self attributedStringForIndexPath:indexPath];
-        CGRect bounds = [attributedString boundingRectWithSize:CGSizeMake(w,h)
-                                                       options:NSStringDrawingUsesFontLeading+NSStringDrawingUsesLineFragmentOrigin
-                                                       context:nil];
-        return bounds.size.height;
-    }
-}
-
-- (NSString *) tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section
-{
-    if (section == 0) {
-        return nil;
-    } else if (section == 1) {
-        return @"Party Entity Details";
-    }
-    return nil;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/en.lproj/InfoPlist.strings b/sdks/ios/samples/parties/parties/en.lproj/InfoPlist.strings
deleted file mode 100644
index 477b28f..0000000
--- a/sdks/ios/samples/parties/parties/en.lproj/InfoPlist.strings
+++ /dev/null
@@ -1,2 +0,0 @@
-/* Localized versions of Info.plist keys */
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/main.m
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/main.m b/sdks/ios/samples/parties/parties/main.m
deleted file mode 100644
index 516a18a..0000000
--- a/sdks/ios/samples/parties/parties/main.m
+++ /dev/null
@@ -1,35 +0,0 @@
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-//
-//  main.m
-//  parties
-//
-//  Created by Tim Burks on 4/30/13.
-//  Copyright (c) 2013 Apigee. All rights reserved.
-//
-
-#import <UIKit/UIKit.h>
-
-#import "AppDelegate.h"
-
-int main(int argc, char *argv[])
-{
-    @autoreleasepool {
-        return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/parties-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/parties-Info.plist b/sdks/ios/samples/parties/parties/parties-Info.plist
deleted file mode 100644
index f394f12..0000000
--- a/sdks/ios/samples/parties/parties/parties-Info.plist
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- 
-//
-// Licensed to the Apache Software Foundation (ASF) under one or more
-// contributor license agreements.  See the NOTICE file distributed with
-// this work for additional information regarding copyright ownership.
-// The ASF licenses this file to You under the Apache License, Version 2.0
-// (the "License"); you may not use this file except in compliance with
-// the License.  You may obtain a copy of the License at
-//
-//     http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
--->
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>en</string>
-	<key>CFBundleDisplayName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundleExecutable</key>
-	<string>${EXECUTABLE_NAME}</string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundleName</key>
-	<string>${PRODUCT_NAME}</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleShortVersionString</key>
-	<string>1.0</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>1.0</string>
-	<key>LSRequiresIPhoneOS</key>
-	<true/>
-	<key>UIRequiredDeviceCapabilities</key>
-	<array>
-		<string>armv7</string>
-	</array>
-	<key>UISupportedInterfaceOrientations</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-	<key>UISupportedInterfaceOrientations~ipad</key>
-	<array>
-		<string>UIInterfaceOrientationPortrait</string>
-		<string>UIInterfaceOrientationPortraitUpsideDown</string>
-		<string>UIInterfaceOrientationLandscapeLeft</string>
-		<string>UIInterfaceOrientationLandscapeRight</string>
-	</array>
-</dict>
-</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/samples/parties/parties/parties-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/ios/samples/parties/parties/parties-Prefix.pch b/sdks/ios/samples/parties/parties/parties-Prefix.pch
deleted file mode 100644
index 96b4d23..0000000
--- a/sdks/ios/samples/parties/parties/parties-Prefix.pch
+++ /dev/null
@@ -1,15 +0,0 @@
-//
-// Prefix header for all source files of the 'parties' target in the 'parties' project
-//
-
-#import <Availability.h>
-
-#ifndef __IPHONE_3_0
-#warning "This project uses features only available in iOS SDK 3.0 and later."
-#endif
-
-#ifdef __OBJC__
-    #import <UIKit/UIKit.h>
-    #import <Foundation/Foundation.h>
-    #import <MapKit/MapKit.h>
-#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/test/test_client.nu
----------------------------------------------------------------------
diff --git a/sdks/ios/test/test_client.nu b/sdks/ios/test/test_client.nu
deleted file mode 100644
index 96fbd85..0000000
--- a/sdks/ios/test/test_client.nu
+++ /dev/null
@@ -1,50 +0,0 @@
-;;
-;; Licensed to the Apache Software Foundation (ASF) under one or more
-;; contributor license agreements.  See the NOTICE file distributed with
-;; this work for additional information regarding copyright ownership.
-;; The ASF licenses this file to You under the Apache License, Version 2.0
-;; (the "License"); you may not use this file except in compliance with
-;; the License.  You may obtain a copy of the License at
-;;
-;;     http://www.apache.org/licenses/LICENSE-2.0
-;;
-;; Unless required by applicable law or agreed to in writing, software
-;; distributed under the License is distributed on an "AS IS" BASIS,
-;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-;; See the License for the specific language governing permissions and
-;; limitations under the License.
-;;
-
-;; test_client.nu
-;;  Simple tests for Usergrid Client class.
-;;
-(load "Usergrid")
-
-(class TestClient is NuTestCase
- 
- (- testClientSigninAndGetUsers is
-    ;; create a client
-    (set client ((UGClient alloc) initWithOrganizationId:"1hotrod" withApplicationID:"fred"))
-    ;; sign in a test user
-    (set response (client logInUser:"alice" password:"test1test"))
-    (assert_equal 0 (response transactionState))
-    (set object ((response rawResponse) JSONValue))
-    (assert_true (object access_token:))
-    (assert_true (object expires_in:))
-    (set user (object user:))
-    (assert_true (user activated:))
-    (assert_equal "alice" (user name:))
-    (assert_equal "test1test" (user validate-password:))
-    ;; query for users
-    (set query (UGQuery new))
-    (set response (client getUsers:query))
-    (assert_equal 0 (response transactionState))
-    (set object ((response rawResponse) JSONValue))
-    (assert_equal "fred" (object applicationName:))
-    (assert_equal "get" (object action:))
-    (set entities (object entities:))
-    (assert_equal (object count:) (entities count)))
-
- (- testSemVerOfClient is
-    ;; create a client
-    (assert_equal "0.1.1" (UGClient version))))

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/test/test_connection.nu
----------------------------------------------------------------------
diff --git a/sdks/ios/test/test_connection.nu b/sdks/ios/test/test_connection.nu
deleted file mode 100644
index 3d0e2e5..0000000
--- a/sdks/ios/test/test_connection.nu
+++ /dev/null
@@ -1,119 +0,0 @@
-;;
-;; Licensed to the Apache Software Foundation (ASF) under one or more
-;; contributor license agreements.  See the NOTICE file distributed with
-;; this work for additional information regarding copyright ownership.
-;; The ASF licenses this file to You under the Apache License, Version 2.0
-;; (the "License"); you may not use this file except in compliance with
-;; the License.  You may obtain a copy of the License at
-;;
-;;     http://www.apache.org/licenses/LICENSE-2.0
-;;
-;; Unless required by applicable law or agreed to in writing, software
-;; distributed under the License is distributed on an "AS IS" BASIS,
-;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-;; See the License for the specific language governing permissions and
-;; limitations under the License.
-;;
-
-;; test_connection.nu
-;;  Simple tests for Usergrid Connection class.
-;;
-(load "Usergrid")
-
-(set ORGANIZATION     "timburks")
-(set APPLICATION      "unittest")
-(set APPLICATION_UUID "6a87cc36-a328-11e2-836c-02e81af253c0")
-(set CLIENT_ID        "YXA6aofMNqMoEeKDbALoGvJTwA")
-(set CLIENT_SECRET    "YXA6oEdSD8zQyKxBKv_3xxZgvISM8C4")
-
-(function perform (request)
-          (set client ((UGHTTPClient alloc) initWithRequest:request))
-          (set result (client connect))
-          result)
-
-(class TestConnection is NuTestCase
- ;; run this before every test
- (- setup is
-    (set usergrid (UGConnection sharedConnection))
-    (usergrid setOrganization:ORGANIZATION)
-    (usergrid setApplication:APPLICATION))
- 
- (- testClientSignin is
-    (set usergrid (UGConnection sharedConnection))
-    ;; log in
-    (set request (usergrid getAccessTokenForApplicationWithClientID:CLIENT_ID
-                                                       clientSecret:CLIENT_SECRET))
-    (set result (perform request))
-    (set object (result object))
-    (assert_true (object access_token:))
-    ;; capture token
-    (usergrid authenticateWithResult:result)
-    (assert_true (usergrid isAuthenticated)))
- 
- (- testUserSignin is
-    (set usergrid (UGConnection sharedConnection))
-    ;; log in
-    (set request (usergrid getAccessTokenForApplicationWithUsername:"test1"
-                                                           password:"test1"))
-    (set result (perform request))
-    (set object (result object))
-    (assert_true (object access_token:))
-    ;; capture token
-    (usergrid authenticateWithResult:result)
-    (assert_true (usergrid isAuthenticated)))
- 
- (- testApplicationDetail is
-    (set usergrid (UGConnection sharedConnection))
-    ;; log in
-    (set request (usergrid getAccessTokenForApplicationWithUsername:"test2"
-                                                           password:"test2"))
-    (set result (perform request))
-    (usergrid authenticateWithResult:result)
-    ;; get application description
-    (set request (usergrid getApplication:APPLICATION inOrganization:ORGANIZATION))
-    (set result (perform request))
-    (set object (result object))
-    (assert_equal APPLICATION (object applicationName:))
-    (assert_equal ORGANIZATION (object organization:))
-    (assert_equal 1 ((object entities:) count))
-    (set collections ((((object entities:) 0) metadata:) collections:))
-    (assert_equal 8 (collections count)))
- 
- (- testAssets is
-    (set usergrid (UGConnection sharedConnection))
-    ;; log in
-    (usergrid authenticateWithResult:(perform (usergrid getAccessTokenForApplicationWithUsername:"test1" password:"test1")))
-    
-    ;; delete all assets
-    (perform (usergrid deleteEntitiesInCollection:"assets"))
-    (set results (perform (usergrid getEntitiesInCollection:"assets" limit:10)))
-    (set object (results object))
-    (assert_equal 0 (object count:))
-    
-    ;; add some assets
-    (set N 2)
-    (N times:
-       (do (i)
-           (set results (perform (usergrid createEntityInCollection:"assets" withValues:(dict name:"asset-#{i}"
-                                                                                            number:i
-                                                                                             owner:APPLICATION_UUID
-                                                                                              path:"asset-#{i}"))))
-           (set object (results object))
-           (set uuid (((object entities:) 0) uuid:))
-           (set results (perform (usergrid postData:("asset-#{i}" dataUsingEncoding:NSUTF8StringEncoding)
-                                           forAsset:uuid)))))
-    (set results (perform (usergrid getEntitiesInCollection:"assets" limit:10)))
-    (set object (results object))
-    (assert_equal N (object count:))
-    ((object entities:) eachWithIndex:
-     (do (asset i)
-         (set uuid (asset uuid:))
-         (set results (perform (usergrid getDataForAsset:uuid)))
-         (set asset-string (NSString stringWithData:(results data) encoding:NSUTF8StringEncoding))
-         (assert_equal i (asset number:))
-         (assert_equal (asset owner:) APPLICATION_UUID)
-         (assert_equal (asset path:) asset-string)
-         (assert_equal (asset name:) asset-string)))))
-
-
-

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/README.md b/sdks/other/README.md
new file mode 100644
index 0000000..5ed729a
--- /dev/null
+++ b/sdks/other/README.md
@@ -0,0 +1,5 @@
+# Other SDKs
+
+The SDKs located here are either older versions for a platform such as iOS vs. the new Swift SDK
+or they were previously built for Usergrid 1.x version and have not been tested against 
+Usergrid 2.x.
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/other/ios/.gitignore b/sdks/other/ios/.gitignore
new file mode 100644
index 0000000..283c6e9
--- /dev/null
+++ b/sdks/other/ios/.gitignore
@@ -0,0 +1,9 @@
+.DS_Store
+*.swp
+*~.nib
+
+build/
+
+.xcodeproj/!*.xcodeproj/project.pbxproj
+UGAPIApp.xcodeproj/xcuserdata/*
+UGAPIApp.xcodeproj/project.xcworkspace/xcuserdata/*

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/.travis.yml
----------------------------------------------------------------------
diff --git a/sdks/other/ios/.travis.yml b/sdks/other/ios/.travis.yml
new file mode 100644
index 0000000..3a6a437
--- /dev/null
+++ b/sdks/other/ios/.travis.yml
@@ -0,0 +1,7 @@
+language: objective-c
+before_script:
+ - mkdir tmp
+ - cd tmp; git clone git://github.com/timburks/nu.git
+ - cd nu; make; ./mininush tools/nuke install
+ - cd ../..
+script: nuke test

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/Default-568h@2x.png
----------------------------------------------------------------------
diff --git a/sdks/other/ios/Default-568h@2x.png b/sdks/other/ios/Default-568h@2x.png
new file mode 100644
index 0000000..0891b7a
Binary files /dev/null and b/sdks/other/ios/Default-568h@2x.png differ

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/other/ios/LICENSE b/sdks/other/ios/LICENSE
new file mode 100644
index 0000000..e06d208
--- /dev/null
+++ b/sdks/other/ios/LICENSE
@@ -0,0 +1,202 @@
+Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "{}"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright {yyyy} {name of copyright owner}
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+


[43/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.m b/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
deleted file mode 100755
index f57015d..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonUTF8Stream.m
+++ /dev/null
@@ -1,141 +0,0 @@
-/*
- Copyright (c) 2011, Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are
- met:
- 
- Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
- 
- Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
- 
- Neither the name of the the author nor the names of its contributors
- may be used to endorse or promote products derived from this software
- without specific prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
- IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonUTF8Stream.h"
-
-
-@implementation SBJsonUTF8Stream
-
-@synthesize index = _index;
-
-- (id)init {
-    self = [super init];
-    if (self) {
-        _data = [[NSMutableData alloc] initWithCapacity:4096u];
-    }
-    return self;
-}
-
-
-- (void)appendData:(NSData *)data_ {
-    
-    if (_index) {
-        // Discard data we've already parsed
-		[_data replaceBytesInRange:NSMakeRange(0, _index) withBytes:"" length:0];
-        
-        // Reset index to point to current position
-		_index = 0;
-	}
-    
-    [_data appendData:data_];
-    
-    // This is an optimisation. 
-    _bytes = (const char*)[_data bytes];
-    _length = [_data length];
-}
-
-
-- (BOOL)getUnichar:(unichar*)ch {
-    if (_index < _length) {
-        *ch = (unichar)_bytes[_index];
-        return YES;
-    }
-    return NO;
-}
-
-- (BOOL)getNextUnichar:(unichar*)ch {
-    if (++_index < _length) {
-        *ch = (unichar)_bytes[_index];
-        return YES;
-    }
-    return NO;
-}
-
-- (BOOL)getStringFragment:(NSString **)string {
-    NSUInteger start = _index;
-    while (_index < _length) {
-        switch (_bytes[_index]) {
-            case '"':
-            case '\\':
-            case 0 ... 0x1f:
-                *string = [[NSString alloc] initWithBytes:(_bytes + start)
-                                                   length:(_index - start)
-                                                 encoding:NSUTF8StringEncoding];
-                return YES;
-                break;
-            default:
-                _index++;
-                break;
-        }
-    }
-    return NO;
-}
-
-- (void)skip {
-    _index++;
-}
-
-- (void)skipWhitespace {
-    while (_index < _length) {
-        switch (_bytes[_index]) {
-            case ' ':
-            case '\t':
-            case '\r':
-            case '\n':
-                _index++;
-                break;
-            default:
-                return;
-                break;
-        }
-    }
-}
-
-- (BOOL)haveRemainingCharacters:(NSUInteger)chars {
-    return [_data length] - _index >= chars;
-}
-
-- (BOOL)skipCharacters:(const char *)chars length:(NSUInteger)len {
-    const void *bytes = ((const char*)[_data bytes]) + _index;
-    if (!memcmp(bytes, chars, len)) {
-        _index += len;
-        return YES;
-    }
-    return NO;
-}
-
-- (NSString*)stringWithRange:(NSRange)range {
-    return [[NSString alloc] initWithBytes:_bytes + range.location length:range.length encoding:NSUTF8StringEncoding];
-    
-}
-
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonWriter.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonWriter.h b/sdks/ios/UGAPI/SBJson/SBJsonWriter.h
deleted file mode 100755
index 640816c..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonWriter.h
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- Copyright (C) 2009 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import <Foundation/Foundation.h>
-
-/**
- @brief The JSON writer class.
- 
- This uses SBJsonStreamWriter internally.
- 
- @see @ref json2objc
- */
-
-@interface SBJsonWriter : NSObject
-
-/**
- @brief The maximum recursing depth.
- 
- Defaults to 32. If the input is nested deeper than this the input will be deemed to be
- malicious and the parser returns nil, signalling an error. ("Nested too deep".) You can
- turn off this security feature by setting the maxDepth value to 0.
- */
-@property NSUInteger maxDepth;
-
-/**
- @brief Return an error trace, or nil if there was no errors.
- 
- Note that this method returns the trace of the last method that failed.
- You need to check the return value of the call you're making to figure out
- if the call actually failed, before you know call this method.
- */
-@property (readonly, copy) NSString *error;
-
-/**
- @brief Whether we are generating human-readable (multiline) JSON.
- 
- Set whether or not to generate human-readable JSON. The default is NO, which produces
- JSON without any whitespace. (Except inside strings.) If set to YES, generates human-readable
- JSON with linebreaks after each array value and dictionary key/value pair, indented two
- spaces per nesting level.
- */
-@property BOOL humanReadable;
-
-/**
- @brief Whether or not to sort the dictionary keys in the output.
- 
- If this is set to YES, the dictionary keys in the JSON output will be in sorted order.
- (This is useful if you need to compare two structures, for example.) The default is NO.
- */
-@property BOOL sortKeys;
-
-/**
- @brief An optional comparator to be used if sortKeys is YES.
- 
- If this is nil, sorting will be done via @selector(compare:).
- */
-@property (copy) NSComparator sortKeysComparator;
-
-/**
- @brief Return JSON representation for the given object.
- 
- Returns a string containing JSON representation of the passed in value, or nil on error.
- If nil is returned and @p error is not NULL, @p *error can be interrogated to find the cause of the error.
- 
- @param value any instance that can be represented as JSON text.
- */
-- (NSString*)stringWithObject:(id)value;
-
-/**
- @brief Return JSON representation for the given object.
- 
- Returns an NSData object containing JSON represented as UTF8 text, or nil on error.
- 
- @param value any instance that can be represented as JSON text.
- */
-- (NSData*)dataWithObject:(id)value;
-
-/**
- @brief Return JSON representation (or fragment) for the given object.
- 
- Returns a string containing JSON representation of the passed in value, or nil on error.
- If nil is returned and @p error is not NULL, @p *error can be interrogated to find the cause of the error.
- 
- @param value any instance that can be represented as a JSON fragment
- @param error pointer to object to be populated with NSError on failure
- 
- */- (NSString*)stringWithObject:(id)value
-                           error:(NSError**)error;
-
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SBJson/SBJsonWriter.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SBJson/SBJsonWriter.m b/sdks/ios/UGAPI/SBJson/SBJsonWriter.m
deleted file mode 100755
index d200f9c..0000000
--- a/sdks/ios/UGAPI/SBJson/SBJsonWriter.m
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- Copyright (C) 2009 Stig Brautaset. All rights reserved.
- 
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
- 
- * Redistributions of source code must retain the above copyright notice, this
-   list of conditions and the following disclaimer.
- 
- * Redistributions in binary form must reproduce the above copyright notice,
-   this list of conditions and the following disclaimer in the documentation
-   and/or other materials provided with the distribution.
- 
- * Neither the name of the author nor the names of its contributors may be used
-   to endorse or promote products derived from this software without specific
-   prior written permission.
- 
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#import "SBJsonWriter.h"
-#import "SBJsonStreamWriter.h"
-#import "SBJsonStreamWriterAccumulator.h"
-
-
-@interface SBJsonWriter ()
-@property (copy) NSString *error;
-@end
-
-@implementation SBJsonWriter
-
-@synthesize sortKeys;
-@synthesize humanReadable;
-
-@synthesize error;
-@synthesize maxDepth;
-
-@synthesize sortKeysComparator;
-
-- (id)init {
-    self = [super init];
-    if (self) {
-        self.maxDepth = 32u;        
-    }
-    return self;
-}
-
-
-- (NSString*)stringWithObject:(id)value {
-	NSData *data = [self dataWithObject:value];
-	if (data)
-		return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
-	return nil;
-}	
-
-- (NSString*)stringWithObject:(id)value error:(NSError**)error_ {
-    NSString *tmp = [self stringWithObject:value];
-    if (tmp)
-        return tmp;
-    
-    if (error_) {
-		NSDictionary *ui = [NSDictionary dictionaryWithObjectsAndKeys:error, NSLocalizedDescriptionKey, nil];
-        *error_ = [NSError errorWithDomain:@"org.brautaset.SBJsonWriter.ErrorDomain" code:0 userInfo:ui];
-	}
-	
-    return nil;
-}
-
-- (NSData*)dataWithObject:(id)object {	
-    self.error = nil;
-
-    SBJsonStreamWriterAccumulator *accumulator = [[SBJsonStreamWriterAccumulator alloc] init];
-    
-	SBJsonStreamWriter *streamWriter = [[SBJsonStreamWriter alloc] init];
-	streamWriter.sortKeys = self.sortKeys;
-	streamWriter.maxDepth = self.maxDepth;
-	streamWriter.sortKeysComparator = self.sortKeysComparator;
-	streamWriter.humanReadable = self.humanReadable;
-    streamWriter.delegate = accumulator;
-	
-	BOOL ok = NO;
-	if ([object isKindOfClass:[NSDictionary class]])
-		ok = [streamWriter writeObject:object];
-	
-	else if ([object isKindOfClass:[NSArray class]])
-		ok = [streamWriter writeArray:object];
-		
-	else if ([object respondsToSelector:@selector(proxyForJson)])
-		return [self dataWithObject:[object proxyForJson]];
-	else {
-		self.error = @"Not valid type for JSON";
-		return nil;
-	}
-	
-	if (ok)
-		return accumulator.data;
-	
-	self.error = streamWriter.error;
-	return nil;	
-}
-	
-	
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SSKeychain.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SSKeychain.h b/sdks/ios/UGAPI/SSKeychain.h
deleted file mode 100644
index 23093b6..0000000
--- a/sdks/ios/UGAPI/SSKeychain.h
+++ /dev/null
@@ -1,357 +0,0 @@
-//
-//  SSKeychain.h
-//  SSToolkit
-//
-//  Created by Sam Soffes on 5/19/10.
-//  Copyright (c) 2009-2011 Sam Soffes. All rights reserved.
-//
-
-#import <Foundation/Foundation.h>
-#import <Security/Security.h>
-
-/** Error codes that can be returned in NSError objects. */
-typedef enum {
-	/** No error. */
-	SSKeychainErrorNone = noErr,
-	
-	/** Some of the arguments were invalid. */
-	SSKeychainErrorBadArguments = -1001,
-	
-	/** There was no password. */
-	SSKeychainErrorNoPassword = -1002,
-	
-	/** One or more parameters passed internally were not valid. */
-	SSKeychainErrorInvalidParameter = errSecParam,
-	
-	/** Failed to allocate memory. */
-	SSKeychainErrorFailedToAllocated = errSecAllocate,
-	
-	/** No trust results are available. */
-	SSKeychainErrorNotAvailable = errSecNotAvailable,
-	
-	/** Authorization/Authentication failed. */
-	SSKeychainErrorAuthorizationFailed = errSecAuthFailed,
-	
-	/** The item already exists. */
-	SSKeychainErrorDuplicatedItem = errSecDuplicateItem,
-	
-	/** The item cannot be found.*/
-	SSKeychainErrorNotFound = errSecItemNotFound,
-	
-	/** Interaction with the Security Server is not allowed. */
-	SSKeychainErrorInteractionNotAllowed = errSecInteractionNotAllowed,
-	
-	/** Unable to decode the provided data. */
-	SSKeychainErrorFailedToDecode = errSecDecode
-} SSKeychainErrorCode;
-
-extern NSString *const kSSKeychainErrorDomain;
-
-/** Account name. */
-extern NSString *const kSSKeychainAccountKey;
-
-/**
- Time the item was created.
- 
- The value will be a string.
- */
-extern NSString *const kSSKeychainCreatedAtKey;
-
-/** Item class. */
-extern NSString *const kSSKeychainClassKey;
-
-/** Item description. */
-extern NSString *const kSSKeychainDescriptionKey;
-
-/** Item label. */
-extern NSString *const kSSKeychainLabelKey;
-
-/** Time the item was last modified.
- 
- The value will be a string.
- */
-extern NSString *const kSSKeychainLastModifiedKey;
-
-/** Where the item was created. */
-extern NSString *const kSSKeychainWhereKey;
-
-/**
- Simple wrapper for accessing accounts, getting passwords, setting passwords, and deleting passwords using the system
- Keychain on Mac OS X and iOS.
- 
- This was originally inspired by EMKeychain and SDKeychain (both of which are now gone). Thanks to the authors.
- SSKeychain has since switched to a simpler implementation that was abstracted from [SSToolkit](http://sstoolk.it).
- */
-@interface SSKeychain : NSObject
-
-///-----------------------
-/// @name Getting Accounts
-///-----------------------
-
-/**
- Returns an array containing the Keychain's accounts, or `nil` if the Keychain has no accounts.
- 
- See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
- dictionaries returned by this method.
- 
- @return An array of dictionaries containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
- accounts. The order of the objects in the array isn't defined.
- 
- @see allAccounts:
- */
-+ (NSArray *)allAccounts;
-
-/**
- Returns an array containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
- accounts.
- 
- See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
- dictionaries returned by this method.
- 
- @param error If accessing the accounts fails, upon return contains an error that describes the problem.
- 
- @return An array of dictionaries containing the Keychain's accounts, or `nil` if the Keychain doesn't have any
- accounts. The order of the objects in the array isn't defined.
- 
- @see allAccounts
- */
-+ (NSArray *)allAccounts:(NSError **)error;
-
-/**
- Returns an array containing the Keychain's accounts for a given service, or `nil` if the Keychain doesn't have any
- accounts for the given service.
- 
- See the `NSString` constants declared in SSKeychain.h for a list of keys that can be used when accessing the
- dictionaries returned by this method.
- 
- @param serviceName The service for which to return the corresponding accounts.
- 
- @return An array of dictionaries containing the Keychain's accountsfor a given `serviceName`, or `nil` if the Keychain
- doesn't have any accounts for the given `serviceName`. The order of the objects in the array isn't defined.
- 
- @see accountsForService:error:
- */
-+ (NSArray *)accountsForService:(NSString *)serviceName;
-
-/**
- Returns an array containing the Keychain's accounts for a given service, or `nil` if the Keychain doesn't have any
- accounts for the given service.
- 
- @param serviceName The service for which to return the corresponding accounts.
- 
- @param error If accessing the accounts fails, upon return contains an error that describes the problem.
- 
- @return An array of dictionaries containing the Keychain's accountsfor a given `serviceName`, or `nil` if the Keychain
- doesn't have any accounts for the given `serviceName`. The order of the objects in the array isn't defined.
- 
- @see accountsForService:
- */
-+ (NSArray *)accountsForService:(NSString *)serviceName error:(NSError **)error;
-
-
-///------------------------
-/// @name Getting Passwords
-///------------------------
-
-/**
- Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't have a
- password for the given parameters.
- 
- @param serviceName The service for which to return the corresponding password.
- 
- @param account The account for which to return the corresponding password.
- 
- @return Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't
- have a password for the given parameters.
- 
- @see passwordForService:account:error:
- */
-+ (NSString *)passwordForService:(NSString *)serviceName account:(NSString *)account;
-
-/**
- Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't have a
- password for the given parameters.
- 
- @param serviceName The service for which to return the corresponding password.
- 
- @param account The account for which to return the corresponding password.
- 
- @param error If accessing the password fails, upon return contains an error that describes the problem.
- 
- @return Returns a string containing the password for a given account and service, or `nil` if the Keychain doesn't
- have a password for the given parameters.
- 
- @see passwordForService:account:
- */
-+ (NSString *)passwordForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
-
-/**
- Returns the password data for a given account and service, or `nil` if the Keychain doesn't have data
- for the given parameters.
- 
- @param serviceName The service for which to return the corresponding password.
- 
- @param account The account for which to return the corresponding password.
- 
- @param error If accessing the password fails, upon return contains an error that describes the problem.
- 
- @return Returns a the password data for the given account and service, or `nil` if the Keychain doesn't
- have data for the given parameters.
- 
- @see passwordDataForService:account:error:
- */
-+ (NSData *)passwordDataForService:(NSString *)serviceName account:(NSString *)account;
-
-/**
- Returns the password data for a given account and service, or `nil` if the Keychain doesn't have data
- for the given parameters.
- 
- @param serviceName The service for which to return the corresponding password.
- 
- @param account The account for which to return the corresponding password.
- 
- @param error If accessing the password fails, upon return contains an error that describes the problem.
- 
- @return Returns a the password data for the given account and service, or `nil` if the Keychain doesn't
- have a password for the given parameters.
- 
- @see passwordDataForService:account:
- */
-+ (NSData *)passwordDataForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
-
-
-///-------------------------
-/// @name Deleting Passwords
-///-------------------------
-
-/**
- Deletes a password from the Keychain.
- 
- @param serviceName The service for which to delete the corresponding password.
- 
- @param account The account for which to delete the corresponding password.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see deletePasswordForService:account:error:
- */
-+ (BOOL)deletePasswordForService:(NSString *)serviceName account:(NSString *)account;
-
-/**
- Deletes a password from the Keychain.
- 
- @param serviceName The service for which to delete the corresponding password.
- 
- @param account The account for which to delete the corresponding password.
- 
- @param error If deleting the password fails, upon return contains an error that describes the problem.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see deletePasswordForService:account:
- */
-+ (BOOL)deletePasswordForService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
-
-
-///------------------------
-/// @name Setting Passwords
-///------------------------
-
-/**
- Sets a password in the Keychain.
- 
- @param password The password to store in the Keychain.
- 
- @param serviceName The service for which to set the corresponding password.
- 
- @param account The account for which to set the corresponding password.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see setPassword:forService:account:error:
- */
-+ (BOOL)setPassword:(NSString *)password forService:(NSString *)serviceName account:(NSString *)account;
-
-/**
- Sets a password in the Keychain.
- 
- @param password The password to store in the Keychain.
- 
- @param serviceName The service for which to set the corresponding password.
- 
- @param account The account for which to set the corresponding password.
- 
- @param error If setting the password fails, upon return contains an error that describes the problem.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see setPassword:forService:account:
- */
-+ (BOOL)setPassword:(NSString *)password forService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
-
-/**
- Sets arbirary data in the Keychain.
- 
- @param password The data to store in the Keychain.
- 
- @param serviceName The service for which to set the corresponding password.
- 
- @param account The account for which to set the corresponding password.
- 
- @param error If setting the password fails, upon return contains an error that describes the problem.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see setPasswordData:forService:account:error:
- */
-+ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)serviceName account:(NSString *)account;
-
-/**
- Sets arbirary data in the Keychain.
- 
- @param password The data to store in the Keychain.
- 
- @param serviceName The service for which to set the corresponding password.
- 
- @param account The account for which to set the corresponding password.
- 
- @param error If setting the password fails, upon return contains an error that describes the problem.
- 
- @return Returns `YES` on success, or `NO` on failure.
- 
- @see setPasswordData:forService:account:
- */
-+ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)serviceName account:(NSString *)account error:(NSError **)error;
-
-
-///--------------------
-/// @name Configuration
-///--------------------
-
-#if __IPHONE_4_0 && TARGET_OS_IPHONE
-/**
- Returns the accessibility type for all future passwords saved to the Keychain.
- 
- @return Returns the accessibility type.
- 
- The return value will be `NULL` or one of the "Keychain Item Accessibility Constants" used for determining when a
- keychain item should be readable.
- 
- @see accessibilityType
- */
-+ (CFTypeRef)accessibilityType;
-
-/**
- Sets the accessibility type for all future passwords saved to the Keychain.
- 
- @param accessibilityType One of the "Keychain Item Accessibility Constants" used for determining when a keychain item
- should be readable.
- 
- If the value is `NULL` (the default), the Keychain default will be used.
- 
- @see accessibilityType
- */
-+ (void)setAccessibilityType:(CFTypeRef)accessibilityType;
-#endif
-
-@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/SSKeychain.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/SSKeychain.m b/sdks/ios/UGAPI/SSKeychain.m
deleted file mode 100644
index 1267b5e..0000000
--- a/sdks/ios/UGAPI/SSKeychain.m
+++ /dev/null
@@ -1,262 +0,0 @@
-//
-//  SSKeychain.m
-//  SSToolkit
-//
-//  Created by Sam Soffes on 5/19/10.
-//  Copyright (c) 2009-2011 Sam Soffes. All rights reserved.
-//
-
-#import "SSKeychain.h"
-
-NSString *const kSSKeychainErrorDomain = @"com.samsoffes.sskeychain";
-
-NSString *const kSSKeychainAccountKey = @"acct";
-NSString *const kSSKeychainCreatedAtKey = @"cdat";
-NSString *const kSSKeychainClassKey = @"labl";
-NSString *const kSSKeychainDescriptionKey = @"desc";
-NSString *const kSSKeychainLabelKey = @"labl";
-NSString *const kSSKeychainLastModifiedKey = @"mdat";
-NSString *const kSSKeychainWhereKey = @"svce";
-
-#if __IPHONE_4_0 && TARGET_OS_IPHONE
-CFTypeRef SSKeychainAccessibilityType = NULL;
-#endif
-
-@interface SSKeychain ()
-+ (NSMutableDictionary *)_queryForService:(NSString *)service account:(NSString *)account;
-@end
-
-@implementation SSKeychain
-
-#pragma mark - Getting Accounts
-
-+ (NSArray *)allAccounts {
-    return [self accountsForService:nil error:nil];
-}
-
-
-+ (NSArray *)allAccounts:(NSError **)error {
-    return [self accountsForService:nil error:error];
-}
-
-
-+ (NSArray *)accountsForService:(NSString *)service {
-    return [self accountsForService:service error:nil];
-}
-
-
-+ (NSArray *)accountsForService:(NSString *)service error:(NSError **)error {
-    OSStatus status = SSKeychainErrorBadArguments;
-    NSMutableDictionary *query = [self _queryForService:service account:nil];
-#if __has_feature(objc_arc)
-	[query setObject:(__bridge id)kCFBooleanTrue forKey:(__bridge id)kSecReturnAttributes];
-    [query setObject:(__bridge id)kSecMatchLimitAll forKey:(__bridge id)kSecMatchLimit];
-#else
-    [query setObject:(id)kCFBooleanTrue forKey:(id)kSecReturnAttributes];
-    [query setObject:(id)kSecMatchLimitAll forKey:(id)kSecMatchLimit];
-#endif
-	
-	CFTypeRef result = NULL;
-#if __has_feature(objc_arc)
-    status = SecItemCopyMatching((__bridge CFDictionaryRef)query, &result);
-#else
-	status = SecItemCopyMatching((CFDictionaryRef)query, &result);
-#endif
-    if (status != noErr && error != NULL) {
-		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
-		return nil;
-	}
-	
-#if __has_feature(objc_arc)
-	return (__bridge_transfer NSArray *)result;
-#else
-    return [(NSArray *)result autorelease];
-#endif
-}
-
-
-#pragma mark - Getting Passwords
-
-+ (NSString *)passwordForService:(NSString *)service account:(NSString *)account {
-	return [self passwordForService:service account:account error:nil];
-}
-
-
-+ (NSString *)passwordForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
-    NSData *data = [self passwordDataForService:service account:account error:error];
-	if (data.length > 0) {
-		NSString *string = [[NSString alloc] initWithData:(NSData *)data encoding:NSUTF8StringEncoding];
-#if !__has_feature(objc_arc)
-		[string autorelease];
-#endif
-		return string;
-	}
-	
-	return nil;
-}
-
-
-+ (NSData *)passwordDataForService:(NSString *)service account:(NSString *)account {
-    return [self passwordDataForService:service account:account error:nil];
-}
-
-
-+ (NSData *)passwordDataForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
-    OSStatus status = SSKeychainErrorBadArguments;
-	if (!service || !account) {
-		if (error) {
-			*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
-		}
-		return nil;
-	}
-	
-	CFTypeRef result = NULL;
-	NSMutableDictionary *query = [self _queryForService:service account:account];
-#if __has_feature(objc_arc)
-	[query setObject:(__bridge id)kCFBooleanTrue forKey:(__bridge id)kSecReturnData];
-	[query setObject:(__bridge id)kSecMatchLimitOne forKey:(__bridge id)kSecMatchLimit];
-	status = SecItemCopyMatching((__bridge CFDictionaryRef)query, &result);
-#else
-	[query setObject:(id)kCFBooleanTrue forKey:(id)kSecReturnData];
-	[query setObject:(id)kSecMatchLimitOne forKey:(id)kSecMatchLimit];
-	status = SecItemCopyMatching((CFDictionaryRef)query, &result);
-#endif
-	
-	if (status != noErr && error != NULL) {
-		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
-		return nil;
-	}
-	
-#if __has_feature(objc_arc)
-	return (__bridge_transfer NSData *)result;
-#else
-    return [(NSData *)result autorelease];
-#endif
-}
-
-
-#pragma mark - Deleting Passwords
-
-+ (BOOL)deletePasswordForService:(NSString *)service account:(NSString *)account {
-	return [self deletePasswordForService:service account:account error:nil];
-}
-
-
-+ (BOOL)deletePasswordForService:(NSString *)service account:(NSString *)account error:(NSError **)error {
-	OSStatus status = SSKeychainErrorBadArguments;
-	if (service && account) {
-		NSMutableDictionary *query = [self _queryForService:service account:account];
-#if __has_feature(objc_arc)
-		status = SecItemDelete((__bridge CFDictionaryRef)query);
-#else
-		status = SecItemDelete((CFDictionaryRef)query);
-#endif
-	}
-	if (status != noErr && error != NULL) {
-		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
-	}
-	return (status == noErr);
-    
-}
-
-
-#pragma mark - Setting Passwords
-
-+ (BOOL)setPassword:(NSString *)password forService:(NSString *)service account:(NSString *)account {
-	return [self setPassword:password forService:service account:account error:nil];
-}
-
-
-+ (BOOL)setPassword:(NSString *)password forService:(NSString *)service account:(NSString *)account error:(NSError **)error {
-    NSData *data = [password dataUsingEncoding:NSUTF8StringEncoding];
-    return [self setPasswordData:data forService:service account:account error:error];
-}
-
-
-+ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)service account:(NSString *)account {
-    return [self setPasswordData:password forService:service account:account error:nil];
-}
-
-
-+ (BOOL)setPasswordData:(NSData *)password forService:(NSString *)service account:(NSString *)account error:(NSError **)error {
-    OSStatus status = SSKeychainErrorBadArguments;
-	if (password && service && account) {
-        [self deletePasswordForService:service account:account];
-        NSMutableDictionary *query = [self _queryForService:service account:account];
-#if __has_feature(objc_arc)
-		[query setObject:password forKey:(__bridge id)kSecValueData];
-#else
-		[query setObject:password forKey:(id)kSecValueData];
-#endif
-		
-#if __IPHONE_4_0 && TARGET_OS_IPHONE
-		if (SSKeychainAccessibilityType) {
-#if __has_feature(objc_arc)
-			[query setObject:(id)[self accessibilityType] forKey:(__bridge id)kSecAttrAccessible];
-#else
-			[query setObject:(id)[self accessibilityType] forKey:(id)kSecAttrAccessible];
-#endif
-		}
-#endif
-		
-#if __has_feature(objc_arc)
-        status = SecItemAdd((__bridge CFDictionaryRef)query, NULL);
-#else
-		status = SecItemAdd((CFDictionaryRef)query, NULL);
-#endif
-	}
-	if (status != noErr && error != NULL) {
-		*error = [NSError errorWithDomain:kSSKeychainErrorDomain code:status userInfo:nil];
-	}
-	return (status == noErr);
-}
-
-
-#pragma mark - Configuration
-
-#if __IPHONE_4_0 && TARGET_OS_IPHONE
-+ (CFTypeRef)accessibilityType {
-	return SSKeychainAccessibilityType;
-}
-
-
-+ (void)setAccessibilityType:(CFTypeRef)accessibilityType {
-	CFRetain(accessibilityType);
-	if (SSKeychainAccessibilityType) {
-		CFRelease(SSKeychainAccessibilityType);
-	}
-	SSKeychainAccessibilityType = accessibilityType;
-}
-#endif
-
-
-#pragma mark - Private
-
-+ (NSMutableDictionary *)_queryForService:(NSString *)service account:(NSString *)account {
-    NSMutableDictionary *dictionary = [NSMutableDictionary dictionaryWithCapacity:3];
-#if __has_feature(objc_arc)
-    [dictionary setObject:(__bridge id)kSecClassGenericPassword forKey:(__bridge id)kSecClass];
-#else
-	[dictionary setObject:(id)kSecClassGenericPassword forKey:(id)kSecClass];
-#endif
-	
-    if (service) {
-#if __has_feature(objc_arc)
-		[dictionary setObject:service forKey:(__bridge id)kSecAttrService];
-#else
-		[dictionary setObject:service forKey:(id)kSecAttrService];
-#endif
-	}
-	
-    if (account) {
-#if __has_feature(objc_arc)
-		[dictionary setObject:account forKey:(__bridge id)kSecAttrAccount];
-#else
-		[dictionary setObject:account forKey:(id)kSecAttrAccount];
-#endif
-	}
-	
-    return dictionary;
-}
-
-@end
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGActivity.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGActivity.h b/sdks/ios/UGAPI/UGActivity.h
deleted file mode 100755
index 1139518..0000000
--- a/sdks/ios/UGAPI/UGActivity.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-
-@interface UGActivity : NSObject
-
-// In order for an activity to be valid, you must call setBasics and one of the setActor functions. 
-// In all cases, the return value will be YES if the function succeeded and NO if there
-// was a problem with the set. A response of NO will usually mean you sent nil for a required field.
-
-// these are the basics of the activity.
-// verb: the action being taken
-// category: The type of activity it is
-// content: The content of this activity. The format is defined by the category
-// title: The title of this category.
--(BOOL) setBasics: (NSString *)verb category:(NSString *)category content:(NSString *)content title:(NSString *)title;
-
-// actorUserName: The username of the entity doing this activity
-// actorDisplayName: The visible name of the entity doing this activity
-// actorUUID: The UUID of the entity doing this activity
--(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorUUID:(NSString *)actorUUID;
-
-// actorUserName: The username of the entity doing this activity
-// actorDisplayName: The visible name of the entity doing this activity
-// actorUUID: The UUID of the entity doing this activity
--(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorEmail:(NSString *)actorEmail;
-
-// Associating an object with the Activity is optional. You don't have to supply an object at all.
-
-// objectType: the type of the object associated with this activity
-// displayName: The visible name of the object associated with this activity
-// entityType: the entity type of this object within UserGrid. The actual type that it is stored under
-// entityUUID: The uuid of the object associated with this activity
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName entityType:(NSString *)entityType entityUUID:(NSString *)entityUUID;
-
-// similar to the function above, but it takes an arbitrary object content (which can be new and unique) instead of an already-defined object
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName objectContent:(NSString *)objectContent;
-
-// similar to the other two functions, but simply has the type and displayName. In this case, the 
-// "content" value supplied in setBasics will be used as the object content.
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName;
-
-// returns YES if this is properly set up. NO if it has not been properly set up
--(BOOL)isValid;
-
-// turn this object in to an NSDictionary. Used internally by UGClient
--(NSDictionary *)toNSDictionary;
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGActivity.m
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGActivity.m b/sdks/ios/UGAPI/UGActivity.m
deleted file mode 100755
index 3eaea00..0000000
--- a/sdks/ios/UGAPI/UGActivity.m
+++ /dev/null
@@ -1,263 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import "UGActivity.h"
-
-// the way they have set up the object info
-enum
-{
-    kUGActivityNoObject = 0,
-    kUGActivityObjectEntity = 1,
-    kUGActivityObjectContent = 2,
-    kUGActivityObjectNameOnly = 3
-};
-
-@implementation UGActivity
-{
-    // basic stats
-    NSString *m_verb;
-    NSString *m_category;
-    NSString *m_content;
-    NSString *m_title;
-    
-    // stats related to the actor
-    NSString *m_actorUserName;
-    NSString *m_actorDisplayName;
-    NSString *m_actorUUID;
-    NSString *m_actorEmail;
-    
-    // stats related to the object
-    NSString *m_objectType;
-    NSString *m_objectDisplayName;
-    
-    // for the object, either these must be set...
-    NSString *m_entityType;
-    NSString *m_entityUUID;
-    
-    // ...or this must be set
-    NSString *m_objectContent;
-    
-    // or it will use the content field as the content for the object
-    
-    // tracking how the object is currently set up
-    int m_objectDataType;
-}
-
--(id)init
-{
-    self = [super init];
-    if ( self )
-    {
-        m_objectDataType = kUGActivityNoObject;
-    }
-    return self;
-}
-
--(BOOL) setBasics: (NSString *)verb category:(NSString *)category content:(NSString *)content title:(NSString *)title
-{
-    // input validation
-    if ( !verb || !category || !content || !title ) return NO;
-    
-    m_verb = verb;
-    m_category = category;
-    m_content = content;
-    m_title = title;
-
-    return YES;
-}
-
--(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorUUID:(NSString *)actorUUID
-{
-    // input validation
-    if ( !actorUserName || !actorDisplayName || !actorUUID ) return NO;
-    
-    m_actorUserName = actorUserName;
-    m_actorDisplayName = actorDisplayName;
-    m_actorUUID = actorUUID;
-    m_actorEmail = nil;
-    
-    return YES;
-}
-
--(BOOL) setActorInfo: (NSString *)actorUserName actorDisplayName:(NSString *)actorDisplayName actorEmail:(NSString *)actorEmail
-{
-    // input validation
-    if ( !actorUserName || !actorDisplayName || !actorEmail ) return NO;
-    
-    m_actorUserName = actorUserName;
-    m_actorDisplayName = actorDisplayName;
-    m_actorEmail = actorEmail;
-    m_actorUUID = nil;
-    
-    return YES;
-}
-
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName entityType:(NSString *)entityType entityUUID:(NSString *)entityUUID
-{
-    // input validation
-    if ( !objectType || !displayName || !entityType || !entityUUID ) return NO;
-    
-    m_objectType = objectType;
-    m_objectDisplayName = displayName;
-    m_entityType = entityType;
-    m_entityUUID = entityUUID;
-    m_objectDataType = kUGActivityObjectEntity;
-    
-    // clear out the unused value
-    m_objectContent = nil;
-    
-    return YES;
-}
-
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName objectContent:(NSString *)objectContent
-{
-    // input validation
-    if ( !objectType || !displayName || !objectContent ) return NO;
-    
-    m_objectType = objectType;
-    m_objectDisplayName = displayName;
-    m_objectContent = objectContent;
-    m_objectDataType = kUGActivityObjectContent;
-    
-    // clear out the unused values
-    m_entityType = nil;
-    m_entityUUID = nil;
-    
-    return YES;
-}
-
--(BOOL)setObjectInfo: (NSString *)objectType displayName:(NSString *)displayName
-{
-    // input validation
-    if ( !objectType || !displayName ) return NO;
-    
-    m_objectType = objectType;
-    m_objectDisplayName = displayName;
-    m_objectDataType = kUGActivityObjectNameOnly;
-    
-    // we'll use m_content when the time comes. But we don't want to 
-    // assume they've set it yet. They can call the setup functions in any order.
-    m_objectContent = nil; 
-    m_entityType = nil;
-    m_entityUUID = nil;
-    
-    return YES;
-}
-
--(BOOL)isValid
-{
-    // if any of the required values are nil, it's not valid
-    if ( !m_verb || !m_category || !m_content || !m_title || !m_actorUserName || !m_actorDisplayName )
-    {
-        return NO;
-    }
-    
-    // either the uuid or the email of the user must be valid
-    if ( !m_actorUUID && !m_actorEmail )
-    {
-        return NO;
-    }
-    
-    // the object data requirements are based on the object setup
-    switch ( m_objectDataType )
-    {
-        case kUGActivityObjectEntity:
-        {
-            if ( !m_objectType || !m_objectDisplayName || !m_entityType || !m_entityUUID ) return NO;
-        }
-        break;
-            
-        case kUGActivityObjectContent:
-        {
-            if ( !m_objectType || !m_objectDisplayName || !m_objectContent ) return NO;
-        }
-            break;
-            
-        case kUGActivityObjectNameOnly:
-        {
-            if ( !m_objectType || !m_objectDisplayName ) return NO;
-        }
-        break;
-            
-        // kUGActivityNoObject has no requirements.
-    }
-    
-    // if we're here, we're valid.
-    return YES;
-}
-
--(NSDictionary *)toNSDictionary
-{
-    NSMutableDictionary *ret = [NSMutableDictionary new];
-    
-    // add all the fields in
-    [ret setObject:@"activity" forKey:@"type"];
-    [ret setObject:m_verb forKey:@"verb"];
-    [ret setObject:m_category forKey:@"category"];
-    [ret setObject:m_content forKey:@"content"];
-    [ret setObject:m_title forKey:@"title"];
-    
-    // make the actor's subdictionary
-    NSMutableDictionary *actor = [NSMutableDictionary new];
-    [actor setObject:@"person" forKey:@"type"];
-    [actor setObject:@"user" forKey:@"entityType"];
-    [actor setObject:m_actorDisplayName forKey:@"displayName"];
-    
-    if ( m_actorUUID )
-    {
-        [actor setObject:m_actorUUID forKey:@"uuid"];
-    }
-    if ( m_actorEmail )
-    {
-        [actor setObject:m_actorEmail forKey:@"email"];
-    }
-    
-    // add the actor to the main dict
-    [ret setObject:actor forKey:@"actor"];
-    
-    if ( m_objectDataType != kUGActivityNoObject )
-    {
-        // there is an associated object. Prep a dict for it
-        NSMutableDictionary *object = [NSMutableDictionary new];
-        
-        // these fields are involved in all cases
-        [object setObject:m_objectType forKey:@"type"];
-        [object setObject:m_objectDisplayName forKey:@"displayName"];
-        
-        if ( m_objectDataType == kUGActivityObjectContent )
-        {
-            [object setObject:m_objectContent forKey:@"content"];
-        }
-        else if ( m_objectDataType == kUGActivityObjectNameOnly )
-        {
-            [object setObject:m_content forKey:@"content"];
-        }
-        else if ( m_objectDataType == kUGActivityObjectEntity )
-        {
-            [object setObject:m_entityType forKey:@"entityType"];
-            [object setObject:m_entityUUID forKey:@"entityUUID"];
-        }
-        
-        // add to the dict
-        [ret setObject:object forKey:@"object"];
-    }
-    
-    // done with the assembly
-    return ret;
-}
-
-@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/ios/UGAPI/UGClient.h
----------------------------------------------------------------------
diff --git a/sdks/ios/UGAPI/UGClient.h b/sdks/ios/UGAPI/UGClient.h
deleted file mode 100755
index 4e6a31f..0000000
--- a/sdks/ios/UGAPI/UGClient.h
+++ /dev/null
@@ -1,328 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#import <Foundation/Foundation.h>
-#import "UGClientResponse.h"
-#import "UGQuery.h"
-#import "UGActivity.h"
-#import "UGUser.h"
-
-/******************** A WORD ON NETWORK COMMUNICATION CALLS ****************
-Some calls require network communication with UserGrid. Therefore,
-they all have the option of being synchronous (blocking) or asynchronous.
-
-You may specify an asynchronous delegate with the call setDelegate. If you
-do, all calls will be asynchronous and responses will be sent to that delegate. 
-The immediate return value (a UGClientResponse *) from any call will have its
-transactionState set to kUGClientResponsePending, and the transactionID will be
-properly set (allowing you to identify the specific call in your callback if you
-wish.)
- 
-The delegate must support the following message:
--(void)ugClientResponse:(UGClientResponse *)response
-
-If you do not set a delegate, all functions will run synchronously, blocking 
-until a response has been received or an error detected. 
-****************************************************************************/
-
-
-/**************************** A WORD ON UGQUERY *****************************
-Some calls take a UGQuery *. These are functions that return a lot of data, as 
-opposed to a simple answer. You may use the UGQuery to control the data with filters
-and response limits. See UGQuery.h for more information.
-
-In all cases, where a UGQuery is one of the parameters, you may send nil. If you
-do, the query will be completely unfiltered, and you will receive back *all* the data
-associated with the operation, up to the response limit, which is 10. You can
-set the response limit in UGQuery as well. 
-****************************************************************************/
-
-
-@interface UGClient : NSObject
-
-+(NSString *) version;
-
-/********************* INIT AND SETUP *********************/
-// init with an app ID
--(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID;
-
-// init with an app ID and a base UserGrid URL. This is useful if you
-// are running a local UG server or your company has its own public
-// UG server. The default URL is http://api.usergrid.com. The base URL
-// must be a fully formated http link, including the "http://" at the
-// beginning.
--(id) initWithOrganizationId: (NSString *)organizationID withApplicationID:(NSString *)applicationID baseURL:(NSString *)baseURL;
-
-// set the delegate. See "A WORD ON NETWORK COMMUNICATION CALLS"
-// at the top of the file for a detailed explanation. The function
-// will return NO if the delegate is rejected. This means the delegate
-// does not support the required delegation function "ugClientResponse".
-//
-// This is the formal declaration of ugClientResponse:
-// -(void)ugClientResponse:(UGClientResponse *)response
-// 
-// You may change the delegate at any time, but be forewarned that any
-// pending transactions in progress will be abandoned. Changing the delegate
-// (especially setting it to nil) ensures that hte previous delegate will
-// receive no further messages from this instance of UGClient. 
-// 
-// Setting the delegate to nil puts the API in to synchronous mode.
--(BOOL) setDelegate:(id)delegate;
-
-
-/********************* LOGIN / LOGOUT *********************/
-// log in with the given username and password
--(UGClientResponse *)logInUser: (NSString *)userName password:(NSString *)password;
-
-// log in with the given username and PIN value
--(UGClientResponse *)logInUserWithPin: (NSString *)userName pin:(NSString *)pin;
-
-// log in user with Facebook token
-//
-//  //sample usage:
-//  NSString * facebookToken = @"your-facebook-token";
-//  UGClientResponse *response = [usergridClient logInUserWithFacebook:facebookToken];
-//  user = [usergridClient getLoggedInUser];
-//  if (user.username){
-//    return true;
-//  } else {
-//    return false;
-//  }
-//
--(UGClientResponse *)logInUserWithFacebook: (NSString *)facebookToken;
-
-// log in as the administrator of the application. Generally used for applications
-// that have an "administrator" feature. Not the sort of thing you want normal
-// users doing. 
--(UGClientResponse *)logInAdmin: (NSString *)adminUserName secret:(NSString *)adminSecret;
-
-// log out the current user. The Client only supports one user logged in at a time.
-// You can have multiple instances of UGClient if you want multiple
-// users doing transactions simultaneously. This does not require network communication,
-// so it has no return. It doesn't actually "log out" from the server. It simply clears 
-// the locally stored auth information
--(void)logOut;
-
-
-
-/********************* USER MANAGEMENT *********************/
-//adds a new user
--(UGClientResponse *)addUser:(NSString *)username email:(NSString *)email name:(NSString *)name password:(NSString *)password;
-
-// updates a user's password
--(UGClientResponse *)updateUserPassword:(NSString *)usernameOrEmail oldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword;
-
-// get all the groups this user is in
--(UGClientResponse *)getGroupsForUser: (NSString *)userID;
-
-// get users in this app. Definitely want to consider sending a Query along
-// with this call
--(UGClientResponse *)getUsers: (UGQuery *)query;
-
-/********************* ACTIVITY MANAGEMENT *********************/
-// create a new activity. 
-// Note that there is a class, UGActivity, which can help
-// you create and validate an Activity, and will generate the needed
-// NSDictionary for you.
--(UGClientResponse *)createActivity: (NSDictionary *)activity;
-
-// create an activity and post it to a user in a single step. See comment
-// above createActivity for information on making Activity creation easier
--(UGClientResponse *)postUserActivity: (NSString *)userID activity:(NSDictionary *)activity;
-
-// post an already-created activity to a user
--(UGClientResponse *)postUserActivityByUUID: (NSString *)userID activity:(NSString *)activityUUID;
-
-// create an activity and post it to a group in a single step. See comment
-// above createActivity for information on making Activity creation easier
--(UGClientResponse *)postGroupActivity: (NSString *)groupID activity:(NSDictionary *)activity;
-
-// post an already-created activity to a group
--(UGClientResponse *)postGroupActivityByUUID: (NSString *)groupID activity:(NSString *)activityUUID;
-
-// get the activities this user is in
--(UGClientResponse *)getActivitiesForUser: (NSString *)userID query:(UGQuery *)query;
-
-// get the activities this group is in
--(UGClientResponse *)getActivitiesForGroup: (NSString *)groupID query:(UGQuery *)query;
-
-// get the activity feed for a user
--(UGClientResponse *)getActivityFeedForUser: (NSString *)userID query:(UGQuery *)query;
-
-// get the activity feed for a group
--(UGClientResponse *)getActivityFeedForGroup: (NSString *)groupID query:(UGQuery *)query;
-
-// remove an activity 
--(UGClientResponse *)removeActivity:(NSString *)activityUUID;
-
-/********************* GROUP MANAGEMENT *********************/
-// create a new group. The groupPath can be a path with slashes to make for
-// a hierarchical structure of your own design (if you want). groupTitle is
-// optional, you can send nil if you don't want to provide one.
--(UGClientResponse *)createGroup:(NSString *)groupPath groupTitle:(NSString *)groupTitle;
-
-// add a user to a group
--(UGClientResponse *)addUserToGroup:(NSString *)userID group:(NSString *)groupID;
-
-// remove a user from a group
--(UGClientResponse *)removeUserFromGroup:(NSString *)userID group:(NSString *)groupID;
-
-// get all the users in this group
--(UGClientResponse *)getUsersForGroup:(NSString *)groupID query:(UGQuery *)query;
-
-
-
-/******************** ENTITY MANAGEMENT ********************/
-// adds an entity to the specified collection. 
--(UGClientResponse *)createEntity: (NSDictionary *)newEntity;
-
-// get a list of entities that meet the specified query.
--(UGClientResponse *)getEntities: (NSString *)type query:(UGQuery *)query;
-
-// updates an entity (it knows the type from the entity data) 
--(UGClientResponse *)updateEntity: (NSString *)entityID entity:(NSDictionary *)updatedEntity;
-
-// removes an entity of the specified type
--(UGClientResponse *)removeEntity: (NSString *)type entityID:(NSString *)entityID;
-
-// Directionally connect two entities. For instance, user "Bob" might like Lyons Restaurant.
-// connectorType would be "users" (because Bob is a user)
-// connectorID would be Bob's userID
-// connectionType would be "like"
-// connecteeID would be the UUID of Lyons Restaurant
--(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID;
-
-// Directionally connect two entities. For instance, user "Bob" might follow user "Mary".
-// connectorType would be "users" (because Bob is a user)
-// connectorID would be Bob's userID
-// connectionType would be "like"
-// connecteeType would  be "users" (because Mary is a user)
-// connecteeID would be Mary's userID
--(UGClientResponse *)connectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType connecteeType:(NSString *)connecteeType connecteeID:(NSString *)connecteeID;
-
-// disconnect two entities. It uses the same parameters and calling rules as connectEntities
--(UGClientResponse *)disconnectEntities: (NSString *)connectorType connectorID:(NSString *)connectorID type:(NSString *)connectionType connecteeID:(NSString *)connecteeID;
-
-// get entity connections
--(UGClientResponse *)getEntityConnections: (NSString *)connectorType connectorID:(NSString *)connectorID connectionType:(NSString *)connectionType query:(UGQuery *)query;
-
-
-
-/********************* MESSAGE MANAGEMENT *********************/
-// post a message to a given queue
--(UGClientResponse *)postMessage: (NSString *)queuePath message:(NSDictionary *)message;
-
-// get all messages from the queue path
--(UGClientResponse *)getMessages: (NSString *)queuePath query:(UGQuery *)query;
-
-// add a subscriber to a queue
--(UGClientResponse *)addSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath;
-
-// remove a subscriber from a queue
--(UGClientResponse *)removeSubscriber: (NSString *)queuePath subscriberPath:(NSString *)subscriberPath;
-
-
-/********************* SERVER-SIDE STORAGE *********************/
-// these functions refer to data that can be put in a special place 
-// specific to this device. Every call to remoteStorage replaces whatever 
-// was there before
-
-// put the data in to the remote storage
--(UGClientResponse *)setRemoteStorage: (NSDictionary *)data;
-
-// get the data from remote storage
--(UGClientResponse *)getRemoteStorage;
-
-// a class function that returns a uuid for this
-// device. It will be globally unique, and will always
-// return the same value for the same handset.
-// NOTE - This value will change if the operating
-// system is reinstalled. This function is used internally, but
-// is also handy for clients, so it is part of the interface.
-+(NSString *)getUniqueDeviceID;
-
-/***************** REMOTE PUSH NOTIFICATIONS *****************/
-
-// call from application:didRegisterForRemoteNotificationsWithDeviceToken: callback
-// will automatically register the passed deviceToken with the usergrid system
-// using the getUniqueDeviceID method to associate this device on the server
-- (UGClientResponse *)setDevicePushToken:(NSData *)newDeviceToken forNotifier:(NSString *)notifier;
-
-// push an "alert" type notification to the remote group, user, or device specified
-// in the path argument. the notifer may be a name or UUID of an apns notifier
-// that has been set up on the usergrid server.
-- (UGClientResponse *)pushAlert:(NSString *)message
-                      withSound:(NSString *)sound
-                             to:(NSString *)path
-                  usingNotifier:(NSString *)notifier;
-
-/*********************** ACCESSORS ************************/
-// if a user is logged in, this returns the OAuth token for this session. 
-// UGClient manages this internally, so you never really need it. But if you
-// want it for other reasons, this accessor gives it to you. If you have not
-// successfully logged in, this will return nil
--(NSString *)getAccessToken;
-
-// returns information about the logged in user
--(UGUser *)getLoggedInUser;
-
-// returns the delegate that is currently being used for asynch
-// calls. Returns nil if there is no delegate (synch mode)
--(id) getDelegate;
-
-/*********************** OBLIQUE USAGE ************************/
-// This is a general purpose function for directly accessing the
-// UserGrid service. This is useful if the service has new features 
-// that the API has not yet supported, or if you are using an older 
-// version of the API and don't want to upgrade.
-// 
-// url: The full URL that you are accessing. You are responsible for 
-//      assembling it, including the appID and all sub-sections down the line
-//
-// op: The HttpMethod being invoked. Examples: @"POST", @"PUT", etc. You may
-//     send nil. If you do, the operation is GET. There is one specially supported
-//     method called "POSTFORM". This will post with the data type set to 
-//     application/x-www-form-urlencoded instead of the more likely needed
-//     application/json. This is necessary if you are doing authentication
-//     or if you are sending form data up. 
-//
-// opData: The data sent along with the operation. You may send nil. If the 
-//         operation is GET, this value is ignored. Usually, this would be
-//         expected to be in json format. With this oblique approach, it is
-//         your responsibility to format the data correctly for whatever you're
-//         doing. Bear in mind that this api comes with SBJson, which provides
-//         some very simple ways to assemble json formatted strings. See SBJsonWriter.
-//
-// NOTE - This function will be synchronous or asynchronous the same as any
-// other function in the API. It is based on the value sent to setDelegate.
--(UGClientResponse *)apiRequest: (NSString *)url operation:(NSString *)op data:(NSString *)opData;
-
-/*********************** DEBUGGING ASSISTANCE ************************/
-// when logging is on, all outgoing URLs are logged via NSLog, and all
-// incoming data from the service is also logged. Additionally, any errors
-// encountered internally are logged. This can be helpful to see the actual
-// service communication in progress and help debug problems you may be having. 
--(void)setLogging: (BOOL)loggingState;
-
-/*********************** VERSION CHECKING ************************/
-#define SYSTEM_VERSION_EQUAL_TO(v)                  ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedSame)
-#define SYSTEM_VERSION_GREATER_THAN(v)              ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedDescending)
-#define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v)  ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending)
-#define SYSTEM_VERSION_LESS_THAN(v)                 ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] == NSOrderedAscending)
-#define SYSTEM_VERSION_LESS_THAN_OR_EQUAL_TO(v)     ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedDescending)
-
-@end


[06/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
deleted file mode 100644
index 55b1276..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Groups.php
+++ /dev/null
@@ -1,486 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'find' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query Groups.',
-        'summary' => 'Query the groups collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'findById' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
-        'notes' => 'Find group by uuid.',
-        'summary' => 'Find group by uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'uuid' => [
-                'description' => 'Group UUID (entity uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'create' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new Group.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new Group entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'destroy' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete a Group entity.',
-        'summary' => 'Delete a Group entity by name or uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'update' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update a Group entity.',
-        'summary' => 'Update a Group entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'group name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'addUser' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}/users/{user_name_or_uuid}',
-        'notes' => 'Update a Group entity.',
-        'summary' => 'Update a Group entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'group name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_name_or_uuid' => [
-                'description' => 'user name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'removeUser' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}/users/{user_name_or_uuid}',
-        'notes' => 'Update a Group entity.',
-        'summary' => 'Update a Group entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Group',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'group name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_name_or_uuid' => [
-                'description' => 'user name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'groups'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Management.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
deleted file mode 100644
index b471e77..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Management.php
+++ /dev/null
@@ -1,1076 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'AuthPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/token',
-        'summary' => 'Get management access token',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ]
-        ]
-    ],
-    'AuthorizeGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/authorize',
-        'summary' => 'Authorize the client.  See the OAuth2 specification.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'response_type' => [
-                'description' => 'Response type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'token',
-                'required' => true,
-                'allowableValues' => ['code', 'token']
-            ],
-            'client_id' => [
-                'description' => 'Client ID.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ]
-        ]
-
-    ],
-    'OrgJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs',
-        'summary' => 'Create new organization.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'organization' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization Name'
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}',
-        'summary' => 'Find organization by name or UUID',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/activate',
-        'summary' => 'Activates the organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'confirm' => [
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-                'description' => 'Send confirmation email'
-            ]
-
-        ]
-    ],
-    'OrgReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/reactivate',
-        'summary' => 'Reactivates the organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-        ]
-    ],
-    'OrgFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/feed',
-        'summary' => 'Get organization activity feed',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgCredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
-        'summary' => 'Get organization client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgCredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/credentials',
-        'summary' => 'Generate organization client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgUsersGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Get admin users for organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgUsersJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Create new admin user for organization using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgUsersFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users',
-        'summary' => 'Create new admin user for organization using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'OrgUserPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'summary' => 'Adds existing admin users for organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin user username, email, or uuid'
-            ]
-        ]
-    ],
-    'OrgUserDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/orgs/{org_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'summary' => 'Remove an admin user from organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin user username, email, or uuid'
-            ]
-        ]
-    ],
-    'OrgAppsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Get apps for organization',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppsJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Create new application for organization using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application Name'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgAppsFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps',
-        'summary' => 'Create new application for organization using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application Name'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'OrgAppDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}',
-        'summary' => 'Delete an application in an organization.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Application',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppCredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
-        'summary' => 'Get application keys.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgAppCredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/orgs/{org_name_or_uuid}/apps/{app_name_or_uuid}/credentials',
-        'summary' => 'Generate application keys.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'app_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Application name or uuid'
-            ]
-        ]
-    ],
-    'OrgUserJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users',
-        'summary' => 'Create new admin user.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'OrgUserFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users',
-        'summary' => 'Create new admin using form post parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-
-    ],
-    'OrgUserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/resetpw',
-        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-    ],
-    'OrgUserResetPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/resetpw',
-        'summary' => 'Complete a user password reset.  Handles form POST response.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'recaptcha_challenge_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Challenge Field'
-            ],
-            'recaptcha_response_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Response Field'
-            ],
-        ]
-    ],
-    'AdminUserGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}',
-        'summary' => 'Returns the admin user details',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-        ]
-
-    ],
-    'AdminUserJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}',
-        'summary' => 'Updates the admin user details.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-
-    ],
-    'AdminUserActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/activate',
-        'summary' => 'Activates the admin user from link provided in email notification.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'confirm' => [
-                'location' => 'uri',
-                'type' => 'boolean',
-                'required' => false,
-                'description' => 'Send confirmation email'
-            ],
-        ]
-    ],
-    'AdminUserReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/reactivate',
-        'summary' => 'Request admin user reactivation.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ]
-        ]
-    ],
-    'AdminUserFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/feed',
-        'summary' => 'Get admin user activity feed.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-        ]
-    ],
-    'AdminUserPasswordJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}/password',
-        'summary' => 'Set admin user password.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'old_password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Old and new password'
-            ],
-            'new_password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Old and new password'
-            ],
-        ]
-    ],
-    'AdminUserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
-        'summary' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ]
-        ]
-    ],
-    'AdminUserResetPasswordFormPost' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/resetpw',
-        'summary' => 'Complete a user password reset.  Handles form POST response.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'recaptcha_challenge_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Challenge Field'
-            ],
-            'recaptcha_response_field' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Recaptcha Response Field'
-            ]
-        ]
-    ],
-    'AdminUserOrgsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Get organizations for admin user.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ]
-    ],
-    'AdminUserOrgsJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Create new organization for admin user using JSON payload.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'organization' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'AdminUserOrgsFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs',
-        'summary' => 'Create new organization for admin user using form parameters.',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Organization',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'organization' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'postField'
-        ]
-    ],
-    'AdminUserOrgPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
-        'summary' => 'Add admin users to organization.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'AdminUserOrgDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/management/users/{user_username_email_or_uuid}/orgs/{org_name_or_uuid}',
-        'summary' => 'Remove an admin user from organization.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'description' => 'The OAuth2 access token'
-            ],
-            'user_username_email_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin username, email or uuid'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-
-        ]
-    ]
-
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
deleted file mode 100644
index 9499e6f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Manifest.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'name' => 'Usergrid',
-    'apiVersion' => '1.0.1',
-    'baseUrl' => $baseURL,
-    'description' => 'Client to Usergrid application service',
-    'operations' => []
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
deleted file mode 100644
index 638ad24..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Messages.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
deleted file mode 100644
index be02717..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifications.php
+++ /dev/null
@@ -1,241 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-    'toGroup' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/{group}/notifications',
-        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'group' => [
-                'description' => 'group name',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ],
-    'toGroups' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/groups/*/notifications',
-        'notes' => 'Create Notification for group.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ],
-    'toDevice' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/{device_uuid}/notifications',
-        'notes' => 'Create Notification for single Device.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'device_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'device name or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ],
-    'toDevices' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/devices/*/notifications',
-        'notes' => 'Create Notification all Devices.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ],
-    'toUser' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_name}/notifications',
-        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_name' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'User name or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ],
-    'toUsers' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/*/notifications',
-        'notes' => 'Create Notification single User.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app notification',
-        'responseClass' => '',
-        'responseType' => 'model',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'user_name' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'User name or uuid'
-            ],
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'json'
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
deleted file mode 100644
index 41249a7..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Notifiers.php
+++ /dev/null
@@ -1,166 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'createApple' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
-        'notes' => 'Create new Apple Notifier.  See Usergrid documentation for the format of body.',
-        'summary' => 'Create new Notifier entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'name' => [
-                'description' => 'notifier name (entity type)',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'provider' => [
-                'description' => 'notifier provider',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'apple'
-            ],
-            'environment' => [
-                'description' => 'notifier environment',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'p12Certificate' => [
-                'description' => 'p12Certificate',
-                'location' => 'postFile',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'users'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'postField'
-        ]
-
-    ],
-    'createGoogle' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
-        'notes' => 'Create new Notifier.  See Usergrid documentation for the format of body.',
-        'summary' => 'Create new Notifier entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'name' => [
-                'description' => 'notifier name (entity type)',
-                'location' => 'json',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'provider' => [
-                'description' => 'notifier provider',
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'google'
-            ],
-            'apiKey' => [
-                'description' => 'apiKey',
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/notifiers',
-        'notes' => 'Get all  Notifier.  See Usergrid documentation for the format of body.',
-        'summary' => 'Get all  Notifier entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'name' => [
-                'description' => 'notifier name (entity type)',
-                'location' => 'json',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
deleted file mode 100644
index a51055f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Receipts.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [],
-    'find' => [],
-    'create' => [],
-    'destroy' => [],
-    'update' => []
-];
\ No newline at end of file


[09/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Models/User.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/User.php b/sdks/php5/apache-usergrid/src/Api/Models/User.php
deleted file mode 100644
index 8bec6d3..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Models/User.php
+++ /dev/null
@@ -1,77 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api\Models;
-
-
-use Guzzle\Service\Command\ResponseClassInterface;
-
-/**
- * Class User
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class User extends BaseCollection implements ResponseClassInterface
-{
-
-    use GuzzleCommandTrait;
-
-    public function deviceAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'users',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'devices'
-        ])->toArray();
-    }
-
-    public function notificationAttribute()
-    {
-
-    }
-
-    public function groupsAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'users',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'groups'
-        ])->toArray();
-    }
-
-    public function rolesAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'users',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'roles'
-        ])->toArray();
-    }
-
-    public function connectionsAttribute()
-    {
-        return $this->getApiClient()->application()->GetRelationship([
-            'collection' => 'users',
-            'entity_id' => $this->entities->fetch('uuid')->first(),
-            'relationship' => 'connections'
-        ])->toArray();
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/QueryAggregator.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/QueryAggregator.php b/sdks/php5/apache-usergrid/src/Api/QueryAggregator.php
deleted file mode 100644
index eacfcd5..0000000
--- a/sdks/php5/apache-usergrid/src/Api/QueryAggregator.php
+++ /dev/null
@@ -1,61 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api;
-
-
-use Guzzle\Http\QueryAggregator\QueryAggregatorInterface;
-use Guzzle\Http\QueryString;
-
-/**
- * Class QueryAggregator
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class QueryAggregator implements QueryAggregatorInterface
-{
-
-    /**
-     * {@inheritDoc}
-     */
-    public function aggregate($key, $value, QueryString $query)
-    {
-        $response = [];
-
-        foreach ($value as $k => $v) {
-            if (is_int($k)) {
-                return [
-                    $query->encodeValue("{$key}[]") => $value
-                ];
-            }
-
-            $k = "{$key}[{$k}]";
-
-            if (is_array($v)) {
-                $response = array_merge($response, self::aggregate($k, $v, $query));
-            } else {
-                $response[$query->encodeValue($k)] = $query->encodeValue($v);
-            }
-        }
-
-        return $response;
-    }
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/ResourceIterator.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/ResourceIterator.php b/sdks/php5/apache-usergrid/src/Api/ResourceIterator.php
deleted file mode 100644
index 7df0dd7..0000000
--- a/sdks/php5/apache-usergrid/src/Api/ResourceIterator.php
+++ /dev/null
@@ -1,69 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-
-namespace Apache\Usergrid\Api;
-
-use Guzzle\Service\Command\CommandInterface;
-use Guzzle\Service\Resource\ResourceIterator as BaseIterator;
-
-/**
- * Class ResourceIterator
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ResourceIterator extends BaseIterator
-{
-    /**
-     * {@inheritDoc}
-     */
-    public function __construct(CommandInterface $command, array $data = [])
-    {
-        parent::__construct($command, $data);
-
-        $this->pageSize = 20;
-    }
-
-    /**
-     * Send a request to retrieve the next page of results. Hook for subclasses to implement.
-     *
-     * @return array Returns the newly loaded resources
-     */
-    protected function sendRequest()
-    {
-        $this->command->set('limit', $this->pageSize);
-
-        if ($this->nextToken) {
-            $this->command->set('cursor', $this->nextToken);
-        }
-
-        $result = $this->command->execute();
-
-        $data = $result['entities'];
-
-        if ($result->has('cursor')) {
-            $this->nextToken = $result['cursor'] ? $result['cursor'] : false;
-        }
-
-        return $data;
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Api/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Usergrid.php b/sdks/php5/apache-usergrid/src/Api/Usergrid.php
deleted file mode 100644
index 279f2b2..0000000
--- a/sdks/php5/apache-usergrid/src/Api/Usergrid.php
+++ /dev/null
@@ -1,452 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Api;
-
-
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
-use Guzzle\Common\Event;
-use Guzzle\Plugin\ErrorResponse\ErrorResponsePlugin;
-use Guzzle\Service\Description\ServiceDescription;
-use InvalidArgumentException;
-
-/**
- * Class Usergrid
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Usergrid
-{
-
-    /**
-     *  Header Bearer Token
-     * @var
-     */
-    protected $token;
-
-
-    /**
-     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\GrantTypeInterface
-     */
-    protected $grantType;
-    /**
-     * The Usergrid API version.
-     *
-     * @var string
-     */
-    protected $version = '1.0.1';
-    /**
-     * The manifests path.
-     *
-     * @var string
-     */
-    protected $manifestPath;
-    /**
-     * The Base URL.
-     *
-     * @var string
-     */
-    protected $baseUrl;
-    /**
-     * Oauth2 Guzzle Plugin.
-     *
-     * @var \Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin
-     */
-    protected $oauth2_plugin;
-    /**
-     * The cached manifests data.
-     *
-     * @var array
-     */
-    protected $manifests = [];
-    /**
-     * The user agent.
-     *
-     * @var string
-     */
-    protected $userAgent = 'BaaS-Usergrid/1.0.0';
-    /**
-     * The headers to be sent to the Guzzle client.
-     *
-     * @var array
-     */
-    protected $headers = [];
-    private $org_name;
-    private $app_name;
-
-    /**
-     * @param null $orgName
-     * @param null $appName
-     * @param $manifestPath
-     * @param $version
-     * @param $baseUrl
-     * @param Oauth2Plugin $oauth2_plugin
-     */
-    function __construct(
-        $orgName = null,
-        $appName = null,
-        $manifestPath,
-        $version,
-        $baseUrl,
-        Oauth2Plugin $oauth2_plugin = null
-    ) {
-        //Set Version so its added to header
-        $this->setVersion($version ?: $this->version);
-
-        $this->baseUrl = $baseUrl;
-
-        $this->org_name = $orgName;
-        $this->app_name = $appName;
-
-        //check if OAuth2 plugin is enabled
-        if ($oauth2_plugin != null) {
-            $this->oauth2_plugin = $oauth2_plugin;
-            $this->grantType = $this->oauth2_plugin->getGrantType();
-        }
-
-        // Set the manifest path
-        $this->setManifestPath($manifestPath ?: dirname(dirname(__FILE__)) . '/Manifests');
-    }
-
-    /**
-     * @return mixed
-     */
-    public function getToken()
-    {
-        return $this->token;
-    }
-
-    /**
-     * @param mixed $token
-     * @return $this
-     */
-    public function setToken($token)
-    {
-        $this->token = $token;
-
-        $this->setHeaders([
-            'Authorization' => (string)'Bearer ' . $token,
-        ]);
-
-        return $this;
-    }
-
-    /**
-     * Dynamically handle missing methods.
-     *
-     * @param  string $method
-     * @param  array $arguments
-     * @return mixed
-     */
-    public function __call($method, array $arguments = [])
-    {
-        if (substr($method, -8) === 'Iterator') {
-            return $this->handleIteratorRequest($method, $arguments);
-        } elseif ($this->isSingleRequest($method)) {
-            return $this->handleSingleRequest($method, $arguments);
-        }
-
-        return $this->handleRequest($method);
-    }
-
-    /**
-     * Handles an iterator request.
-     *
-     * @param  string $method
-     * @param  array $arguments
-     * @return \Apache\Usergrid\Api\ResourceIterator
-     * @throws \InvalidArgumentException
-     */
-    protected function handleIteratorRequest($method, array $arguments = [])
-    {
-        $client = $this->handleRequest(substr($method, 0, -8));
-
-        $command = $client->getCommand('all', array_get($arguments, 0, []));
-
-        return new ResourceIterator($command, array_get($arguments, 1, []));
-    }
-
-    /**
-     * Handles the current request.
-     *
-     * @param  string $method
-     * @throws InvalidArgumentException
-     * @return \Guzzle\Service\Client
-     */
-    protected function handleRequest($method)
-    {
-        if (!$this->manifestExists($method)) {
-            throw new InvalidArgumentException("Undefined method [{$method}] called.");
-        }
-
-        // Initialize the Guzzle client
-        $client = new GuzzleClient('',
-            ['command.params' => ['app_name_or_uuid' => $this->app_name, 'org_name_or_uuid' => $this->org_name]]);
-
-        // Set our own usergrid api client for internal
-        // usage within our api models.
-        $client->setApiClient($this);
-
-        // Set the client user agent
-        $client->setUserAgent($this->getUserAgent(), true);
-
-
-        // Set the headers
-        $client->setDefaultOption('headers', $this->getHeaders());
-
-        // Get the Guzzle event dispatcher
-        $dispatcher = $client->getEventDispatcher();
-
-        // Register the error response plugin for our custom exceptions
-        $dispatcher->addSubscriber(new ErrorResponsePlugin);
-
-        // Listen to the "command.after_prepare" event fired by Guzzle
-        $dispatcher->addListener('command.after_prepare', function (Event $event) {
-            $request = $event['command']->getRequest();
-
-            $request->getQuery()->setAggregator(new QueryAggregator());
-        });
-
-        //check if Oauth 2 plugin is a instance of Oauth2Plugin
-        if ($this->oauth2_plugin instanceof Oauth2Plugin) {
-            $dispatcher->addSubscriber($this->oauth2_plugin);
-        }
-
-
-        // Set the manifest payload into the Guzzle client
-        $client->setDescription(ServiceDescription::factory(
-            $this->buildPayload($method)
-        ));
-
-        // Return the Guzzle client
-        return $client;
-    }
-
-    /**
-     * Checks if the manifest file for the current request exists.
-     *
-     * @param  string $file
-     * @return bool
-     */
-    protected function manifestExists($file)
-    {
-        return file_exists($this->getManifestFilePath($file));
-    }
-
-    /**
-     * Returns the given request manifest file path.
-     *
-     * @param  string $file
-     * @return string
-     */
-    protected function getManifestFilePath($file)
-    {
-        return $this->getFullManifestPath() . '/' . ucwords($file) . '.php';
-    }
-
-    /**
-     * Returns the full versioned manifests path.
-     *
-     * @return string
-     */
-    protected function getFullManifestPath()
-    {
-        return $this->getManifestPath() . '/' . $this->getVersion();
-    }
-
-    /**
-     * @return string
-     */
-    public function getManifestPath()
-    {
-        return $this->manifestPath;
-    }
-
-    /**
-     * @param string $manifestPath
-     * @return $this
-     */
-    public function setManifestPath($manifestPath)
-    {
-        $this->manifestPath = $manifestPath;
-        return $this;
-    }
-
-    /**
-     * @return string
-     */
-    public function getVersion()
-    {
-        return $this->version;
-    }
-
-    /**
-     * @param string $version
-     * @return $this
-     */
-    public function setVersion($version)
-    {
-        $this->version = $version;
-
-        $this->setHeaders([
-            'Usergrid-Version' => (string)$version,
-        ]);
-        return $this;
-    }
-
-    /**
-     * @return string
-     */
-    public function getUserAgent()
-    {
-        return $this->userAgent;
-    }
-
-    /**
-     * @param string $userAgent
-     * @return $this
-     */
-    public function setUserAgent($userAgent)
-    {
-        $this->userAgent = $userAgent;
-
-        return $this;
-    }
-
-    /**
-     * Returns the Guzzle client headers.
-     *
-     * @return array
-     */
-    public function getHeaders()
-    {
-        return $this->headers;
-    }
-
-    /**
-     * Sets the Guzzle client headers.
-     *
-     * @param  array $headers
-     * @return $this
-     */
-    public function setHeaders(array $headers = [])
-    {
-        $this->headers = array_merge($this->headers, $headers);
-
-        return $this;
-    }
-
-    /**
-     * Returns the current request payload.
-     *
-     * @param  string $method
-     * @return array
-     */
-    protected function buildPayload($method)
-    {
-        $operations = $this->getRequestManifestPayload($method);
-
-        $manifest = $this->getRequestManifestPayload('manifest', false);
-
-        return array_merge($manifest, compact('operations'));
-    }
-
-    /**
-     * Returns the given file manifest data.
-     *
-     * @param  string $file
-     * @param  bool $includeErrors
-     * @return array
-     */
-    protected function getRequestManifestPayload($file, $includeErrors = true)
-    {
-        $file = ucwords($file);
-
-        /** @noinspection PhpUnusedLocalVariableInspection */
-        $baseURL = $this->baseUrl;
-
-        if (!$manifest = array_get($this->manifests, $file)) {
-            if ($includeErrors) {
-                /** @noinspection PhpUnusedLocalVariableInspection */
-                $errors = $this->getRequestManifestPayload('errors', false);
-            }
-
-            /** @noinspection PhpIncludeInspection */
-            $manifest = require_once $this->getManifestFilePath($file);
-
-            array_set($this->manifests, $file, $manifest);
-        }
-
-        return $manifest;
-    }
-
-    /**
-     * Determines if the request is a single request.
-     *
-     * @param $method
-     * @return bool
-     */
-    protected function isSingleRequest($method)
-    {
-        return (str_singular($method) === $method && $this->manifestExists(str_plural($method)));
-    }
-
-    /**
-     * Handles a single request.
-     *
-     * @param  string $method
-     * @param  array $arguments
-     * @return \Guzzle\Service\Client
-     * @throws \InvalidArgumentException
-     */
-    protected function handleSingleRequest($method, array $arguments = [])
-    {
-        // Check if we have any arguments
-        if (empty($arguments)) {
-            throw new InvalidArgumentException('Not enough arguments provided!');
-        }
-
-        // Pluralize the method name
-        $pluralMethod = str_plural($method);
-
-        // Get the request manifest payload data
-        $manifest = $this->getRequestManifestPayload($pluralMethod);
-
-        if (!$parameters = array_get($manifest, 'find')) {
-            throw new InvalidArgumentException("Undefined method [{$method}] called.");;
-        }
-
-        // Get the required parameters for the request
-        $required = array_where(array_get($parameters, 'parameters'), function ($key, $value) {
-            return $value['required'] === true;
-        });
-
-        // Prepare the arguments for the request
-        $arguments = array_combine(
-            array_keys($required),
-            count($required) === 1 ? (array)$arguments[0] : $arguments
-        );
-
-        // Execute the request
-        return $this->handleRequest($pluralMethod)->find($arguments);
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
deleted file mode 100755
index b03d4a7..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/AuthorizationCode.php
+++ /dev/null
@@ -1,77 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-use Guzzle\Common\Collection;
-use Guzzle\Http\ClientInterface;
-
-/**
- * Authorization code grant type.
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749#section-4.1
- */
-class AuthorizationCode implements GrantTypeInterface
-{
-    /** @var ClientInterface The token endpoint client */
-    protected $client;
-
-    /** @var Collection Configuration settings */
-    protected $config;
-
-    public function __construct(ClientInterface $client, $config)
-    {
-        $this->client = $client;
-        $this->config = Collection::fromConfig($config, array(
-            'client_secret' => '',
-            'scope' => '',
-            'redirect_uri' => '',
-        ), array(
-            'client_id',
-            'code',
-        ));
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public function getTokenData()
-    {
-        $postBody = array(
-            'grant_type' => 'authorization_code',
-            'code' => $this->config['code'],
-        );
-        if ($this->config['scope']) {
-            $postBody['scope'] = $this->config['scope'];
-        }
-        if ($this->config['redirect_uri']) {
-            $postBody['redirect_uri'] = $this->config['redirect_uri'];
-        }
-        $request = $this->client->post(null, array(), $postBody);
-        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
-        $response = $request->send();
-        $data = $response->json();
-
-        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
-        return array_intersect_key($data, $requiredData);
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
deleted file mode 100755
index 729f6a5..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/ClientCredentials.php
+++ /dev/null
@@ -1,73 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-use Guzzle\Common\Collection;
-use Guzzle\Http\ClientInterface;
-
-/**
- * Client credentials grant type.
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749#section-4.4
- */
-class ClientCredentials implements GrantTypeInterface
-{
-    /** @var ClientInterface The token endpoint client */
-    protected $client;
-
-    /** @var Collection Configuration settings */
-    protected $config;
-
-    public function __construct(ClientInterface $client, $config)
-    {
-        $this->client = $client;
-        $this->config = Collection::fromConfig($config, array(
-            'client_secret' => '',
-            'scope' => '',
-        ), array(
-            'client_id',
-        ));
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public function getTokenData()
-    {
-        $postBody = array(
-            'grant_type' => 'client_credentials',
-            'client_id' => $this->config['client_id'],
-            'client_secret' => $this->config['client_secret']
-        );
-        if ($this->config['scope']) {
-            $postBody['scope'] = $this->config['scope'];
-        }
-        $request = $this->client->post(null, array(), $postBody);
-//        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
-        $response = $request->send();
-        $data = $response->json();
-
-        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
-        return array_intersect_key($data, $requiredData);
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
deleted file mode 100755
index 99096c0..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/GrantTypeInterface.php
+++ /dev/null
@@ -1,41 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-
-/**
- * Interface GrantTypeInterface
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-interface GrantTypeInterface
-{
-    /**
-     * Get the token data returned by the OAuth2 server.
-     *
-     * @return array An array with the following keys:
-     *               - access_token: The access token.
-     *               - expires_in: The access token lifetime, in seconds.
-     *               - refresh_token: The refresh token, if present.
-     */
-    public function getTokenData();
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
deleted file mode 100755
index f30d593..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/HWIOAuthBundleRefreshToken.php
+++ /dev/null
@@ -1,62 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-use HWI\Bundle\OAuthBundle\Security\Http\ResourceOwnerMap;
-use Symfony\Component\Security\Core\SecurityContextInterface;
-
-/**
- * HWIOAuthBundle Aware Refresh token grant type.
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749#section-6
- */
-class HWIOAuthBundleRefreshToken implements GrantTypeInterface
-{
-    /** @var SecurityContextInterface Symfony2 security component */
-    protected $securityContext;
-
-    /** @var ResourceOwnerMap         HWIOAuthBundle OAuth2 ResourceOwnerMap */
-    protected $resourceOwnerMap;
-
-    public function __construct(ResourceOwnerMap $resourceOwnerMap, SecurityContextInterface $securityContext)
-    {
-        $this->securityContext = $securityContext;
-        $this->resourceOwnerMap = $resourceOwnerMap;
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public function getTokenData($refreshToken = null)
-    {
-        $token = $this->securityContext->getToken();
-        $resourceName = $token->getResourceOwnerName();
-        $resourceOwner = $this->resourceOwnerMap->getResourceOwnerByName($resourceName);
-
-        $data = $resourceOwner->refreshAccessToken($refreshToken);
-        $token->setRawToken($data);
-        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
-
-        return array_intersect_key($data, $requiredData);
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
deleted file mode 100755
index 6afc482..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/PasswordCredentials.php
+++ /dev/null
@@ -1,75 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-use Guzzle\Common\Collection;
-use Guzzle\Http\ClientInterface;
-
-/**
- * Resource owner password credentials grant type.
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749#section-4.3
- */
-class PasswordCredentials implements GrantTypeInterface
-{
-    /** @var ClientInterface The token endpoint client */
-    protected $client;
-
-    /** @var Collection Configuration settings */
-    protected $config;
-
-    public function __construct(ClientInterface $client, $config)
-    {
-        $this->client = $client;
-        $this->config = Collection::fromConfig($config, array(
-            'client_secret' => '',
-            'scope' => '',
-        ), array(
-            'client_id',
-            'username',
-            'password'
-        ));
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public function getTokenData()
-    {
-        $postBody = array(
-            'grant_type' => 'password',
-            'username' => $this->config['username'],
-            'password' => $this->config['password'],
-        );
-        if ($this->config['scope']) {
-            $postBody['scope'] = $this->config['scope'];
-        }
-        $request = $this->client->post(null, array(), $postBody);
-        //Note: Usergrid it not using Oauth2 to spec so it dose not need a Auth type set no need to client id + secret when using password
-//        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
-        $response = $request->send();
-        $data = $response->json();
-
-        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
-        return array_intersect_key($data, $requiredData);
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
deleted file mode 100755
index 149d570..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/GrantType/RefreshToken.php
+++ /dev/null
@@ -1,74 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType;
-
-use Guzzle\Common\Collection;
-use Guzzle\Http\ClientInterface;
-
-/**
- * Refresh token grant type.
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749#section-6
- */
-class RefreshToken implements GrantTypeInterface
-{
-    /** @var ClientInterface The token endpoint client */
-    protected $client;
-
-    /** @var Collection Configuration settings */
-    protected $config;
-
-    public function __construct(ClientInterface $client, $config)
-    {
-        $this->client = $client;
-        $this->config = Collection::fromConfig($config, array(
-            'client_secret' => '',
-            'refresh_token' => '',
-            'scope' => '',
-        ), array(
-            'client_id',
-        ));
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public function getTokenData($refreshToken = null)
-    {
-        $postBody = array(
-            'grant_type' => 'refresh_token',
-            // If no refresh token was provided to the method, use the one
-            // provided to the constructor.
-            'refresh_token' => $refreshToken ?: $this->config['refresh_token'],
-        );
-        if ($this->config['scope']) {
-            $postBody['scope'] = $this->config['scope'];
-        }
-        $request = $this->client->post(null, array(), $postBody);
-        $request->setAuth($this->config['client_id'], $this->config['client_secret']);
-        $response = $request->send();
-        $data = $response->json();
-
-        $requiredData = array_flip(array('access_token', 'expires_in', 'refresh_token'));
-        return array_intersect_key($data, $requiredData);
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php b/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
deleted file mode 100755
index 8454309..0000000
--- a/sdks/php5/apache-usergrid/src/Guzzle/Plugin/Oauth2/Oauth2Plugin.php
+++ /dev/null
@@ -1,212 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Guzzle\Plugin\Oauth2;
-
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\GrantTypeInterface;
-use Guzzle\Common\Event;
-use Guzzle\Http\Exception\BadResponseException;
-use Symfony\Component\EventDispatcher\EventSubscriberInterface;
-
-/**
- * OAuth2 plugin
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- *
- * @link http://tools.ietf.org/html/rfc6749
- */
-class Oauth2Plugin implements EventSubscriberInterface
-{
-
-    /** @var GrantTypeInterface The grant type implementation used to acquire access tokens */
-    protected $grantType;
-
-    /** @var GrantTypeInterface The grant type implementation used to refresh access tokens */
-    protected $refreshTokenGrantType;
-
-    /** @var array An array with the "access_token" and "expires" keys */
-    protected $accessToken;
-
-    /** @var string The refresh token string. * */
-    protected $refreshToken;
-
-    /**
-     * Create a new Oauth2 plugin
-     * @param GrantTypeInterface $grantType
-     * @param GrantTypeInterface $refreshTokenGrantType
-     */
-    public function __construct(GrantTypeInterface $grantType = null, GrantTypeInterface $refreshTokenGrantType = null)
-    {
-        $this->grantType = $grantType;
-        $this->refreshTokenGrantType = $refreshTokenGrantType;
-    }
-
-    /**
-     * {@inheritdoc}
-     */
-    public static function getSubscribedEvents()
-    {
-        return array(
-            'request.before_send' => 'onRequestBeforeSend',
-            'request.error' => 'onRequestError',
-        );
-    }
-
-    /**
-     * Request before-send event handler.
-     *
-     * Adds the Authorization header if an access token was found.
-     *
-     * @param Event $event Event received
-     */
-    public function onRequestBeforeSend(Event $event)
-    {
-        $accessToken = $this->getAccessToken();
-        if ($accessToken) {
-            $event['request']->setHeader('Authorization', 'Bearer ' . $accessToken['access_token']);
-        }
-    }
-
-    /**
-     * Get the access token.
-     *
-     * Handles token expiration for tokens with an "expires" timestamp.
-     * In case no valid token was found, tries to acquire a new one.
-     *
-     * @return array|null
-     */
-    public function getAccessToken()
-    {
-        if (isset($this->accessToken['expires']) && $this->accessToken['expires'] < time()) {
-            // The access token has expired.
-            $this->accessToken = null;
-        }
-        if (!$this->accessToken) {
-            // Try to acquire a new access token from the server.
-            $this->acquireAccessToken();
-        }
-
-        return $this->accessToken;
-    }
-
-    /**
-     * Set the access token.
-     *
-     * @param array|string $accessToken The access token
-     */
-    public function setAccessToken(array $accessToken)
-    {
-        $this->accessToken = $accessToken;
-    }
-
-    /**
-     * Acquire a new access token from the server.
-     *
-     * @return array|null
-     */
-    protected function acquireAccessToken()
-    {
-        if ($this->refreshTokenGrantType && $this->refreshToken) {
-            try {
-                // Get an access token using the stored refresh token.
-                $tokenData = $this->refreshTokenGrantType->getTokenData($this->refreshToken);
-            } catch (BadResponseException $e) {
-                // The refresh token has probably expired.
-                $this->refreshToken = null;
-            }
-        }
-        if ($this->grantType && !isset($tokenData)) {
-            // Get a new access token.
-            $tokenData = $this->grantType->getTokenData();
-        }
-
-        $this->accessToken = null;
-        if (isset($tokenData)) {
-            // Process the returned data. Both expired_in and refresh_token
-            // are optional parameters.
-            $this->accessToken = array(
-                'access_token' => $tokenData['access_token'],
-            );
-            if (isset($tokenData['expires_in'])) {
-                $this->accessToken['expires'] = time() + $tokenData['expires_in'];
-            }
-            if (isset($tokenData['refresh_token'])) {
-                $this->refreshToken = $tokenData['refresh_token'];
-            }
-        }
-
-        return $this->accessToken;
-    }
-
-    /**
-     * Request error event handler.
-     *
-     * Handles unauthorized errors by acquiring a new access token and
-     * retrying the request.
-     *
-     * @param Event $event Event received
-     */
-    public function onRequestError(Event $event)
-    {
-        if ($event['response']->getStatusCode() == 401) {
-            if ($event['request']->getHeader('X-Guzzle-Retry')) {
-                // We already retried once, give up.
-                return;
-            }
-
-            // Acquire a new access token, and retry the request.
-            $newAccessToken = $this->acquireAccessToken();
-            if ($newAccessToken) {
-                $newRequest = clone $event['request'];
-                $newRequest->setHeader('Authorization', 'Bearer ' . $newAccessToken['access_token']);
-                $newRequest->setHeader('X-Guzzle-Retry', '1');
-                $event['response'] = $newRequest->send();
-                $event->stopPropagation();
-            }
-        }
-    }
-
-    /**
-     * Get the refresh token.
-     *
-     * @return string
-     */
-    public function getRefreshToken()
-    {
-        return $this->refreshToken;
-    }
-
-    /**
-     * Set the refresh token.
-     *
-     * @param string $refreshToken The refresh token
-     */
-    public function setRefreshToken($refreshToken)
-    {
-        $this->refreshToken = $refreshToken;
-    }
-
-    /**
-     * @return GrantTypeInterface
-     */
-    public function getGrantType()
-    {
-        return $this->grantType;
-    }
-}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php b/sdks/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
deleted file mode 100644
index 57807ad..0000000
--- a/sdks/php5/apache-usergrid/src/Laravel/ApacheUsergridServiceProvider.php
+++ /dev/null
@@ -1,159 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-namespace Apache\Usergrid\Laravel;
-
-
-use Apache\Usergrid\Api\Usergrid;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\ClientCredentials;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\PasswordCredentials;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\GrantType\RefreshToken;
-use Apache\Usergrid\Guzzle\Plugin\Oauth2\Oauth2Plugin;
-use Guzzle\Http\Client;
-use Illuminate\Support\ServiceProvider;
-
-/**
- * Class ApacheUsergridServiceProvider
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class ApacheUsergridServiceProvider extends ServiceProvider
-{
-
-    protected $oauth2Plugin = null;
-
-    /**
-     *
-     */
-    public function boot()
-    {
-        $this->package('apache/usergrid', 'apache/usergrid', __DIR__ . '/..');
-    }
-
-    /**
-     * Register the service provider.
-     *
-     * @return void
-     */
-    public function register()
-    {
-        // register Usergrid
-        $this->registerUsergrid();
-
-    }
-
-    protected function registerUsergrid()
-    {
-
-        $this->app['usergrid'] = $this->app->share(function ($app) {
-
-            /** Note: I had to move this to here from the register function as the below config values would not get set and would be null
-             * unless I has this with the package namespace missing but doing that would mean that it would not find the  enable_oauth2_plugin
-             * value .. This has been driving me crazy as I tried to read the config values from a rout and they would not show up
-             * then I did . Also this would not find the config values if the boot function did not have the package method called with
-             * all 3 args
-             * $enable_oauth2_plugin = $this->app['config']->get('usergrid.enable_oauth2_plugin');
-             *
-             * //check if user managed oauth auth flow
-             * if($enable_oauth2_plugin){
-             * // Create the Oauth2 Guzzle Plugin.
-             * $this->createGuzzleOauth2Plugin();
-             * }
-             */
-            $enable_oauth2_plugin = $app['config']->get('apache/usergrid::usergrid.enable_oauth2_plugin');
-
-            //check if user managed oauth auth flow
-            if ($enable_oauth2_plugin) {
-                // Create the Oauth2 Guzzle Plugin.
-                $this->createGuzzleOauth2Plugin();
-            }
-
-            $baseUrl = $app['config']->get('apache/usergrid::usergrid.url');
-
-            $orgName = $app['config']->get('apache/usergrid::usergrid.orgName');
-
-            $appName = $app['config']->get('apache/usergrid::usergrid.appName');
-
-            $manifestPath = $app['config']->get('apache/usergrid::usergrid.manifestPath');
-
-            $version = $app['config']->get('apache/usergrid::usergrid.version');
-
-            return new Usergrid($orgName, $appName, $manifestPath, $version, $baseUrl, $this->oauth2Plugin);
-        });
-
-        $this->app->alias('usergrid', 'Apache\Usergrid\Api\Usergrid');
-    }
-
-
-    protected function createGuzzleOauth2Plugin()
-    {
-
-        $base_url = $this->app['config']->get('apache/usergrid::usergrid.url');
-
-        $org_name = $this->app['config']->get('apache/usergrid::usergrid.orgName');
-
-        $app_name = $this->app['config']->get('apache/usergrid::usergrid.appName');
-
-        $grant_type = $this->app['config']->get('apache/usergrid::usergrid.grant_type');
-
-        $client_id = $this->app['config']->get('apache/usergrid::usergrid.clientId');
-
-        $client_secret = $this->app['config']->get('apache/usergrid::usergrid.clientSecret');
-
-        $username = $this->app['config']->get('apache/usergrid::usergrid.username');
-
-        $password = $this->app['config']->get('apache/usergrid::usergrid.password');
-
-
-        if ($this->app['config']->get('apache/usergrid::usergrid.auth_type') == 'organization') {
-
-            $url = $base_url . '/management/token';
-
-        } elseif ($this->app['config']->get('apache/usergrid::usergrid.auth_type') == 'application') {
-            $url = $base_url . '/' . $org_name . '/' . $app_name . '/token';
-        }
-
-        $oauth2Client = new Client($url);
-
-        if ($grant_type == 'client_credentials') {
-            $config = [
-                'client_id' => $client_id,
-                'client_secret' => $client_secret,
-
-            ];
-            $grantType = new ClientCredentials($oauth2Client, $config);
-            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
-            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
-
-        } elseif ($grant_type == 'password') {
-            $config = [
-                'username' => $username,
-                'password' => $password,
-                'client_id' => $client_id,
-                'client_secret' => $client_secret
-            ];
-            $grantType = new PasswordCredentials($oauth2Client, $config);
-            $refreshTokenGrantType = new RefreshToken($oauth2Client, $config);
-            $this->oauth2Plugin = new Oauth2Plugin($grantType, $refreshTokenGrantType);
-        }
-
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php b/sdks/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
deleted file mode 100644
index 1ea29f2..0000000
--- a/sdks/php5/apache-usergrid/src/Laravel/Facades/Usergrid.php
+++ /dev/null
@@ -1,42 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-namespace Apache\Usergrid\Laravel\Facades;
-
-
-use Illuminate\Support\Facades\Facade;
-
-/**
- * Class Usergrid
- *
- * @package    Apache/Usergrid
- * @version    1.0.0
- * @author     Jason Kristian <ja...@gmail.com>
- * @license    Apache License, Version  2.0
- * @copyright  (c) 2008-2014, Baas Platform Pty. Ltd
- * @link       http://baas-platform.com
- */
-class Usergrid extends Facade
-{
-    /**
-     * @return string
-     */
-    protected static function getFacadeAccessor()
-    {
-        return "usergrid";
-    }
-
-} 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Application.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
deleted file mode 100644
index 0054a8c..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.0/Application.php
+++ /dev/null
@@ -1,979 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'AuthPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
-        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
-        'summary' => 'Get app access token',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthPasswordPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
-        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
-        'summary' => 'Get app access token',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'postField',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthorizeGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
-        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
-        'summary' => 'Authorize app client',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'response_type' => [
-                'description' => 'Response type',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'default' => 'token'
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthorizePost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
-        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
-        'summary' => 'Authorize app client',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'response_type' => [
-                'description' => 'Response type',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'default' => 'token'
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'CredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
-        'notes' => 'Get the app client credentials.',
-        'summary' => 'Get app client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'CredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
-        'notes' => 'Generate new app client credentials',
-        'summary' => 'Generate app client credentials',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
-        'notes' => 'Create new app user',
-        'summary' => 'Create new app user.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
-        'notes' => 'Create new app user',
-        'summary' => 'Create new app user using form post parameters.',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordRestGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
-        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'summary' => 'Initiate a user password reset',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
-        'notes' => 'Complete a user password reset.  Handles form POST response.',
-        'summary' => 'Complete a user password reset',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'email' => [
-                'description' => 'User Email',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_challenge_field' => [
-                'description' => 'Recaptcha Challenge Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_response_field' => [
-                'description' => 'Recaptcha Response Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'notes' => 'Returns the app user details.',
-        'summary' => 'Returns the app user details',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'notes' => 'Updates the app user details.',
-        'summary' => 'Updates the app user details',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'UserActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate',
-        'notes' => 'Activates the app user from link provided in email notification.',
-        'summary' => 'Activates the app user',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'token' => [
-                'description' => 'Activation Token (supplied via email)',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'confirm' => [
-                'description' => 'Send confirmation email',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate',
-        'notes' => 'Request app user reactivation.',
-        'summary' => 'Reactivates the app user',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed',
-        'notes' => 'Get app user activity feed.',
-        'summary' => 'Get app user activity feed',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password',
-        'notes' => 'Set app user password.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Set app user password',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Old and new password",
-            'location' => 'json'
-        ]
-    ],
-    'UserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
-        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'summary' => 'Initiate a user password reset',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserResetPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
-        'notes' => 'Complete a user password reset.  Handles form POST response.',
-        'summary' => 'Complete a user password reset',
-        'responseClass' => '',
-        'responseType' => 'object',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_challenge_field' => [
-                'description' => 'Recaptcha Challenge Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_response_field' => [
-                'description' => 'Recaptcha Response Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'EntityGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'EntityJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'EntityPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update an app entity in a collection.',
-        'summary' => 'Update an app entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'EntityDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete an app entity.',
-        'summary' => 'Delete an app entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'PostEvents' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Event',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-
-
-];
\ No newline at end of file


[07/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Application.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
deleted file mode 100644
index 94f9c58..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
+++ /dev/null
@@ -1,1108 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'AuthPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
-        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
-        'summary' => 'Get app access token',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'query',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthPasswordPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
-        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
-        'summary' => 'Get app access token',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'grant_type' => [
-                'description' => 'Grant type.',
-                'location' => 'postField',
-                'type' => 'string',
-                'defaultValue' => 'password',
-                'required' => true,
-            ],
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'username' => [
-                'description' => 'Username (for grant_type=password).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'password' => [
-                'description' => 'Password (for grant_type=password).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID (for grant_type=client_credentials).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_secret' => [
-                'description' => 'Client Secret (for grant_type=client_credentials).',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthorizeGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
-        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
-        'summary' => 'Authorize app client',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'response_type' => [
-                'description' => 'Response type',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'default' => 'token'
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'AuthorizePost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
-        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
-        'summary' => 'Authorize app client',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'response_type' => [
-                'description' => 'Response type',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-                'default' => 'token'
-            ],
-            'redirect_uri' => [
-                'description' => 'Redirect URI',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'client_id' => [
-                'description' => 'Client ID',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'scope' => [
-                'description' => 'Access Token Scope.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'state' => [
-                'description' => 'Client State.',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'CredentialsGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
-        'notes' => 'Get the app client credentials.',
-        'summary' => 'Get app client credentials',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'CredentialsPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
-        'notes' => 'Generate new app client credentials',
-        'summary' => 'Generate app client credentials',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'access_token' => [
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'The OAuth2 access token'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
-        'notes' => 'Create new app user',
-        'summary' => 'Create new app user.  See Usergrid documentation for JSON format of body.',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'username' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'json',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
-        'notes' => 'Create new app user',
-        'summary' => 'Create new app user using form post parameters.',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'username' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Username'
-            ],
-            'name' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Name'
-            ],
-            'email' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Email'
-            ],
-            'password' => [
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Admin Password'
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordRestGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
-        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'summary' => 'Initiate a user password reset',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid]/{app_name_or_uuid}/users/resetpw',
-        'notes' => 'Complete a user password reset.  Handles form POST response.',
-        'summary' => 'Complete a user password reset',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'email' => [
-                'description' => 'User Email',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_challenge_field' => [
-                'description' => 'Recaptcha Challenge Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_response_field' => [
-                'description' => 'Recaptcha Response Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'notes' => 'Returns the app user details.',
-        'summary' => 'Returns the app user details',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
-        'notes' => 'Updates the app user details.',
-        'summary' => 'Updates the app user details',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            'location' => 'json'
-        ]
-    ],
-    'UserActivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate',
-        'notes' => 'Activates the app user from link provided in email notification.',
-        'summary' => 'Activates the app user',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'token' => [
-                'description' => 'Activation Token (supplied via email)',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'confirm' => [
-                'description' => 'Send confirmation email',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserReactivateGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate',
-        'notes' => 'Request app user reactivation.',
-        'summary' => 'Reactivates the app user',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserFeedGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed',
-        'notes' => 'Get app user activity feed.',
-        'summary' => 'Get app user activity feed',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserPasswordJsonPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password',
-        'notes' => 'Set app user password.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Set app user password',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Old and new password",
-            'location' => 'json'
-        ]
-    ],
-    'UserResetPasswordGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
-        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
-        'summary' => 'Initiate a user password reset',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'UserResetPasswordFormPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
-        'notes' => 'Complete a user password reset.  Handles form POST response.',
-        'summary' => 'Complete a user password reset',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'user_username_email_or_uuid' => [
-                'description' => 'User username, email or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_challenge_field' => [
-                'description' => 'Recaptcha Challenge Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'recaptcha_response_field' => [
-                'description' => 'Recaptcha Response Field',
-                'location' => 'postField',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'EntityGet' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'EntityJsonPost' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app entity',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'EntityPut' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update an app entity in a collection.',
-        'summary' => 'Update an app entity',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'EntityDelete' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete an app entity.',
-        'summary' => 'Delete an app entity',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'PostEvents' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create Event.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app event',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    //Application Collection Relationships
-    'GetRelationship' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_id}/{relationship}',
-        'notes' => 'Query an Entity Relationship ',
-        'summary' => 'Query an Entity Relationship',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_id' => [
-                'description' => 'Entity  ID (uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'relationship' => [
-                'description' => 'Relationship',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'CreateRelationship' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{first_entity_id}/{relationship}/{second_entity_id}',
-        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new app entity',
-        'responseClass' => '',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'first_entity_id' => [
-                'description' => 'first entity id (uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'relationship' => [
-                'description' => 'relationship',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'second_entity_id' => [
-                'description' => '2nd entity id (uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
deleted file mode 100644
index a51055f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [],
-    'find' => [],
-    'create' => [],
-    'destroy' => [],
-    'update' => []
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
deleted file mode 100644
index b89e805..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
+++ /dev/null
@@ -1,381 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query an app collection.',
-        'summary' => 'Query an app collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'find' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query Users.',
-        'summary' => 'Query the users collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'findById' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
-        'notes' => 'Find User by uuid.',
-        'summary' => 'Find user by uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'uuid' => [
-                'description' => 'User UUID (entity uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'create' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new User.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new User entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'destroy' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete a User entity.',
-        'summary' => 'Delete a User entity by name or uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'update' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update a User entity.',
-        'summary' => 'Update a User entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\User',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => $custom
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ]
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
deleted file mode 100644
index 65aa01d..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
+++ /dev/null
@@ -1,465 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Get All devices.',
-        'summary' => 'Get all Device collection limit 10000',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false
-
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'find' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Query Devices.',
-        'summary' => 'Query the devices collection',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'findById' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
-        'notes' => 'Find Device by uuid.',
-        'summary' => 'Find device by uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'uuid' => [
-                'description' => 'Group UUID (entity uuid)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-    'create' => [
-        'httpMethod' => 'POST',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
-        'notes' => 'Create new Device.  See Usergrid documentation for JSON format of body.',
-        'summary' => 'Create new Device entity',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'destroy' => [
-        'httpMethod' => 'DELETE',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Delete a Device entity.',
-        'summary' => 'Delete a Device entity by name or uuid',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ]
-    ],
-    'update' => [
-        'httpMethod' => 'PUT',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
-        'notes' => 'Update a Device entity.',
-        'summary' => 'Update a Device entity by name or uuid and using JSON data',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'entity_name_or_uuid' => [
-                'description' => 'entity name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Entity data",
-            'location' => 'json'
-        ]
-    ],
-    'notifiers' => [
-        'httpMethod' => 'GET',
-        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{device_uuid}/notifier',
-        'notes' => 'Get All device notifiers.',
-        'summary' => 'Get all Device notifiers',
-        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
-        'responseType' => 'class',
-        'errorResponses' => $errors,
-        'parameters' => [
-            'app_name_or_uuid' => [
-                'description' => 'app name or uuid',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'org_name_or_uuid' => [
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'description' => 'Organization name or uuid'
-            ],
-            'collection' => [
-                'description' => 'collection name (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-                'default' => 'devices'
-            ],
-            'device_uuid' => [
-                'description' => 'device uuid (entity type)',
-                'location' => 'uri',
-                'type' => 'string',
-                'required' => true,
-            ],
-            'access_token' => [
-                'description' => 'The OAuth2 access token',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'ql' => [
-                'description' => 'a query in the query language',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'reversed' => [
-                'description' => 'return results in reverse order',
-                'location' => 'query',
-                'type' => 'boolean',
-                'required' => false,
-            ],
-            'start' => [
-                'description' => 'the first entity UUID to return',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'cursor' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'string',
-                'required' => false,
-            ],
-            'limit' => [
-                'description' => 'an encoded representation of the query position for paging',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false
-
-            ],
-            'filter' => [
-                'description' => 'a condition to filter on',
-                'location' => 'query',
-                'type' => 'integer',
-                'required' => false,
-            ]
-        ],
-        'additionalParameters' => [
-            "description" => "Other parameters",
-            'location' => 'query'
-        ]
-    ],
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
deleted file mode 100644
index 3230dbd..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\BadRequestException',
-        'code' => 400,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\UnauthorizedException',
-        'code' => 401,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\RequestFailedException',
-        'code' => 402,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\NotFoundException',
-        'code' => 404,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 500,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 502,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 503,
-    ],
-    [
-        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
-        'code' => 504,
-    ],
-];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Events.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
deleted file mode 100644
index a51055f..0000000
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-/**
- * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License").
- * You may not use this file except in compliance with the License.
- * A copy of the License is located at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * or in the "license" file accompanying this file. This file is distributed
- * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
- * express or implied. See the License for the specific language governing
- * permissions and limitations under the License.
- */
-
-return [
-
-    'all' => [],
-    'find' => [],
-    'create' => [],
-    'destroy' => [],
-    'update' => []
-];
\ No newline at end of file


[24/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Notification.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Notification.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Notification.php
new file mode 100755
index 0000000..53bc506
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Notification.php
@@ -0,0 +1,103 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Notification - a data structure to hold all notification-related parameters
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 09-Mar-2013
+ */
+
+namespace Apache\Usergrid;
+
+define('DEVICES', 'DEVICES');
+define('GROUPS', 'GROUPS');
+define('USERS', 'USERS');
+
+class Notification extends Response {
+  private $message = '';
+  private $notifier_name;
+  private $delivery_time = 0;
+  private $recipients_list = array();
+  private $recipient_type = DEVICES;
+  private $errors = array();
+
+  public function __construct($message = '', $notifier_name = '', $delivery_time = 0, $recipients_list = array(), $recipient_type = DEVICES) {
+    $this->message = $message;
+    $this->notifier_name = $notifier_name;
+    $this->delivery_time = $delivery_time;
+    $this->recipients_list = $recipients_list;
+    $this->recipient_type = $recipient_type;
+  }
+
+  public function set_message($in) {
+    $this->message = $in;
+  }
+
+  public function get_message() {
+    return $this->message;
+  }
+
+  public function set_notifier_name($in) {
+    $this->notifier_name = $in;
+  }
+
+  public function get_notifier_name() {
+    return $this->notifier_name;
+  }
+
+  public function set_delivery_time($in) {
+    $this->delivery_time = $in;
+  }
+
+  public function get_delivery_time() {
+    return $this->delivery_time;
+  }
+
+  public function set_recipients_list($in) {
+    $this->recipients_list = $in;
+  }
+
+  public function get_recipients_list() {
+    return $this->recipients_list;
+  }
+
+  public function set_recipient_type($in) {
+    $this->recipient_type = $in;
+  }
+
+  public function get_recipient_type() {
+    return $this->recipient_type;
+  }
+
+  public function log_error($in) {
+    $this->errors[] = $in;
+  }
+
+  public function errors() {
+    return (count($this->errors) > 0);
+  }
+
+  public function get_error_array() {
+    return $this->errors;
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Request.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Request.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Request.php
new file mode 100755
index 0000000..85890e6
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Request.php
@@ -0,0 +1,174 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+* @file
+* Request - a data structure to hold all request-related parameters
+*
+* @author Rod Simpson <ro...@apigee.com>
+* @since 26-Apr-2013
+*/
+
+namespace Apache\Usergrid;
+
+require_once (dirname(__FILE__) . '/Exceptions.php');
+
+
+class Request {
+  /**
+   * @var string
+   */
+  private $method;
+  /**
+   * @var string
+   */
+  private $endpoint;
+  /**
+   * @var array
+   */
+  private $query_string_array; //an array of key value pairs to be appended as the query string
+  /**
+   * @var array
+   */
+  private $body;
+  /**
+   * @var bool
+   */
+  private $management_query;
+
+  /**
+   * Constructor for Request object
+   *
+   * @param string $method
+   * @param string $endpoint
+   * @param array $query_string_array
+   * @param array $body
+   * @param bool $management_query
+   */
+  public function __construct($method = 'GET', $endpoint = '', $query_string_array = array(), $body = array(), $management_query=FALSE) {
+		$this->method = $method;
+		$this->endpoint = $endpoint;
+		$this->query_string_array = $query_string_array;
+		$this->body = $body;
+		$this->management_query = $management_query;
+  }
+
+  /**
+   * Sets (and validates) the HTTP method.
+   *
+   * @param string $http_method
+   * @throws UGException
+   */
+  public function set_method($http_method){
+    if ($http_method !== 'GET' && $http_method !== 'POST' && $http_method !== 'PUT' && $http_method !== 'DELETE') {
+      throw new UGException("Unknown HTTP method type $http_method");
+    }
+    $this->method = $http_method;
+  }
+
+  /**
+   * Gets the HTTP method (GET, POST, PUT or DELETE)
+   *
+   * @return string
+   */
+  public function get_method(){
+    return $this->method;
+  }
+
+  /**
+   * Sets the endpoint base URL.
+   *
+   * @param $endpoint
+   */
+  public function set_endpoint($endpoint){
+    $this->endpoint = $endpoint;
+  }
+  /**
+   * Returns the endpoint base URL.
+   *
+   * @return string
+   */
+  public function get_endpoint(){
+    return $this->endpoint;
+  }
+
+  /**
+   * Sets the query-string array. This should be an associative key-value hash.
+   *
+   * @param array $in
+   */
+  public function set_query_string_array($key_value_pairs) {
+    if (!is_array($key_value_pairs)) {
+      throw new UGException('Request->query_string_array must be an array.');
+    }
+    $this->query_string_array = $key_value_pairs;
+  }
+  /**
+   * Returns the key-value associative array of query string values.
+   *
+   * @return array
+   */
+  public function get_query_string_array(){
+    return $this->query_string_array;
+  }
+
+  /**
+   * Sets the body array. This should be an array structure representing
+   * parameters sent via PUT/POST.
+   *
+   * @param array $body
+   */
+  public function set_body($body){
+    if (!is_array($body)) {
+      throw new UGException('Request->body must be an array.');
+    }
+    $this->body = $body;
+  }
+
+  /**
+   * Returns the body array.
+   *
+   * @return array
+   */
+  public function get_body(){
+    return $this->body;
+  }
+
+  /**
+   * Sets the boolean flag indicating whether this is a "management query" or
+   * not.
+   *
+   * @param bool $in
+   */
+  public function set_management_query($in){
+    //ensure we have a bool
+    $this->management_query = (bool)$in;
+  }
+
+  /**
+   * Returns flag indicating whether this is a "management query".
+   *
+   * @return bool
+   */
+  public function get_management_query(){
+    return $this->management_query;
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/lib/vendor/Apache/Usergrid/Response.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/lib/vendor/Apache/Usergrid/Response.php b/sdks/other/php/lib/vendor/Apache/Usergrid/Response.php
new file mode 100755
index 0000000..39467b7
--- /dev/null
+++ b/sdks/other/php/lib/vendor/Apache/Usergrid/Response.php
@@ -0,0 +1,90 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file
+ * Response - a data structure to hold all response-related parameters
+ *
+ * @author Rod Simpson <ro...@apigee.com>
+ * @since 26-Apr-2013
+ */
+
+namespace Apache\Usergrid;
+
+
+class Response extends Request{
+  private $data = array();
+  private $json = '';
+  private $curl_meta = array();
+  private $error = FALSE;
+  private $error_code = '';
+  private $error_message = '';
+
+  public function __construct($data = array(), $curl_meta = array(), $error = FALSE, $error_code = '', $error_message = '', $json = '') {
+		$this->data = $data;
+		$this->json = $json;
+		$this->curl_meta = $curl_meta;
+		$this->error = $error;
+		$this->set_error_code = $error_code;
+		$this->error_message = $error_message;
+  }
+
+  public function set_data($in){
+    $this->data = $in;
+  }
+  public function get_data(){
+    return $this->data;
+  }
+
+  public function set_json($in){
+    $this->json = $in;
+  }
+  public function get_json(){
+    return $this->json;
+  }
+
+  public function set_curl_meta($in){
+    $this->curl_meta = $in;
+  }
+  public function get_curl_meta(){
+    return $this->curl_meta;
+  }
+
+  public function set_error($in){
+    $this->error = $in;
+  }
+  public function get_error(){
+    return $this->error;
+  }
+
+  public function set_error_code($in){
+    $this->error_code = $in;
+  }
+  public function get_error_code(){
+    return $this->error_code;
+  }
+
+  public function set_error_message($in){
+    $this->error_message = $in;
+  }
+  public function get_error_message(){
+    return $this->error_message;
+  }
+}

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php/tests/autoloader.inc.php
----------------------------------------------------------------------
diff --git a/sdks/other/php/tests/autoloader.inc.php b/sdks/other/php/tests/autoloader.inc.php
new file mode 100644
index 0000000..3793355
--- /dev/null
+++ b/sdks/other/php/tests/autoloader.inc.php
@@ -0,0 +1,36 @@
+#!/usr/bin/env php
+<?php
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+function usergrid_autoload($class) {
+
+
+  if (strpos($class, '\\') !== FALSE) {
+    $path_parts = explode('\\', $class);
+    if ($path_parts[0] == 'Apache') {
+      $lib_path = realpath(dirname(__FILE__) . '/../lib/vendor');
+      $class_path = $lib_path . '/' . join('/', $path_parts) . '.php';
+      if (file_exists($class_path)) {
+        require_once($class_path);
+      }
+    }
+  }
+}
+
+spl_autoload_register('usergrid_autoload');

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/.gitignore
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/.gitignore b/sdks/other/php5/apache-usergrid/.gitignore
new file mode 100644
index 0000000..61ba991
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/.gitignore
@@ -0,0 +1,12 @@
+# Created by .gitignore support plugin (hsz.mobi)
+### Composer template
+composer.phar
+vendor/
+
+# dot env files
+.env.php
+.evn.*.php
+
+# Commit your application's lock file http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file
+# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
+# composer.lock

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/attrubites/attributes.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/attrubites/attributes.php b/sdks/other/php5/apache-usergrid/Examples/attrubites/attributes.php
new file mode 100644
index 0000000..0f4f180
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/attrubites/attributes.php
@@ -0,0 +1,122 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+include('data.php');
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+
+/**
+ * Attributes are a new feature that make getting related models easy as accessing a property on a model object
+ * The way relationships work before this feature it required you to call the getRelationship method on the application
+ * service which is still available, so for example you would first get the user then once you had the user you create a
+ * array that contained the uuid of the user the related collection name and the relationship name then call the api passing in the
+ * array but for the default relationships we already have the data that we need to make the api call so that is what
+ * I've done.
+ * <pre>
+ * <?php
+ *  $user = Usergrid::users()->findById(['uuid' => '1234abcd']) ;
+ *  $device = $user->device;
+ * ?>
+ * </pre>
+ *  That's all you need to do to get a device for the user this only works when you have one user in your user collection
+ *  if you call this with more then one user in your user collection it will return the device for the first user in the
+ *  collection.
+ *
+ */
+
+$user = Usergrid::users()->findById(['uuid' => '1234abcd']);
+
+echo "device" . PHP_EOL;
+var_dump($user->device);
+var_dump('=================================================================');
+
+echo "roles" . PHP_EOL;
+var_dump($user->roles);
+var_dump('=================================================================');
+
+echo "groups" . PHP_EOL;
+var_dump($user->groups);
+var_dump('=================================================================');
+
+echo "connections" . PHP_EOL;
+var_dump($user->connections);
+var_dump('=================================================================');
+
+
+var_dump('=================================================================');
+echo "GROUPS" . PHP_EOL;
+var_dump('=================================================================');
+
+
+$group = Usergrid::groups()->findById(['uuid' => '121212']);
+
+
+echo "roles" . PHP_EOL;
+var_dump($group->roles);
+var_dump('=================================================================');
+
+echo "groups" . PHP_EOL;
+var_dump($group->users);
+var_dump('=================================================================');
+
+echo "connections" . PHP_EOL;
+var_dump($group->connections);
+var_dump('=================================================================');
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/collections/books.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/collections/books.php b/sdks/other/php5/apache-usergrid/Examples/collections/books.php
new file mode 100644
index 0000000..034046e
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/collections/books.php
@@ -0,0 +1,130 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+include('data.php');
+
+use Apache\Usergrid\Api\Filters\Date;
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+
+foreach ($books_data as $book) {
+    Usergrid::application()->EntityJsonPost($book);
+}
+
+
+$books = Usergrid::application()->EntityGet(['collection' => 'books', 'limit' => 25]);
+
+
+// get result count just call the Illuminate\Support\Collection  count method
+var_dump($books->entities->count());
+
+
+// As responses are model object you can treat them like a assoc arrays
+var_dump($books->entities[0]['uuid']);
+
+// if you like a more object orientated way then use the Collection Class methods
+
+// get all uuid
+var_dump($books->entities->fetch('uuid'));
+
+//get first uuid
+var_dump($books->entities->fetch('uuid')->first());
+
+// get first item in collection -- this is the first item in my response php collection not the Usergrid Collection (table).
+var_dump($books->entities->first());
+
+// get last item in collection -- this is the last item in my response php collection not the Usergrid Collection (table).
+var_dump($books->entities->last());
+
+// convert created date to string
+var_dump(Date::convert($books->entities->fetch('created')->first()));
+
+// Illuminate\Support\Collection class support all advanced collection methods
+
+// pop last item off collection
+$book = $books->entities->pop();
+
+// Converting methods
+$json_ = $books->entities->toJson();
+
+//Convert the object into something JSON serializable.
+$books->entities->jsonSerialize();
+
+// Get an iterator for the items in collection
+$iterator = $books->entities->getIterator();
+
+//Get a CachingIterator instance
+$caching_iterator = $books->entities->getCachingIterator();
+
+/// Here are some more Methods that you can call on your responses .. To get the most out of this SDK please look at the Illuminate\Support\Collection class
+/// which is the supper class of Apache/Usergrid/Api/Models/BaseCollection class
+/**
+ * $books->unique();
+ * $books->transform();
+ * $books->take();
+ * $books->splice();
+ * $books->sum($callback );
+ * $books->values();
+ * $books->sortByDesc($callback);
+ * $books->sortBy();
+ * $books->shuffle();
+ * $books->chunk();
+ */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/collections/data.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/collections/data.php b/sdks/other/php5/apache-usergrid/Examples/collections/data.php
new file mode 100644
index 0000000..e9ca805
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/collections/data.php
@@ -0,0 +1,38 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+$books_data = [
+    ['collection' => 'books', 'title' => 'book one', 'name' => 'book_one', 'author' => 'author 1'],
+    ['collection' => 'books', 'title' => 'book two', 'name' => 'book_two', 'author' => 'author 2'],
+    ['collection' => 'books', 'title' => 'book three', 'name' => 'book_three', 'author' => 'author 3'],
+    ['collection' => 'books', 'title' => 'book four', 'name' => 'book_four', 'author' => 'author 4'],
+    ['collection' => 'books', 'title' => 'book five', 'name' => 'book_five', 'author' => 'author 5'],
+    ['collection' => 'books', 'title' => 'book six', 'name' => 'book_six', 'author' => 'author 6'],
+    ['collection' => 'books', 'title' => 'book seven', 'name' => 'book_seven', 'author' => 'author 7'],
+    ['collection' => 'books', 'title' => 'book eight', 'name' => 'book_eight', 'author' => 'author 8'],
+    ['collection' => 'books', 'title' => 'book nine', 'name' => 'book_nine', 'author' => 'author 9'],
+    ['collection' => 'books', 'title' => 'book ten', 'name' => 'book_ten', 'author' => 'author 10'],
+    ['collection' => 'books', 'title' => 'book eleven', 'name' => 'book_eleven', 'author' => 'author 11'],
+    ['collection' => 'books', 'title' => 'book twelve', 'name' => 'book_twelve', 'author' => 'author 12'],
+    ['collection' => 'books', 'title' => 'book thirteen', 'name' => 'book_thirteen', 'author' => 'author 13'],
+    ['collection' => 'books', 'title' => 'book fourteen', 'name' => 'book_fourteen', 'author' => 'author 14'],
+    ['collection' => 'books', 'title' => 'book fifteen', 'name' => 'book_fifteen', 'author' => 'author 15'],
+    ['collection' => 'books', 'title' => 'book sixteen', 'name' => 'book_sixteen', 'author' => 'author 16'],
+    ['collection' => 'books', 'title' => 'book seventeen', 'name' => 'book_seventeen', 'author' => 'author 17'],
+    ['collection' => 'books', 'title' => 'book eighteen', 'name' => 'book_eighteen', 'author' => 'author 18'],
+    ['collection' => 'books', 'title' => 'book nineteen', 'name' => 'book_nineteen', 'author' => 'author 19'],
+    ['collection' => 'books', 'title' => 'book twenty', 'name' => 'book_twenty', 'author' => 'author 20'],
+];

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/collections/users.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/collections/users.php b/sdks/other/php5/apache-usergrid/Examples/collections/users.php
new file mode 100644
index 0000000..da67ac3
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/collections/users.php
@@ -0,0 +1,120 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+include('data.php');
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/** The PHP SDK returns all responses as Illuminate\Support\Collection subclasses so the word collection below is php collection class not usergrid collection */
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+
+// call user by page size 20
+$users_paged = Usergrid::users()->all();
+var_dump(get_class($users_paged->entities));
+
+//// get user 50 page size
+$users_paged_50 = Usergrid::users()->all(['limit' => 50]);
+var_dump($users_paged_50->entities);
+
+// get all users
+$all_users = Usergrid::usersIterator();
+foreach ($all_users as $user) {
+//    var_dump($user['uuid']); // as array
+}
+
+// find user by query
+$find_user_by_query = Usergrid::users()->find(['ql' => "select * where email='jason@apps4u.com.au'"]);
+var_dump($find_user_by_query->entities->fetch('uuid'));
+
+$find_user_by_uuid = Usergrid::users()->findById(['uuid' => $find_user_by_query->entities->fetch('uuid')->first()]);
+var_dump($find_user_by_uuid->entities);
+
+
+// AS all results as PHP Collections and the entities property is always returned as a PHP Collection you can fetch nested records
+$user_addr = Usergrid::users()->findById(['uuid' => 'Jason']);
+echo $user_addr->entities->fetch('adr.addr1');
+//or
+echo $user_addr->entities->fetch('adr.city');
+
+// get users device URL -- nested fetch on php collection
+$users_nested = Usergrid::users()->all();
+var_dump($users_nested->entities->fetch('metadata.collections.devices')->first());
+
+// The response that is returned is a PHP collection that has a Zero indexed $item property.
+// but as its a collection class it has some methods that can help you find what you need and one
+// of my fav feature is changing the Zero indexed collection to be indexed by the entity uuid or name or any other property.
+$users_by = Usergrid::users()->all();
+
+$users_by_uuid = $users_by->entities->keyBy('uuid');
+var_dump($users_by_uuid->get('add uuid of user'));
+
+$users_by_name = $users_by->entities->keyBy('username');
+var_dump($users_by_name->get('jasonk'));
+
+$users_by_email = $users_by->entities->keyBy('email');
+var_dump($users_by_email->get('jasonk@apps4u.com.au'));
+
+// sort by key
+$sorted_by_email = $users_by->sortBy('username');
+var_dump($sorted_by_email);
+
+
+// add user to group
+//$user_to_group = Usergrid::groups()->addUser(['entity_name_or_uuid' => 'group_name_or_uuid', 'user_name_or_uuid' => 'user name or uuid']);
+
+//$user_remove_group = Usergrid::groups()->removeUser(['entity_name_or_uuid' => 'group_name_or_uuid', 'user_name_or_uuid' => 'user name or uuid']);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/examples.md
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/examples.md b/sdks/other/php5/apache-usergrid/Examples/examples.md
new file mode 100644
index 0000000..6bfdcd7
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/examples.md
@@ -0,0 +1,17 @@
+## Examples Read Me ##
+
+I don't show every method that you can call in the examples but I show you the most common api calls you will make but to get the most out of this api 
+you really should spend around 10 to 15 minutes to read all the guzzle web service descriptors files in the Manifest folders that are versioned the most 
+up to date version is 1.0.1 folder.
+
+### Manifest files ###
+Guzzle web service descriptors.
+
+You can use the files included with the sdk but you are able to create your own , so you can pass the path the the manifest folder in the config to the sdk. 
+The reason you might create you own is to support you own custom collections. So the way to do that is to copy the manifest folder to the location you want
+then there is a file called custom that you need to copy and edit so for example if I had a custom Collection called Books and I want to be able to call
+the sdk like ```Usergrid::books()->findById(['uuid'=> '12121']); ``` . All I have to do is copy the manifest file called custom and name it books and then 
+in the file replace the ```$custom``` with the word ```'books'``` .
+From that point on I can make api calls to my custom collection just like any of the default collection usergrid give you its a easy as that Ive designed this
+SDK to be extended so you can get the most out of your usergrid install .
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/examples.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/examples.php b/sdks/other/php5/apache-usergrid/Examples/examples.php
new file mode 100644
index 0000000..0348610
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/examples.php
@@ -0,0 +1,245 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+include('vendor/autoload.php');
+
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => './src/Manifests', //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'application',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'password',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+/** Usergrid Facades Off */
+
+//call the bootstrap class that will create the api client then get the usergrid instance from the bootstrapper
+$bootstrapper = new UsergridBootstrapper($config);
+$usergrid = $bootstrapper->createUsergrid();
+
+/** Note: I'm using Users for the first lot of example's but you could do the same for all default collections eg: groups, devices, roles, notification etc*/
+
+// All responses are model objects that subclass the baseCollection class so all collection methods are available eg: first(), map(), fetch(), hasValue(), hasKey() etc.
+
+//find users with query
+$user = $usergrid->users()->find(['ql' => 'select * where activated=true']);
+
+//var_dump($user->entities->first());
+
+//request that throw exception in this case 404 not found
+try {
+
+    $user2 = $usergrid->users()->findById(['uuid' => 'uuid-number']);
+//    var_dump($user2->get('entities'));
+} catch (Apache\Usergrid\Api\Exception\NotFoundException $e) {
+
+//    var_dump($e->getResponse());
+}
+/**
+ * There a errors for all Usergrid response errors and http errors so you can create a catch all error class or plug it into your fav php frameworks error handling.
+ * Apache\Usergrid\Api\Exception\BadRequestException = http 400
+ * Apache\Usergrid\Api\Exception\UnauthorizedException = http 401
+ * Apache\Usergrid\Api\Exception\RequestFailedException = http 402
+ * Apache\Usergrid\Api\Exception\NotFoundException = http 404
+ * Apache\Usergrid\Api\Exception\ServerErrorException = http 500
+ * Apache\Usergrid\Api\Exception\ServerErrorException = http 502
+ * Apache\Usergrid\Api\Exception\ServerErrorException = http 503
+ * Apache\Usergrid\Api\Exception\ServerErrorException = http 504
+ */
+
+// collection Iterators no need to keep calling request with a cursor to get all entities in a collection
+// UserIterator(), DeviceIterator() GroupsIterator() , RolesIterator() etc.
+$user_iterator = $usergrid->usersIterator();
+
+foreach ($user_iterator as $iUser) {
+    var_dump($iUser);
+    var_dump("---------------------------------------------------------------------------------");
+}
+
+// create new user
+$new_user = ['name' => 'jasonk', 'username' => 'JasonK', 'email' => 'jason@example.com', 'password' => 'some_password'];
+//$created_user = $usergrid->users()->create($new_user);
+//var_dump($created_user->entities);
+
+//Update Users by name or uuid
+$new_email = ['email' => 'jason@example', 'entity_name_or_uuid' => 'benn'];
+$updated_user = $usergrid->users()->update($new_email);
+//var_dump($updated_user->entities);
+
+// delete a user
+//$deleted_user = $usergrid->users()->delete(['entity_name_or_uuid' => 'benn']);
+//var_dump($deleted_user);
+
+//get custom collection
+$custom_collection = $usergrid->application()->EntityGet(['collection' => 'shops']);
+//var_dump($custom_collection->entities->get('name'));
+
+//get custom collection with query
+$custom_collection_query = $usergrid->application()->EntityGet([
+    'collection' => 'shops',
+    'ql' => "select * where country='aus'"
+]);
+//var_dump($custom_collection_query->get('entities'));
+
+// Post custom collection as JSON data
+$custom_entity = [
+    'collection' => 'shops',
+    'name' => 'shop_name',
+    'adr' => ['street' => '1 main st', 'location' => 'sydney', 'post_code' => '2323'],
+    'type' => 'pet_shop'
+];
+//$created_entity = $usergrid->application()->EntityJsonPost($custom_entity);
+//var_dump($created_entity->entities);
+
+// update custom Entity
+$custom_entity_edit = [
+    'collection' => 'shops',
+    'entity_name_or_uuid' => '918a044a-618a-11e4-8c11-253e9c3723a9',
+    ['adr' => ['street' => '3 main st', 'location' => 'act', 'post_code' => '3323']]
+];
+$edited_entity = $usergrid->application()->EntityPut($custom_entity_edit);
+
+
+/** Usergrid Facades On */
+
+//create a bootstrap instance and then call the static instance method on the Usergrid facade
+$bootstrapper2 = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper2);
+
+
+// find users with query
+$fUser = Usergrid::users()->find(['ql' => 'select * where activated=true']);
+
+$fUser_iterator = Usergrid::usersIterator();
+
+foreach ($fUser_iterator as $iUser) {
+    var_dump($iUser);
+    var_dump("---------------------------------------------------------------------------------");
+}
+
+// create new user
+$fNew_user = [
+    'name' => 'jasonk',
+    'username' => 'JasonK2',
+    'email' => 'jaso2n@example.com',
+    'password' => 'some_password'
+];
+$fCreated_user = Usergrid::users()->create($fNew_user);
+//var_dump($fCreated_user->entities);
+
+//Update Users by name or uuid
+$fNew_email = ['email' => 'jason@example', 'entity_name_or_uuid' => 'benn'];
+$fUpdated_user = Usergrid::users()->update($fNew_email);
+//var_dump($fUpdated_user->entities);
+
+// delete a user
+$fDeleted_user = Usergrid::users()->delete(['entity_name_or_uuid' => 'benn']);
+//var_dump($fDeleted_user->entities);
+
+//get custom collection
+$fCustom_collection = Usergrid::application()->EntityGet(['collection' => 'shops']);
+//var_dump($custom_collection->get('entities'));
+
+//get custom collection with query
+$fCustom_collection_query = Usergrid::application()->EntityGet([
+    'collection' => 'shops',
+    'ql' => "select * where country='aus'"
+]);
+//var_dump($custom_collection_query->get('name'));
+
+// Post custom collection as JSON data
+$fCustom_entity = [
+    'collection' => 'shops',
+    'name' => 'shop_name3',
+    'adr' => ['street' => '1 main st', 'location' => 'sydney', 'post_code' => '2323'],
+    'type' => 'pet_shop'
+];
+$fCreated_entity = Usergrid::applictions()->EntityJsonPost($custom_entity);
+//var_dump($fCreated_entity->entities);
+
+// update entity
+$fCustom_entity_edit = [
+    'collection' => 'shops',
+    'entity_name_or_uuid' => 'shop_name2',
+    ['adr' => ['street' => '3 main st', 'location' => 'act', 'post_code' => '3323']]
+];
+$fEdited_entity = Usergrid::applications()->EntityPut($fCustom_entity_edit);
+//var_dump($fEdited_entity->entities);
+
+
+/** Relationships */
+$related_data = [
+    'collection' => 'required',
+    'entity_id' => 'required',
+    'relationship' => 'required',
+    'ql' => 'optional'
+];
+$get_relationship = Usergrid::application()->GetRelationship($related_data);
+
+
+$create_relationship_data = [
+    'collection' => 'required',
+    'first_entity_id' => 'required',
+    'relationship' => 'required',
+    'second_entity_id' => 'required'
+];
+$new_relationship = Usergrid::application()->CreateRelationship($create_relationship_data);
+
+
+/** Groups  */
+
+//add user to group
+$fAdd_user_to_group_data = [
+    'entity_name_or_uuid' => 'group_name',
+    'user_name_or_uuid' => 'username'
+];
+$fAdded_user_to_group = Usergrid::groups()->addUser($fAdd_user_to_group_data);
+
+//delete user from group
+$fDeleted_user_from_group = Usergrid::groups()->deleteUser($fAdd_user_to_group_data);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/management/management.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/management/management.php b/sdks/other/php5/apache-usergrid/Examples/management/management.php
new file mode 100644
index 0000000..cfc5d61
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/management/management.php
@@ -0,0 +1,91 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+/**
+ * When working with the management api any calls that require a application to target will use the default app name set in the config but some times you may want to
+ * make a api call to a different application which is possible when the url requires a application name it taken from the config but if you pass in a different application
+ * name in the method arguments it will override the default application name just for that api call so If I wanted to add a user to two application I could make the same call
+ * twice but pass in a application name only for the 2nd call.
+ */
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+
+// Get organization activity
+$activity_feed = Usergrid::management()->OrgFeedGet();
+
+// get org details
+$organization_details = Usergrid::management()->OrgGet();
+
+//get organizations application
+$organization_applications = Usergrid::management()->OrgAppsGet();
+
+//create application
+$app = ['name' => 'app name -- required'];
+$new_application = Usergrid::management()->OrgAppsJsonPost($app);
+
+// delete application
+$deleted_application = Usergrid::management()->OrgAppDelete($app);
+
+//get irg admin users
+$organization_admin_users = Usergrid::management()->OrgUsersGet();
+
+/** There are many more api calls just look at the management manifest file to get the method name's and arguments to pass .
+ * The management manifest file is a copy of the swagger file for usergrid so you can also run the swagger UI tool on your usergrid install as well.
+ */
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/messages/data.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/messages/data.php b/sdks/other/php5/apache-usergrid/Examples/messages/data.php
new file mode 100644
index 0000000..5d00ec4
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/messages/data.php
@@ -0,0 +1,17 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+$message = [];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/messages/messages.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/messages/messages.php b/sdks/other/php5/apache-usergrid/Examples/messages/messages.php
new file mode 100644
index 0000000..0eded4a
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/messages/messages.php
@@ -0,0 +1,62 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+include('data.php');
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/notifications/data.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/notifications/data.php b/sdks/other/php5/apache-usergrid/Examples/notifications/data.php
new file mode 100644
index 0000000..0efdf85
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/notifications/data.php
@@ -0,0 +1,17 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+$notification = [];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/notifications/notifications.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/notifications/notifications.php b/sdks/other/php5/apache-usergrid/Examples/notifications/notifications.php
new file mode 100644
index 0000000..1a76ef8
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/notifications/notifications.php
@@ -0,0 +1,86 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+
+include('data.php');
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1', // set manifest version
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => null, //leave as default or change to your own custom folder
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => '',
+        'password' => '',
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+
+// to user
+$to_user = Usergrid::notifications()->toUser();
+
+
+//to users
+$to_users = Usergrid::notifications()->toUsers();
+
+
+//to group
+$to_group = Usergrid::notifications()->toGroup();
+
+
+// to groups
+$to_groups = Usergrid::notifications()->toGroups();
+
+
+// to device
+$to_device = Usergrid::notifications()->toDevice();
+
+
+// to devices
+$to_devices = Usergrid::notifications()->toDevices();

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/Examples/notifications/notifiers.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/Examples/notifications/notifiers.php b/sdks/other/php5/apache-usergrid/Examples/notifications/notifiers.php
new file mode 100644
index 0000000..e32f6f4
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/Examples/notifications/notifiers.php
@@ -0,0 +1,79 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+include('vendor/autoload.php');
+include('data.php');
+
+use Apache\Usergrid\Native\Facades\Usergrid;
+use Apache\Usergrid\Native\UsergridBootstrapper;
+
+
+/** Source your config from file I'm using array here just for ease of use.
+ * When using Laravel Framework publish the package config file when using with
+ * other modern PHP frameworks just use their default config system .
+ */
+$config = [
+    'usergrid' => [
+        'url' => 'https://api.usergrid.com',
+        'version' => '1.0.1',
+        'orgName' => '',
+        'appName' => '',
+        'manifestPath' => './src/Manifests',
+        'clientId' => '',
+        'clientSecret' => '',
+        'username' => null,
+        'password' => null,
+        /**
+         * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+         * Token from.  You have two options here one is 'application' the other is 'organization'
+         *
+         *  organization will get the the token from http://example.com/management using  client_credentials or password grant type
+         *  application will get the token from http://example.com/managment/org_name/app_name using client_credentials or password grant type
+         */
+        'auth_type' => 'organization',
+        /** The Grant Type to use
+         *
+         * This has to be set to one of the 2 grant types that Apache Usergrid
+         * supports which at the moment is client_credentials or password but at
+         * 2 level organization or application
+         */
+        'grant_type' => 'client_credentials',
+        /**
+         * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+         * */
+        'enable_oauth2_plugin' => true
+    ]
+];
+
+// You need to add a push cert to this folder and pass the path in the apple_notifier_data array
+
+$bootstrapper = new UsergridBootstrapper($config);
+Usergrid::instance($bootstrapper);
+
+//create Apple Notifier
+$apple_notifier_data = [
+    'name' => 'apple_test',
+    'environment' => 'development',
+    'p12Certificate' => @'pushtest_dev.p12'
+];
+$apple_notifier = Usergrid::notifiers()->createApple($apple_notifier_data);
+
+// create Google Notifier
+$google_notifier_data = [
+    'name' => 'google_test',
+    'apiKey' => 'AIzaSyCIH_7WC0mOqBGMOXyQnFgrBpOePgHvQJM',
+    'provider' => 'google'
+];
+$google_notifier = Usergrid::notifiers()->createGoogle($google_notifier_data);
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/LICENSE
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/LICENSE b/sdks/other/php5/apache-usergrid/LICENSE
new file mode 100644
index 0000000..e06d208
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/LICENSE
@@ -0,0 +1,202 @@
+Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "{}"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright {yyyy} {name of copyright owner}
+
+   Licensed under the Apache License, Version 2.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://www.apache.org/licenses/LICENSE-2.0
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/README.md
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/README.md b/sdks/other/php5/apache-usergrid/README.md
new file mode 100644
index 0000000..567f3f1
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/README.md
@@ -0,0 +1,219 @@
+# README 
+
+This a Guzzle Web Service Client and Service Descriptor to work with the Apache Usergrid Management and Application API . 
+
+## Getting Started 
+
+install as composer package by adding this to your composer.json file.
+
+``` 
+    "apache-usergrid" : "dev-master" 
+```
+
+and add the URL to the repositories section within your composer.json file.
+
+```
+    "repositories": [{
+        "type" : "vcs",
+        "url" : "https://apps4u@bitbucket.org/apps4u/apache-usergrid.git"
+    }]
+```
+
+import the classes ``` include autoload.php ``` then create a new instance of the class with a path to you config file
+or native use just create a config file
+
+
+
+    use Apache\Usergrid\UsergridBootstrapper;
+    $config = [    
+    'usergrid' => [
+                       'url' => 'https://api.usergrid.com',
+                       'version' => '1.0.0',
+                       'orgName' => '',
+                       'appName' => '',
+                       'manifestPath' => './src/Manifests',
+                       'clientId' => '',
+                       'clientSecret' => '',
+                       'username' => '',
+                       'password' => '',
+                       /**
+                        * The Auth Type setting is the Oauth 2 end point you want to get the OAuth 2
+                        * Token from.  You have two options here one is 'application' the other is 'organization'
+                        *
+                        *  organization will get the the token from http://example.com/management/token using  client_credentials or password grant type
+                        *  application will get the token from http://example.com/org_name/app_name/token using client_credentials or password grant type
+                        */
+                       'auth_type' => 'application',
+                       /** The Grant Type to use
+                        *
+                        * This has to be set to one of the 2 grant types that Apache Usergrid
+                        * supports which at the moment is client_credentials or password.
+                        */
+                       'grant_type' => 'client_credentials'
+                        /**
+                        * if you want to manage your own auth flow by calling the token api and setting the token your self just set this to false
+                        * */
+                       'enable_oauth2_plugin' => true
+                   ]
+             ];
+                   
+                   $bootstrap = new UsergridBootstrapper($config);
+                   $usergrid = $bootstrap->createUsergrid();
+                   $collection =$usergrid->application()->getEntity(['collection' => 'shops']);
+
+
+## Or if you like Static Facades
+
+```
+     $bootstrap = new UsergridBootstrapper($config);
+     Usergrid::instance($bootstrap);
+     $res = Usergrid::application()->EntityGet(['collection' => 'shops']);
+```
+
+
+### Laravel
+
+In Laravel once you have install the composer package you then publish the config file like ```php artisan config:publish apache/usergrid ``` which will publish the config file to the app/config/packages/apache/usergrid/config.php 
+then add your client_id and secret to the config file the set the service provider in the app/config.php providers array ```Apache\Usergrid\Laravel\ApacheUsergridServiceProvider``` and add the alias to
+the aliases array ```'Usergrid' => 'Apache\Usergrid\Laravel\Facades\Usergrid``` to be able to access class via a Facade. Example for Laravel
+
+```
+    $collection = Usergrid::application()->EntityGet(['collection' => 'shops']);
+```
+
+## how it works
+
+ You have one main client called Usergrid so if I wanted to call the Management Api and I have Facades enabled then
+ I would call like this ```Usergrid::Management->OrgAppsGet();``` or ```Usergrid::Application->EntityGet();```
+ 
+ There is one top level manifest file called Manifest.php and contain only top level Guzzle service descriptor properties and a empty operations array so 
+ when calling ```php Usergrid::Management()->OrgAppsGet() ```  the Main Manifest file has the operation array filled in by the Management Manifest files operations array
+ and they are cached by the Usergrid web service client. Calls on the Usergrid client are like magic method in the sense that ```php Usergrid::Management()-> method``` call is not
+ backed by a Management class or method its the Manifest that it being selected . Also by using Facades all method are like static method and fit in with newer PHP frameworks just like using the
+ AWS PHP SDK when calling enableFacades() on the AWS factory method.
+ 
+ All responses are subclasses of Illuminate\Support\Collection class so all collection methods are available to call on your response model eg: first(), get(), map(), fetch(), hasKey(), hasValue(), etc.
+ this is not to mistake this with a Usergrid collection which is like your DB table they too are collection object but if you get a response of a single entity then its a Collection with a count of 1.
+ 
+ 
+ 
+### Error Handling 
+
+All HTTP and Server error returned by the Usergrid API have error classes attached to the services descriptors so to handle error's that you want too, Just catch the correct exception eg. resource not found.
+
+```
+    try {
+     $collection = Usergrid::Application()->GetEntity(['collection' => 'shops', 'uuid' => 'not found uuid']);
+    } catch(NotFoundException $e) {
+        // Handle resource not found
+    }
+```
+ 
+### Authentication
+
+  You can manage your own Oauth 2 flow by setting the enable_oauth2_plugin config setting to false then you need to call the Token api or get the token from elsewhere and then set the token on the usergrid instance.
+  By default this will manage Oauth2 flow for you and I recommend that you leave it set to true. But if you want to do it yourself set the config setting to false and then do something like this.
+  
+```
+    $res  =  Usergrid::management()->authPasswordGet($array);
+    $token = $res->get('access_token');
+    Usergrid::setToken($token)->users()->findById(['uuid' => '1234']);
+```
+ 
+ Authentication for Apache Usergrid uses OAuth-2 protocol and has 4 levels of authentication.
+ 
+* Organization Token  Top level organization access the token is for the organization.
+* Organization Admin Token Top level Admin user this token is the organizations admin users.
+* Application Token  Per Application token that is for the application.
+*  Application User Token User level access this token is for a logged in user.
+ 
+ The Organization and Application token's when using client_credentials should only be used in a server side application as it has full access to all resources.
+ The Organization Token can access all applications and edit Organization details. The Application token has full access to all application 
+ resources. The Admin user token is the organization admin user so it too has access to all Applications and Organizations and the last level which is a User
+ Token that is a per application user and will have access to all resources that roles attached to that user can access.
+ 
+So there are two settings in the config that controls which type of token you get.
+the ```'auth_type' => 'application' ``` controls the level you get Organization or Application and the ``` 'grant_type' => 'client_credentials'``` controls
+which type of credentials you use which can be either `client_credentials` or `password` using client_id & client_secret or username & password.
+
+### Result Iteration
+Apache Usergrid has a default paging size of 10 records so if you ask for a collection that has more then 10 result (entities) then it will return 
+a Cursor so you can pass it to the next request to get then next lot of 10 results so Ive made this easier. Using manifest version 1.0.1 and above you can now use a resource iterator  
+that will return all entities for you in one request. So again let the SDK do the hard work for you. Resource Iterators as lazy loaded so they only make the api call if the data is needed 
+for example when you first make the call no data is requested from the network but as soon as you dereference the data then the first page is requested and the 2nd page is not requested till
+you request the data for example if I used it in a foreach loop it will make a network request for the next page of data only after the loop has gone through the current page count and if you cancel the 
+foreach loop then it wont request any more data the default page size is 20 for resource iterators.
+
+The SDK will check each response to see if their is a cursor and if there is it will get the next set till all entities are returned.
+```
+    $allDevices = Usergrid::DevicesIterator();
+    foreach($allDevices as $device) {
+    // this will have all devices. 
+    }
+```
+# NEW feature - Attributes
+### Attributes (relationships) 
+The Usergrid PHP SDK has api call on the application service to get a related models but it requires that you make two api calls one to get the entity then a 2nd to get the relationship eg:
+
+```
+$users = Usergrid::users()->all(['limit' => 1]);
+$user_uuid = $users-entities->fetch('uuid');
+$data = [ 'collection' => 'users', 'entity_id' => $user_uuid, 'relationship' => 'devices'];
+$device = Usergrid::application()->GetRelationship($data);
+```
+
+Now the data we require for you to make the relationship api call is already in the SDK we should not force you to make a 2nd api call and give us data we already have. so now you don't need to any more. Just access the default relationships as a property on your response Model.
+
+```
+    $users = Usergrid::users()->all();
+    $user = $users->entities->get(0);
+    $device = $user->device;
+```
+
+that's it, So the take away point is let the SDK do the work for you and if you create custom service descriptors and model classes for your custom collection then look at the User response
+model class at it's deviceAttribute method to see how you can either add it to your custom collections or add custom relationship attributes to the default collections. Remember the SDK is designed
+for you to be able to extend the Guzzle service descriptors (manifest files).
+
+
+### HTTP headers and UserAgents
+
+ When working with http clients & server system you may want to sett additional HTTP Headers. Ive have made this easy as well on the Usergrid class you 
+ can set any http headers or access token or user agent when calling the set method it will append new headers or replace headers already set so if you 
+ have some customer analytics set up on your version of usergrid server then just pass the headers you like in a fluent way eg:
+ ``` Usergrid::setHeaders(['BAAS-PLATFORM-ANALYTICS' => 'user001'])->users()->findById(['uuid' => '12343']); ```
+ 
+
+
+## Manifest Files (Guzzle & Swagger  Service Descriptors)
+
+All the files in the manifest folder are just temp file the final Service Descriptors are versioned so
+the real files are in the manifest/1.0.0 folder so as usergrid is updated new versions can be added like 1.1.0 etc.
+Ill leave the other manifest file there for now but will cleanup when Apache Usergrid accepts this library.
+
+## designs guidelines
+
+The design of this is to make it easy to add to existing project and be able to map Model objects in your project 
+to response models for example in my project I have a organization object that is saved in a mysql database and I can
+call a Usergrid Api call on that model object just like using the Usergrid api class eg:
+``` Usergrid::Management->putOrganization($data_array) ``` is the same as
+``` Organization::put($data_array) ``` how to do this is beyond the scope of the SDK but its not hard to create 
+Gateway Objects using php Traits
+
+## PHPUnit Tests
+Some unit tests require a internet connection and a usergrid install so they have been marked with a phpunit @group annotation so to run the tests without a usergrid install just pass the ```--exclude-group internet``` as a option on the command line or IDE setting
+that will exclude the few tests that require access to usergrid which I've limited to only a few unit tests like testing if it can get a oauth2 access_token. 
+
+## Javascript
+
+There is a javascript api to go with this for example I have a site that uses the javascript sdk to login to Apache Usergrid then it send the token server side 
+to be used in api calls on behalf of the logged in user. You can find this javascript sdk in my public git repo it requires one extra config setting and then you include
+the javascript file in your page  It's set to works with Laravel as it posts the token to a route but it would not be hard to use else where just create uri it can post the token too. Its not part of this SDK so think
+of it as a helper as some times it good to have access to both world server side calls for long running or large result sets and Ajax calls to update UI using the one login token for both type of calls.
+
+
+### Contribution guidelines
+* Please help if you like this.
+* Writing tests
+* Code review
+* Code
+* Manifest files

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/TODO.md
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/TODO.md b/sdks/other/php5/apache-usergrid/TODO.md
new file mode 100644
index 0000000..9038491
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/TODO.md
@@ -0,0 +1,2 @@
+## To Do ##
+PHP unit tests , I need to create test for most API calls 
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/composer.json
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/composer.json b/sdks/other/php5/apache-usergrid/composer.json
new file mode 100644
index 0000000..14341a9
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/composer.json
@@ -0,0 +1,40 @@
+{
+    "name": "apache/usergrid",
+    "description": "Apache Usergrid PHP SDK guzzle web service client and service descriptor to interact with usergrid management and application api",
+    "minimum-stability": "stable",
+    "license": "Apache",
+    "authors": [
+        {
+            "name": "Jason Kristian",
+            "email": "jasonk@apps4u.com.au"
+        }
+    ],
+    "repositories": [
+        {
+            "type" : "vcs",
+            "url" : "https://apps4u@bitbucket.org/apps4u/apache-usergrid.git"
+        }
+    ],
+    "require": {
+        "guzzle/guzzle": "3.9.*",
+        "illuminate/support": "~4.2",
+        "nesbot/carbon": "~1.0"
+
+    },
+    "require-dev": {
+        "mockery/mockery": "~0.9",
+        "phpunit/phpunit": "~4.0"
+    },
+    "autoload": {
+        "classmap": [],
+        "psr-4": {
+            "Apache\\Usergrid\\": "src/"
+        }
+    },
+    "extra": {
+        "branch-alias": {
+            "dev-master": "master"
+        }
+    }
+
+}


[20/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Application.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
new file mode 100644
index 0000000..94f9c58
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Application.php
@@ -0,0 +1,1108 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'AuthPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
+        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
+        'summary' => 'Get app access token',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'query',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthPasswordPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/token',
+        'notes' => 'Get the app access token.  See the OAuth2 specification for details.',
+        'summary' => 'Get app access token',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'grant_type' => [
+                'description' => 'Grant type.',
+                'location' => 'postField',
+                'type' => 'string',
+                'defaultValue' => 'password',
+                'required' => true,
+            ],
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'username' => [
+                'description' => 'Username (for grant_type=password).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'password' => [
+                'description' => 'Password (for grant_type=password).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID (for grant_type=client_credentials).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_secret' => [
+                'description' => 'Client Secret (for grant_type=client_credentials).',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthorizeGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
+        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
+        'summary' => 'Authorize app client',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'response_type' => [
+                'description' => 'Response type',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'default' => 'token'
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'AuthorizePost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/authorize',
+        'notes' => 'Authorize the app client.  See the OAuth2 specification.',
+        'summary' => 'Authorize app client',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'response_type' => [
+                'description' => 'Response type',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+                'default' => 'token'
+            ],
+            'redirect_uri' => [
+                'description' => 'Redirect URI',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'client_id' => [
+                'description' => 'Client ID',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'scope' => [
+                'description' => 'Access Token Scope.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'state' => [
+                'description' => 'Client State.',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'CredentialsGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
+        'notes' => 'Get the app client credentials.',
+        'summary' => 'Get app client credentials',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'CredentialsPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/credentials',
+        'notes' => 'Generate new app client credentials',
+        'summary' => 'Generate app client credentials',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'access_token' => [
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'The OAuth2 access token'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
+        'notes' => 'Create new app user',
+        'summary' => 'Create new app user.  See Usergrid documentation for JSON format of body.',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'username' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'json',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users',
+        'notes' => 'Create new app user',
+        'summary' => 'Create new app user using form post parameters.',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'username' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Username'
+            ],
+            'name' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Name'
+            ],
+            'email' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Email'
+            ],
+            'password' => [
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Admin Password'
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordRestGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/resetpw',
+        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'summary' => 'Initiate a user password reset',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid]/{app_name_or_uuid}/users/resetpw',
+        'notes' => 'Complete a user password reset.  Handles form POST response.',
+        'summary' => 'Complete a user password reset',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'email' => [
+                'description' => 'User Email',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_challenge_field' => [
+                'description' => 'Recaptcha Challenge Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_response_field' => [
+                'description' => 'Recaptcha Response Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'notes' => 'Returns the app user details.',
+        'summary' => 'Returns the app user details',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}',
+        'notes' => 'Updates the app user details.',
+        'summary' => 'Updates the app user details',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            'location' => 'json'
+        ]
+    ],
+    'UserActivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/activate',
+        'notes' => 'Activates the app user from link provided in email notification.',
+        'summary' => 'Activates the app user',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'token' => [
+                'description' => 'Activation Token (supplied via email)',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'confirm' => [
+                'description' => 'Send confirmation email',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserReactivateGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/reactivate',
+        'notes' => 'Request app user reactivation.',
+        'summary' => 'Reactivates the app user',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserFeedGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/feed',
+        'notes' => 'Get app user activity feed.',
+        'summary' => 'Get app user activity feed',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserPasswordJsonPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/password',
+        'notes' => 'Set app user password.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Set app user password',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Old and new password",
+            'location' => 'json'
+        ]
+    ],
+    'UserResetPasswordGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
+        'notes' => 'Initiate a user password reset.  Returns browser-viewable HTML page.',
+        'summary' => 'Initiate a user password reset',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'UserResetPasswordFormPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/users/{user_username_email_or_uuid}/resetpw',
+        'notes' => 'Complete a user password reset.  Handles form POST response.',
+        'summary' => 'Complete a user password reset',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'user_username_email_or_uuid' => [
+                'description' => 'User username, email or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_challenge_field' => [
+                'description' => 'Recaptcha Challenge Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'recaptcha_response_field' => [
+                'description' => 'Recaptcha Response Field',
+                'location' => 'postField',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'EntityGet' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'EntityJsonPost' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app entity',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'EntityPut' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update an app entity in a collection.',
+        'summary' => 'Update an app entity',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'EntityDelete' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete an app entity.',
+        'summary' => 'Delete an app entity',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'PostEvents' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create Event.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app event',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    //Application Collection Relationships
+    'GetRelationship' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_id}/{relationship}',
+        'notes' => 'Query an Entity Relationship ',
+        'summary' => 'Query an Entity Relationship',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_id' => [
+                'description' => 'Entity  ID (uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'relationship' => [
+                'description' => 'Relationship',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'CreateRelationship' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{first_entity_id}/{relationship}/{second_entity_id}',
+        'notes' => 'Create new app entity.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new app entity',
+        'responseClass' => '',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'first_entity_id' => [
+                'description' => 'first entity id (uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'relationship' => [
+                'description' => 'relationship',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'second_entity_id' => [
+                'description' => '2nd entity id (uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
new file mode 100644
index 0000000..a51055f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Assets.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [],
+    'find' => [],
+    'create' => [],
+    'destroy' => [],
+    'update' => []
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
new file mode 100644
index 0000000..b89e805
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Custom.php
@@ -0,0 +1,381 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query an app collection.',
+        'summary' => 'Query an app collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'find' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query Users.',
+        'summary' => 'Query the users collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'findById' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
+        'notes' => 'Find User by uuid.',
+        'summary' => 'Find user by uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'uuid' => [
+                'description' => 'User UUID (entity uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'create' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new User.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new User entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'destroy' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete a User entity.',
+        'summary' => 'Delete a User entity by name or uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'update' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update a User entity.',
+        'summary' => 'Update a User entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\User',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => $custom
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ]
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
new file mode 100644
index 0000000..65aa01d
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
@@ -0,0 +1,465 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Get All devices.',
+        'summary' => 'Get all Device collection limit 10000',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false
+
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'find' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Query Devices.',
+        'summary' => 'Query the devices collection',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'findById' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
+        'notes' => 'Find Device by uuid.',
+        'summary' => 'Find device by uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'uuid' => [
+                'description' => 'Group UUID (entity uuid)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+    'create' => [
+        'httpMethod' => 'POST',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
+        'notes' => 'Create new Device.  See Usergrid documentation for JSON format of body.',
+        'summary' => 'Create new Device entity',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'destroy' => [
+        'httpMethod' => 'DELETE',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Delete a Device entity.',
+        'summary' => 'Delete a Device entity by name or uuid',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ]
+    ],
+    'update' => [
+        'httpMethod' => 'PUT',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
+        'notes' => 'Update a Device entity.',
+        'summary' => 'Update a Device entity by name or uuid and using JSON data',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Device',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'entity_name_or_uuid' => [
+                'description' => 'entity name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Entity data",
+            'location' => 'json'
+        ]
+    ],
+    'notifiers' => [
+        'httpMethod' => 'GET',
+        'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{device_uuid}/notifier',
+        'notes' => 'Get All device notifiers.',
+        'summary' => 'Get all Device notifiers',
+        'responseClass' => 'Apache\Usergrid\Api\Models\Notifier',
+        'responseType' => 'class',
+        'errorResponses' => $errors,
+        'parameters' => [
+            'app_name_or_uuid' => [
+                'description' => 'app name or uuid',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'org_name_or_uuid' => [
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'description' => 'Organization name or uuid'
+            ],
+            'collection' => [
+                'description' => 'collection name (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+                'default' => 'devices'
+            ],
+            'device_uuid' => [
+                'description' => 'device uuid (entity type)',
+                'location' => 'uri',
+                'type' => 'string',
+                'required' => true,
+            ],
+            'access_token' => [
+                'description' => 'The OAuth2 access token',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'ql' => [
+                'description' => 'a query in the query language',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'reversed' => [
+                'description' => 'return results in reverse order',
+                'location' => 'query',
+                'type' => 'boolean',
+                'required' => false,
+            ],
+            'start' => [
+                'description' => 'the first entity UUID to return',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'cursor' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'string',
+                'required' => false,
+            ],
+            'limit' => [
+                'description' => 'an encoded representation of the query position for paging',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false
+
+            ],
+            'filter' => [
+                'description' => 'a condition to filter on',
+                'location' => 'query',
+                'type' => 'integer',
+                'required' => false,
+            ]
+        ],
+        'additionalParameters' => [
+            "description" => "Other parameters",
+            'location' => 'query'
+        ]
+    ],
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
new file mode 100644
index 0000000..3230dbd
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Errors.php
@@ -0,0 +1,50 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\BadRequestException',
+        'code' => 400,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\UnauthorizedException',
+        'code' => 401,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\RequestFailedException',
+        'code' => 402,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\NotFoundException',
+        'code' => 404,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 500,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 502,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 503,
+    ],
+    [
+        'class' => 'Apache\Usergrid\Api\Exception\ServerErrorException',
+        'code' => 504,
+    ],
+];
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
----------------------------------------------------------------------
diff --git a/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Events.php b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
new file mode 100644
index 0000000..a51055f
--- /dev/null
+++ b/sdks/other/php5/apache-usergrid/src/Manifests/1.0.1/Events.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+return [
+
+    'all' => [],
+    'find' => [],
+    'create' => [],
+    'destroy' => [],
+    'update' => []
+];
\ No newline at end of file


[29/45] usergrid git commit: Moving older SDKs to a difference location and updating main README to link to new SDK locations.

Posted by mr...@apache.org.
http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGEntityViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGEntityViewController.h b/sdks/other/ios/samples/Browser/browser/UGEntityViewController.h
new file mode 100644
index 0000000..af95c4c
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGEntityViewController.h
@@ -0,0 +1,22 @@
+//
+//  UGEntityViewController.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@interface UGEntityViewController : UITableViewController
+@property (nonatomic, strong) NSDictionary *entity;
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGEntityViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGEntityViewController.m b/sdks/other/ios/samples/Browser/browser/UGEntityViewController.m
new file mode 100644
index 0000000..7cb2d17
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGEntityViewController.m
@@ -0,0 +1,86 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGEntityViewController.m
+//  Browser
+//
+
+#import "UGEntityViewController.h"
+#import "UGTextViewController.h"
+
+@interface UGEntityViewController ()
+
+@end
+
+@implementation UGEntityViewController
+
+- (id)initWithStyle:(UITableViewStyle)style
+{
+    self = [super initWithStyle:style];
+    if (self) {
+        // Custom initialization
+    }
+    return self;
+}
+
+- (void) loadView
+{
+    [super loadView];
+    self.navigationItem.title = self.entity[@"name"];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return [self.entity count];
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UITableViewCell *cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:@"Cell"];
+    return cell;
+}
+
+#pragma mark - Table view delegate
+
+- (void) tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    NSArray *keys = [[self.entity allKeys] sortedArrayUsingSelector:@selector(compare:)];
+    NSString *key = keys[[indexPath row]];
+    cell.textLabel.text = key;
+    id entity = self.entity[key];
+    cell.detailTextLabel.text = [entity description];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    NSArray *keys = [[self.entity allKeys] sortedArrayUsingSelector:@selector(compare:)];
+    NSString *key = keys[[indexPath row]];
+    UGTextViewController *textViewController = [[UGTextViewController alloc] init];
+    textViewController.key = key;
+    textViewController.binding = self.entity;
+    [self.navigationController pushViewController:textViewController animated:YES];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGSignInViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGSignInViewController.h b/sdks/other/ios/samples/Browser/browser/UGSignInViewController.h
new file mode 100644
index 0000000..58481cf
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGSignInViewController.h
@@ -0,0 +1,24 @@
+//
+//  UGSignInViewController.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@class UGAppViewController;
+
+@interface UGSignInViewController : UITableViewController
+@property (nonatomic, weak) UGAppViewController *appViewController;
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGSignInViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGSignInViewController.m b/sdks/other/ios/samples/Browser/browser/UGSignInViewController.m
new file mode 100644
index 0000000..7e346c9
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGSignInViewController.m
@@ -0,0 +1,185 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGSignInViewController.m
+//  Browser
+//
+
+#import "UGHTTPClient.h"
+#import "UGConnection.h"
+#import "UGSignInViewController.h"
+#import "UGAppViewController.h"
+
+#define SERVER @"http://api.usergrid.com"
+
+@interface UGFormTableViewCell : UITableViewCell <UITextFieldDelegate>
+@property (nonatomic, strong) UILabel *label;
+@property (nonatomic, strong) UITextField *textField;
+@property (nonatomic, strong) NSString *key;
+@property (nonatomic, weak) id binding;
+@end
+
+@implementation UGFormTableViewCell
+
+- (id) initWithTitle:(NSString *)title key:(NSString *) key binding:(id) binding
+{
+    if (self = [super initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]) {
+        self.label = [[UILabel alloc] initWithFrame:CGRectMake(10,0,90,14)];
+        self.label.backgroundColor = [UIColor clearColor];
+        self.label.font = [UIFont systemFontOfSize:10];
+        self.label.textColor = [UIColor grayColor];
+        self.label.textAlignment = UITextAlignmentLeft;
+        [self.contentView addSubview:self.label];
+        self.textField = [[UITextField alloc] initWithFrame:CGRectMake(10, 14, 100, 30)];
+        self.textField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;
+        self.textField.font = [UIFont systemFontOfSize:18];
+        self.textField.autocorrectionType = UITextAutocorrectionTypeNo;
+        self.textField.autocapitalizationType = UITextAutocapitalizationTypeNone;
+        self.textField.delegate = self;
+        if ([key isEqualToString:@"password"]) {
+            self.textField.secureTextEntry = YES;
+        }
+        [self.contentView addSubview:self.textField];
+        self.selectionStyle = UITableViewCellSelectionStyleNone;
+        // individual cell properties
+        self.label.text = title;
+        self.key = key;
+        self.binding = binding;
+    }
+    return self;
+}
+
+- (void) layoutSubviews
+{
+    [super layoutSubviews];
+    CGRect textFieldFrame = self.textField.frame;
+    textFieldFrame.size.width = self.textField.superview.bounds.size.width - textFieldFrame.origin.x - 5;
+    self.textField.frame = textFieldFrame;
+}
+
+- (void) textFieldDidEndEditing:(UITextField *)textField
+{
+    [self.binding setObject:textField.text forKey:self.key];
+}
+
+@end
+
+@interface UGSignInViewController ()
+@property (nonatomic, strong) NSMutableDictionary *values;
+@property (nonatomic, strong) NSArray *cells;
+@end
+
+@implementation UGSignInViewController
+
+- (id)init {
+    if (self = [super initWithStyle:UITableViewStyleGrouped]) {
+        self.values = [[[NSUserDefaults standardUserDefaults] objectForKey:@"usergrid"] mutableCopy];
+        if (!self.values) {
+            self.values = [NSMutableDictionary dictionary];
+            [self.values setObject:SERVER forKey:@"server"];
+        }
+        self.cells =
+        @[[[UGFormTableViewCell alloc] initWithTitle:@"Server" key:@"server" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Organization" key:@"organization" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Application" key:@"application" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Username" key:@"username" binding:self.values],
+          [[UGFormTableViewCell alloc] initWithTitle:@"Password" key:@"password" binding:self.values]];
+    }
+    return self;
+}
+
+- (void) loadView
+{
+    [super loadView];
+    self.title = @"Connection";
+    self.tableView.backgroundView = nil;
+    self.tableView.backgroundColor = [UIColor darkGrayColor];
+    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc]
+                                             initWithTitle:@"Cancel"
+                                             style:UIBarButtonItemStyleBordered
+                                             target:self
+                                             action:@selector(cancel:)];
+    self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc]
+                                              initWithTitle:@"Sign In"
+                                              style:UIBarButtonItemStyleBordered
+                                              target:self
+                                              action:@selector(signin:)];
+}
+
+#pragma mark - Table view data source
+
+- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
+{
+    return 1;
+}
+
+- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
+{
+    return [self.cells count];
+}
+
+- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    return [self.cells objectAtIndex:[indexPath row]];
+}
+
+#pragma mark - Table view delegate
+
+- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UGFormTableViewCell *formCell = (UGFormTableViewCell *) cell;
+    formCell.textField.text = [formCell.binding objectForKey:formCell.key];
+}
+
+- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
+{
+    UGFormTableViewCell *formCell = (UGFormTableViewCell *)[tableView cellForRowAtIndexPath:indexPath];
+    [formCell.textField becomeFirstResponder];
+}
+
+#pragma mark - Sign In
+
+- (void) cancel:(id) sender
+{
+    [self dismissModalViewControllerAnimated:YES];
+}
+
+- (void) signin:(id) sender
+{
+    for (UGFormTableViewCell *cell in self.cells) {
+        [cell.textField resignFirstResponder];
+    }
+    [[NSUserDefaults standardUserDefaults] setObject:self.values forKey:@"usergrid"];
+    [[NSUserDefaults standardUserDefaults] synchronize];
+    
+    UGConnection *connection = [UGConnection sharedConnection];
+    connection.server = [self.values objectForKey:@"server"];
+    connection.organization = [self.values objectForKey:@"organization"];
+    connection.application = [self.values objectForKey:@"application"];
+    
+    [[[UGHTTPClient alloc] initWithRequest:
+      [connection getAccessTokenForApplicationWithUsername:[self.values objectForKey:@"username"]
+                                              password:[self.values objectForKey:@"password"]]]
+     connectWithCompletionHandler:^(UGHTTPResult *result) {
+         [connection authenticateWithResult:result];
+         [(UGAppViewController *) self.appViewController downloadApplicationDescription];
+         [self dismissModalViewControllerAnimated:YES];
+     }];
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGTextViewController.h
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGTextViewController.h b/sdks/other/ios/samples/Browser/browser/UGTextViewController.h
new file mode 100644
index 0000000..57e2c8f
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGTextViewController.h
@@ -0,0 +1,23 @@
+//
+//  UGTextViewController.h
+//  Browser
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+@interface UGTextViewController : UIViewController
+@property (nonatomic, strong) NSString *key;
+@property (nonatomic, strong) NSDictionary *binding;
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/UGTextViewController.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/UGTextViewController.m b/sdks/other/ios/samples/Browser/browser/UGTextViewController.m
new file mode 100644
index 0000000..d428913
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/UGTextViewController.m
@@ -0,0 +1,43 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  UGTextViewController.m
+//  Browser
+//
+
+
+#import "UGTextViewController.h"
+
+@interface UGTextViewController ()
+@property (nonatomic, strong) UITextView *textView;
+@end
+
+@implementation UGTextViewController
+
+- (void) loadView
+{
+    [super loadView];
+    self.textView = [[UITextView alloc] initWithFrame:self.view.bounds];
+    self.textView.autoresizingMask = UIViewAutoresizingFlexibleWidth+UIViewAutoresizingFlexibleHeight;
+    self.textView.font = [UIFont systemFontOfSize:20];
+    [self.view addSubview:self.textView];
+    self.textView.text = [self.binding[self.key] description];
+    self.navigationItem.title = self.key;
+}
+
+@end

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/browser-Info.plist
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/browser-Info.plist b/sdks/other/ios/samples/Browser/browser/browser-Info.plist
new file mode 100644
index 0000000..212588c
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/browser-Info.plist
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+-->
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+	<key>CFBundleDevelopmentRegion</key>
+	<string>en</string>
+	<key>CFBundleDisplayName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundleExecutable</key>
+	<string>${EXECUTABLE_NAME}</string>
+	<key>CFBundleIdentifier</key>
+	<string>com.apigee.${PRODUCT_NAME:rfc1034identifier}</string>
+	<key>CFBundleInfoDictionaryVersion</key>
+	<string>6.0</string>
+	<key>CFBundleName</key>
+	<string>${PRODUCT_NAME}</string>
+	<key>CFBundlePackageType</key>
+	<string>APPL</string>
+	<key>CFBundleShortVersionString</key>
+	<string>1.0</string>
+	<key>CFBundleSignature</key>
+	<string>????</string>
+	<key>CFBundleVersion</key>
+	<string>1.0</string>
+	<key>LSRequiresIPhoneOS</key>
+	<true/>
+	<key>UIRequiredDeviceCapabilities</key>
+	<array>
+		<string>armv7</string>
+	</array>
+	<key>UISupportedInterfaceOrientations</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+	<key>UISupportedInterfaceOrientations~ipad</key>
+	<array>
+		<string>UIInterfaceOrientationPortrait</string>
+		<string>UIInterfaceOrientationPortraitUpsideDown</string>
+		<string>UIInterfaceOrientationLandscapeLeft</string>
+		<string>UIInterfaceOrientationLandscapeRight</string>
+	</array>
+</dict>
+</plist>

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/browser-Prefix.pch
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/browser-Prefix.pch b/sdks/other/ios/samples/Browser/browser/browser-Prefix.pch
new file mode 100644
index 0000000..86a5940
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/browser-Prefix.pch
@@ -0,0 +1,14 @@
+//
+// Prefix header for all source files of the 'browser' target in the 'browser' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_3_0
+#warning "This project uses features only available in iOS SDK 3.0 and later."
+#endif
+
+#ifdef __OBJC__
+    #import <UIKit/UIKit.h>
+    #import <Foundation/Foundation.h>
+#endif

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/en.lproj/InfoPlist.strings b/sdks/other/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
new file mode 100644
index 0000000..477b28f
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/en.lproj/InfoPlist.strings
@@ -0,0 +1,2 @@
+/* Localized versions of Info.plist keys */
+

http://git-wip-us.apache.org/repos/asf/usergrid/blob/867060fa/sdks/other/ios/samples/Browser/browser/main.m
----------------------------------------------------------------------
diff --git a/sdks/other/ios/samples/Browser/browser/main.m b/sdks/other/ios/samples/Browser/browser/main.m
new file mode 100644
index 0000000..11cecbf
--- /dev/null
+++ b/sdks/other/ios/samples/Browser/browser/main.m
@@ -0,0 +1,30 @@
+//
+// Licensed to the Apache Software Foundation (ASF) under one or more
+// contributor license agreements.  See the NOTICE file distributed with
+// this work for additional information regarding copyright ownership.
+// The ASF licenses this file to You under the Apache License, Version 2.0
+// (the "License"); you may not use this file except in compliance with
+// the License.  You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+//
+//  main.m
+//  Browser
+//
+
+#import "UGAppDelegate.h"
+
+int main(int argc, char *argv[])
+{
+    @autoreleasepool {
+        return UIApplicationMain(argc, argv, nil, NSStringFromClass([UGAppDelegate class]));
+    }
+}