Module: Smslist::Client::State
- Included in:
- Smslist::Client
- Defined in:
- lib/smslist/client/state.rb
Constant Summary collapse
- STATE_ERRORS =
{ 1 => 'The subscriber is absent or out of a coverage', 2 => 'Call barred service activated', 3 => 'Unknown subscriber', 4 => 'Memory capacity exceeded', 5 => 'Equipment protocol error', 6 => 'Teleservice not provisioned', 7 => 'Facility not supported', 8 => 'Subscriber is busy', 9 => 'Roaming restrictions', 10 => 'Timeout', 11 => 'SS7 routing error', 12 => 'Internal system failure', 13 => 'SMSC failure' }.freeze
Instance Method Summary collapse
-
#state(message_ids = []) ⇒ Hash
Get state for a list of message ids.
Instance Method Details
#state(message_ids = []) ⇒ Hash
Get state for a list of message ids
29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/smslist/client/state.rb', line 29 def state( = []) body = build_xml_body do |xml| xml.get_state { .each do |id| xml.id_sms id end } end response = parse_xml(post body.to_xml, :state) parse_state_response(response) end |