forked from mediasp/openimp-api
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Nick Griffiths
committed
Jun 20, 2012
1 parent
0022101
commit 69f4314
Showing
1 changed file
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# OpenIMP API Client | ||
|
||
Client for communicating with OpenIMP APIs, such as that used by Consilidated Independent. | ||
|
||
## Hello, World | ||
|
||
require 'ci-api' | ||
|
||
client = CI::Client.new('http://api.cissme.com/media/v1', { | ||
:username => 'mediaman', :password => 'secretzzz'}) | ||
|
||
release_by_uri = client.get('/release/upc/012345678') | ||
puts release_by_uri.inspect | ||
|
||
release_repo = CI::Repository::Release.new(client) | ||
release_by_find = release_repo.find(:upc => '012345678') | ||
puts release_by_find.inspect | ||
|