I was thinking the method would be called like so create_keypair('mykey', :public_key => PUBLIC_KEY, :user_id => 'bob') which would require this line to look like `key_data.merge!(attributes)`

I was thinking this line should look like `key_data.merge!(attributes)` and you would call it like so `create_keypair('mykey', :public_key => MY_KEY_HERE). Where you thinking of something different?