class Findface::Face
Public Class Methods
create(options)
click to toggle source
Endpoint: api.findface.pro/v0/face/ (POST) | Usage: FindFace::Face.create
Output: Creates a new face object
# File lib/findface/face.rb, line 22 def create options API::request(:post, 'face', options) end
delete(face_id)
click to toggle source
Endpoint: api.findface.pro/v0/face/id/:id (DELETE) | Usage: FindFace::Face.delete(face_id)
Output: Deletes a face with matching id
# File lib/findface/face.rb, line 50 def delete face_id API::request(:delete, "face/id/#{face_id}") end
delete_by_meta(meta_string)
click to toggle source
Endpoint: api.findface.pro/v0/face/meta/:meta_string (DELETE) | Usage: FindFace::Face.delete_by_meta(meta_string)
Output: Deletes a face with matching meta_string
# File lib/findface/face.rb, line 57 def delete_by_meta meta_string API::request(:delete, "face/meta/#{Findface.encode_meta_string(meta_string)}") end
details(face_id)
click to toggle source
Endpoint: api.findface.pro/v0/face/id/:id (GET) | Usage: FindFace::Face.details(face_id)
Output: Returns the details of a face with matching id
# File lib/findface/face.rb, line 29 def details face_id API::request(:get, "face/id/#{face_id}") end
details_by_meta(meta_string, pages = nil)
click to toggle source
Endpoint: api.findface.pro/v0/face/meta/:meta_string (GET) | Usage: FindFace::Face.details_by_meta(meta_string)
Output: Returns the details of an face with matching meta_string
# File lib/findface/face.rb, line 36 def details_by_meta meta_string, pages = nil Findface.get_list "face/meta/#{Findface.encode_meta_string(meta_string)}", pages end
list(pages = nil)
click to toggle source
Endpoint: api.findface.pro/v0/faces/ (GET) | Usage: FindFace::Face.list
Output: Returns list of faces
# File lib/findface/face.rb, line 8 def list pages = nil Findface.get_list 'faces', pages end
list_by_meta()
click to toggle source
Endpoint: api.findface.pro/v0/meta/ (GET) | Usage: FindFace::Face.list_by_meta
Output: Returns list of faces with meta information
# File lib/findface/face.rb, line 15 def list_by_meta API::request(:get, 'meta') end
update(face_id, options)
click to toggle source
Endpoint: api.findface.pro/v0/face/id/:id (PUT) | Usage: FindFace::Face.update(face_id)
Output: Updates a face with matching id
# File lib/findface/face.rb, line 43 def update face_id, options API::request(:put, "face/id/#{face_id}", options) end