Signing back into the Community for the first time? You'll need to reset your password to access your account. Find out more.
Forum Discussion
sshipway
3 years agoOccasional Contributor
templateUuid error when trying to create secret via Ruby SDK
I am trying to create a new Secret in a 1Password vault via the Connect API (container 1.5.1), using the Ruby gem SDK (0.1.3)
I am calling the api with:
item = op.create_item(vault_id: vau...
sshipway
3 years agoOccasional Contributor
Problem solved! Details here for the benefit of anyone else in the future.
This was insufficient documentation in the ruby SDK (or possibly insufficient User IQ in myself?). The problem here was the way arguments were passed to create_item()
Rather than pass the attributes using
create_item(vault_id: vaultid,body: attributes)
they should instead have been passed as individual parameters
create_item(vault_id: vaultid, title: title, tags: tagarray, fields: fieldarray, category: "LOGIN" )
calling the function like this and it all works. Other calls also require parameters to be given in this way rather than as a single hash.
The update_item()
function is broken however (SDK 0.1.3) and needs a fix in the library, see issues in the git repo.