
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
A Ruby interface for making requests to the FOLIO ILS API (https://folio.org), including some convenience methods that have been useful for the Columbia University Libraries.
bundle add folio_api_client
If bundler is not being used to manage dependencies, you can install the gem by running:
gem install folio_api_client
# Create a client
client = FolioApiClient.new(FolioApiClient::Configuration.new(
url: 'https://development.example.com',
username: 'username',
password: 'password',
tenant: 'abc123',
timeout: 10
))
# Make some requests
instance_record_id = '65e07045-4d68-4a07-835e-33f0c80482ab'
instance_record_response = client.get("/instance-storage/instances/#{instance_record_id}")
puts JSON.parse(instance_record_response.body)
holdings_record_id = 'b2e9946b-82fe-4cfb-ad4c-b3c452379dae'
holdings_record_response = client.get("/holdings-storage/holdings/#{holdings_record_id}")
puts JSON.parse(holdings_record_response.body)
# Generic request syntax for any FOLIO REST endpoint:
client.get(path, params)
client.post(path, body, content_type: 'application/json'))
client.put(path, body, content_type: 'application/json'))
client.delete(path, body, content_type: 'application/json'))
# Other convenience methods:
client.find_item_record(barcode: 'some-barcode')
client.find_location_record(location_id: 'some-location-id')
client.find_holdings_record(holdings_record_id: 'some-holdings-record-id')
client.find_instance_record(instance_record_id: 'some-instance-record-id')
client.find_instance_record(instance_record_hrid: 'some-instance-record-hrid')
client.find_source_record(instance_record_id: 'some-instance-record-id')
client.find_source_record(instance_record_hrid: 'some-instance-record-hrid')
# Convert a FOLIO MARC source record to a marc gem MARC::Record object:
source_record = client.find_source_record(instance_record_id: 'some-instance-record-id')
marc_record = MARC::Record.new_from_hash(source_record['parsedRecord']['content'])
See https://dev.folio.org/reference/api/ for the full list of available FOLIO API endpoints.
After checking out the repo, run bin/setup
to install dependencies. Then, run rake spec
to run the tests. You can also run bin/console
for an interactive prompt that will allow you to experiment.
To release a new version of this gem, update the version number in version.rb
, and then run bundle exec rake release
, which will create a git tag for the version, push git commits and the created tag, and push the .gem
file to rubygems.org.
Bug reports and pull requests are welcome on GitHub at: https://github.com/cul/folio_api_client
FAQs
Unknown package
We found that folio_api_client demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.