Method: Appwrite::Avatars#get_qr
- Defined in:
- lib/appwrite/services/avatars.rb
#get_qr(text:, size: nil, margin: nil, download: nil) ⇒ Object
Converts a given plain text to a QR code image. You can use the query parameters to change the size and style of the resulting image.
266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 |
# File 'lib/appwrite/services/avatars.rb', line 266 def get_qr(text:, size: nil, margin: nil, download: nil) api_path = '/avatars/qr' if text.nil? raise Appwrite::Exception.new('Missing required parameter: "text"') end api_params = { text: text, size: size, margin: margin, download: download, } api_headers = { } @client.call( method: 'GET', path: api_path, headers: api_headers, params: api_params, ) end |