Readme.md in usps-imis-api-0.1.1 vs Readme.md in usps-imis-api-0.1.2
- old
+ new
@@ -11,20 +11,20 @@
```
or add this line to your Gemfile:
```ruby
-gem 'usps-imis-api', '>= 0.1.0'
+gem 'usps-imis-api', '>= 0.1.1'
```
## Setup
Include the library, and set the configuration:
```ruby
require 'dotenv/load' # Optionally load environment variables from `.env` file
-require 'usps_imis_api'
+require 'usps-imis-api'
Imis.configure do |config|
config.environment = :development # Rails.env
config.imis_id_query_name = ENV['IMIS_ID_QUERY_NAME']
@@ -134,10 +134,24 @@
If there is no known mapping for the requested field, the Mapper will give up, but will provide
you with the standard API call syntax, and will suggest you inform ITCom leadership of the new
mapping you need.
+### DSL Mode
+
+Instead of manually setting the current iMIS ID, then running individual queries, you can instead
+run queries in DSL mode. This specifies the iMIS ID for the scope of the block, then reverts to the
+previous value.
+
+```ruby
+api.with(31092) do
+ # These two requests are identical:
+ put('ABC_ASC_Individual_Demog', { 'TotMMS' => 15 })
+ mapper.update(:mm, 15)
+end
+```
+
## Exception Handling
Exception and error response handling will be added later.
## Automated Testing and Linting
@@ -151,9 +165,13 @@
Linting is available by running:
```ruby
bundle exec rubocop
```
+
+### GitHub Actions
+
+Testing and linting are automatically run on every push.
## PHP
This same API is
[available for PHP](https://github.com/unitedstatespowersquadrons/imis-api).