Sha256: 34541b6298f8055af0fa32eaad55433a924541a21afc35309c118c5028bb7379
Contents?: true
Size: 702 Bytes
Versions: 16
Compression:
Stored size: 702 Bytes
Contents
module PortaText module Command module Api # The me/acl endpoint. # https://github.com/PortaText/docs/wiki/REST-API#api_acl # # Author:: Marcelo Gornstein (mailto:marcelog@portatext.com) # Copyright:: Copyright (c) 2015 PortaText # License:: Apache-2.0 class Acl < Base def add(ip, netmask = 32, description = '') key = "#{ip}#{netmask}" set key, ip: ip, netmask: netmask, description: description end def body(method) return super if method.eql? :get { acl: @args.values }.to_json end def endpoint(_method) 'me/acl' end end end end end
Version data entries
16 entries across 16 versions & 1 rubygems