Class: Google::Apis::AddressvalidationV1::GoogleMapsAddressvalidationV1UspsData

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/addressvalidation_v1/classes.rb,
lib/google/apis/addressvalidation_v1/representations.rb,
lib/google/apis/addressvalidation_v1/representations.rb

Overview

The USPS data for the address. uspsData is not guaranteed to be fully populated for every US or PR address sent to the Address Validation API. It's recommended to integrate the backup address fields in the response if you utilize uspsData as the primary part of the response.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleMapsAddressvalidationV1UspsData

Returns a new instance of GoogleMapsAddressvalidationV1UspsData.



807
808
809
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 807

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#abbreviated_cityString

Abbreviated city. Corresponds to the JSON property abbreviatedCity

Returns:

  • (String)


539
540
541
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 539

def abbreviated_city
  @abbreviated_city
end

#address_record_typeString

Type of the address record that matches the input address. * F: FIRM. This is a match to a Firm Record, which is the finest level of match available for an address. * G: GENERAL DELIVERY. This is a match to a General Delivery record. * H: BUILDING / APARTMENT. This is a match to a Building or Apartment record. * P: POST OFFICE BOX. This is a match to a Post Office Box.

  • R: RURAL ROUTE or HIGHWAY CONTRACT: This is a match to either a Rural Route or a Highway Contract record, both of which may have associated Box Number ranges. * S: STREET RECORD: This is a match to a Street record containing a valid primary number range. Corresponds to the JSON property addressRecordType

Returns:

  • (String)


552
553
554
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 552

def address_record_type
  @address_record_type
end

#carrier_routeString

The carrier route code. A four character code consisting of a one letter prefix and a three digit route designator. Prefixes: * C: Carrier route (or city route) * R: Rural route * H: Highway Contract Route * B: Post Office Box Section * G: General delivery unit Corresponds to the JSON property carrierRoute

Returns:

  • (String)


560
561
562
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 560

def carrier_route
  @carrier_route
end

#carrier_route_indicatorString

Carrier route rate sort indicator. Corresponds to the JSON property carrierRouteIndicator

Returns:

  • (String)


565
566
567
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 565

def carrier_route_indicator
  @carrier_route_indicator
end

#cass_processedBoolean Also known as: cass_processed?

Indicator that the request has been CASS processed. Corresponds to the JSON property cassProcessed

Returns:

  • (Boolean)


570
571
572
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 570

def cass_processed
  @cass_processed
end

#countyString

County name. Corresponds to the JSON property county

Returns:

  • (String)


576
577
578
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 576

def county
  @county
end

#default_addressBoolean Also known as: default_address?

Indicator that a default address was found, but more specific addresses exists. Corresponds to the JSON property defaultAddress

Returns:

  • (Boolean)


581
582
583
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 581

def default_address
  @default_address
end

#delivery_point_check_digitString

The delivery point check digit. This number is added to the end of the delivery_point_barcode for mechanically scanned mail. Adding all the digits of the delivery_point_barcode, delivery_point_check_digit, postal code, and ZIP+4 together should yield a number divisible by 10. Corresponds to the JSON property deliveryPointCheckDigit

Returns:

  • (String)


590
591
592
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 590

def delivery_point_check_digit
  @delivery_point_check_digit
end

#delivery_point_codeString

2 digit delivery point code Corresponds to the JSON property deliveryPointCode

Returns:

  • (String)


595
596
597
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 595

def delivery_point_code
  @delivery_point_code
end

#dpv_cmraString

Indicates if the address is a CMRA (Commercial Mail Receiving Agency)--a private business receiving mail for clients. Returns a single character. * Y: The address is a CMRA * N: The address is not a CMRA Corresponds to the JSON property dpvCmra

Returns:

  • (String)


602
603
604
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 602

def dpv_cmra
  @dpv_cmra
end

#dpv_confirmationString

The possible values for DPV confirmation. Returns a single character or returns no value. * N: Primary and any secondary number information failed to DPV confirm. * D: Address was DPV confirmed for the primary number only, and the secondary number information was missing. * S: Address was DPV confirmed for the primary number only, and the secondary number information was present but not confirmed. * Y: Address was DPV confirmed for primary and any secondary numbers. * Empty: If the response does not contain a dpv_confirmation value, the address was not submitted for DPV confirmation. Corresponds to the JSON property dpvConfirmation

Returns:

  • (String)


614
615
616
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 614

def dpv_confirmation
  @dpv_confirmation
end

#dpv_door_not_accessibleString

Flag indicates addresses where USPS cannot knock on a door to deliver mail. Returns a single character. * Y: The door is not accessible. * N: No indication the door is not accessible. Corresponds to the JSON property dpvDoorNotAccessible

Returns:

  • (String)


621
622
623
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 621

def dpv_door_not_accessible
  @dpv_door_not_accessible
end

#dpv_dropString

Flag indicates mail is delivered to a single receptable at a site. Returns a single character. * Y: The mail is delivered to a single receptable at a site. * N: The mail is not delivered to a single receptable at a site. Corresponds to the JSON property dpvDrop

Returns:

  • (String)


628
629
630
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 628

def dpv_drop
  @dpv_drop
end

#dpv_enhanced_delivery_codeString

Indicates that more than one DPV return code is valid for the address. Returns a single character. * Y: Address was DPV confirmed for primary and any secondary numbers. * N: Primary and any secondary number information failed to DPV confirm. * S: Address was DPV confirmed for the primary number only, and the secondary number information was present but not confirmed, or a single trailing alpha on a primary number was dropped to make a DPV match and secondary information required. * D: Address was DPV confirmed for the primary number only, and the secondary number information was missing. * R: Address confirmed but assigned to phantom route R777 and R779 and USPS delivery is not provided. Corresponds to the JSON property dpvEnhancedDeliveryCode

Returns:

  • (String)


642
643
644
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 642

def dpv_enhanced_delivery_code
  @dpv_enhanced_delivery_code
end

#dpv_footnoteString

The footnotes from delivery point validation. Multiple footnotes may be strung together in the same string. * AA: Input address matched to the ZIP+4 file * A1: Input address was not matched to the ZIP+4 file * BB: Matched to DPV ( all components) * CC: Secondary number not matched and not required * C1: Secondary number not matched but required * N1: High-rise address missing secondary number * M1: Primary number missing * M3: Primary number invalid

  • P1: Input address PO, RR or HC box number missing * P3: Input address PO, RR, or HC Box number invalid * F1: Input address matched to a military address * G1: Input address matched to a general delivery address * U1: Input address matched to a unique ZIP code * PB: Input address matched to PBSA record * RR: DPV confirmed address with PMB information * R1: DPV confirmed address without PMB information * R7: Carrier Route R777 or R779 record * IA: Informed Address identified * TA: Primary number matched by dropping a trailing alpha Corresponds to the JSON property dpvFootnote

Returns:

  • (String)


660
661
662
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 660

def dpv_footnote
  @dpv_footnote
end

#dpv_no_secure_locationString

Flag indicates door is accessible, but package will not be left due to security concerns. Returns a single character. * Y: The package will not be left due to security concerns. * N: No indication the package will not be left due to security concerns. Corresponds to the JSON property dpvNoSecureLocation

Returns:

  • (String)


668
669
670
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 668

def dpv_no_secure_location
  @dpv_no_secure_location
end

#dpv_no_statString

Is this a no stat address or an active address? No stat addresses are ones which are not continuously occupied or addresses that the USPS does not service. Returns a single character. * Y: The address is not active * N: The address is active Corresponds to the JSON property dpvNoStat

Returns:

  • (String)


676
677
678
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 676

def dpv_no_stat
  @dpv_no_stat
end

#dpv_no_stat_reason_codeFixnum

Indicates the NoStat type. Returns a reason code as int. * 1: IDA (Internal Drop Address) – Addresses that do not receive mail directly from the USPS but are delivered to a drop address that services them. * 2: CDS - Addresses that have not yet become deliverable. For example, a new subdivision where lots and primary numbers have been determined, but no structure exists yet for occupancy. * 3: Collision - Addresses that do not actually DPV confirm. * 4 : CMZ (College, Military and Other Types) - ZIP + 4 records USPS has incorporated into the data. * 5: Regular - Indicates addresses not receiving delivery and the addresses are not counted as possible deliveries. * 6: Secondary Required - The address requires secondary information. Corresponds to the JSON property dpvNoStatReasonCode

Returns:

  • (Fixnum)


690
691
692
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 690

def dpv_no_stat_reason_code
  @dpv_no_stat_reason_code
end

#dpv_non_delivery_daysString

Flag indicates mail delivery is not performed every day of the week. Returns a single character. * Y: The mail delivery is not performed every day of the week. * N: No indication the mail delivery is not performed every day of the week. Corresponds to the JSON property dpvNonDeliveryDays

Returns:

  • (String)


698
699
700
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 698

def dpv_non_delivery_days
  @dpv_non_delivery_days
end

#dpv_non_delivery_days_valuesFixnum

Integer identifying non-delivery days. It can be interrogated using bit flags: 0x40 – Sunday is a non-delivery day 0x20 – Monday is a non-delivery day 0x10 – Tuesday is a non-delivery day 0x08 – Wednesday is a non-delivery day 0x04 – Thursday is a non-delivery day 0x02 – Friday is a non-delivery day 0x01 – Saturday is a non-delivery day Corresponds to the JSON property dpvNonDeliveryDaysValues

Returns:

  • (Fixnum)


707
708
709
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 707

def dpv_non_delivery_days_values
  @dpv_non_delivery_days_values
end

#dpv_pbsaString

Indicates the address was matched to PBSA record. Returns a single character. * Y: The address was matched to PBSA record. * N: The address was not matched to PBSA record. Corresponds to the JSON property dpvPbsa

Returns:

  • (String)


714
715
716
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 714

def dpv_pbsa
  @dpv_pbsa
end

#dpv_throwbackString

Indicates that mail is not delivered to the street address. Returns a single character. * Y: The mail is not delivered to the street address. * N: The mail is delivered to the street address. Corresponds to the JSON property dpvThrowback

Returns:

  • (String)


721
722
723
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 721

def dpv_throwback
  @dpv_throwback
end

#dpv_vacantString

Is this place vacant? Returns a single character. * Y: The address is vacant

  • N: The address is not vacant Corresponds to the JSON property dpvVacant

Returns:

  • (String)


727
728
729
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 727

def dpv_vacant
  @dpv_vacant
end

#elot_flagString

eLOT Ascending/Descending Flag (A/D). Corresponds to the JSON property elotFlag

Returns:

  • (String)


732
733
734
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 732

def elot_flag
  @elot_flag
end

#elot_numberString

Enhanced Line of Travel (eLOT) number. Corresponds to the JSON property elotNumber

Returns:

  • (String)


737
738
739
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 737

def elot_number
  @elot_number
end

#error_messageString

Error message for USPS data retrieval. This is populated when USPS processing is suspended because of the detection of artificially created addresses. The USPS data fields might not be populated when this error is present. Corresponds to the JSON property errorMessage

Returns:

  • (String)


744
745
746
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 744

def error_message
  @error_message
end

#ews_no_matchBoolean Also known as: ews_no_match?

The delivery address is matchable, but the EWS file indicates that an exact match will be available soon. Corresponds to the JSON property ewsNoMatch

Returns:

  • (Boolean)


750
751
752
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 750

def ews_no_match
  @ews_no_match
end

#fips_county_codeString

FIPS county code. Corresponds to the JSON property fipsCountyCode

Returns:

  • (String)


756
757
758
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 756

def fips_county_code
  @fips_county_code
end

LACSLink indicator. Corresponds to the JSON property lacsLinkIndicator

Returns:

  • (String)


761
762
763
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 761

def lacs_link_indicator
  @lacs_link_indicator
end

LACSLink return code. Corresponds to the JSON property lacsLinkReturnCode

Returns:

  • (String)


766
767
768
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 766

def lacs_link_return_code
  @lacs_link_return_code
end

#pmb_designatorString

PMB (Private Mail Box) unit designator. Corresponds to the JSON property pmbDesignator

Returns:

  • (String)


771
772
773
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 771

def pmb_designator
  @pmb_designator
end

#pmb_numberString

PMB (Private Mail Box) number; Corresponds to the JSON property pmbNumber

Returns:

  • (String)


776
777
778
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 776

def pmb_number
  @pmb_number
end

#po_box_only_postal_codeBoolean Also known as: po_box_only_postal_code?

PO Box only postal code. Corresponds to the JSON property poBoxOnlyPostalCode

Returns:

  • (Boolean)


781
782
783
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 781

def po_box_only_postal_code
  @po_box_only_postal_code
end

#post_office_cityString

Main post office city. Corresponds to the JSON property postOfficeCity

Returns:

  • (String)


787
788
789
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 787

def post_office_city
  @post_office_city
end

#post_office_stateString

Main post office state. Corresponds to the JSON property postOfficeState

Returns:

  • (String)


792
793
794
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 792

def post_office_state
  @post_office_state
end

#standardized_addressGoogle::Apis::AddressvalidationV1::GoogleMapsAddressvalidationV1UspsAddress

USPS representation of a US address. Corresponds to the JSON property standardizedAddress



797
798
799
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 797

def standardized_address
  @standardized_address
end

Footnotes from matching a street or highrise record to suite information. If business name match is found, the secondary number is returned. * A: SuiteLink record match, business address improved. * 00: No match, business address is not improved. Corresponds to the JSON property suitelinkFootnote

Returns:

  • (String)


805
806
807
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 805

def suitelink_footnote
  @suitelink_footnote
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
# File 'lib/google/apis/addressvalidation_v1/classes.rb', line 812

def update!(**args)
  @abbreviated_city = args[:abbreviated_city] if args.key?(:abbreviated_city)
  @address_record_type = args[:address_record_type] if args.key?(:address_record_type)
  @carrier_route = args[:carrier_route] if args.key?(:carrier_route)
  @carrier_route_indicator = args[:carrier_route_indicator] if args.key?(:carrier_route_indicator)
  @cass_processed = args[:cass_processed] if args.key?(:cass_processed)
  @county = args[:county] if args.key?(:county)
  @default_address = args[:default_address] if args.key?(:default_address)
  @delivery_point_check_digit = args[:delivery_point_check_digit] if args.key?(:delivery_point_check_digit)
  @delivery_point_code = args[:delivery_point_code] if args.key?(:delivery_point_code)
  @dpv_cmra = args[:dpv_cmra] if args.key?(:dpv_cmra)
  @dpv_confirmation = args[:dpv_confirmation] if args.key?(:dpv_confirmation)
  @dpv_door_not_accessible = args[:dpv_door_not_accessible] if args.key?(:dpv_door_not_accessible)
  @dpv_drop = args[:dpv_drop] if args.key?(:dpv_drop)
  @dpv_enhanced_delivery_code = args[:dpv_enhanced_delivery_code] if args.key?(:dpv_enhanced_delivery_code)
  @dpv_footnote = args[:dpv_footnote] if args.key?(:dpv_footnote)
  @dpv_no_secure_location = args[:dpv_no_secure_location] if args.key?(:dpv_no_secure_location)
  @dpv_no_stat = args[:dpv_no_stat] if args.key?(:dpv_no_stat)
  @dpv_no_stat_reason_code = args[:dpv_no_stat_reason_code] if args.key?(:dpv_no_stat_reason_code)
  @dpv_non_delivery_days = args[:dpv_non_delivery_days] if args.key?(:dpv_non_delivery_days)
  @dpv_non_delivery_days_values = args[:dpv_non_delivery_days_values] if args.key?(:dpv_non_delivery_days_values)
  @dpv_pbsa = args[:dpv_pbsa] if args.key?(:dpv_pbsa)
  @dpv_throwback = args[:dpv_throwback] if args.key?(:dpv_throwback)
  @dpv_vacant = args[:dpv_vacant] if args.key?(:dpv_vacant)
  @elot_flag = args[:elot_flag] if args.key?(:elot_flag)
  @elot_number = args[:elot_number] if args.key?(:elot_number)
  @error_message = args[:error_message] if args.key?(:error_message)
  @ews_no_match = args[:ews_no_match] if args.key?(:ews_no_match)
  @fips_county_code = args[:fips_county_code] if args.key?(:fips_county_code)
  @lacs_link_indicator = args[:lacs_link_indicator] if args.key?(:lacs_link_indicator)
  @lacs_link_return_code = args[:lacs_link_return_code] if args.key?(:lacs_link_return_code)
  @pmb_designator = args[:pmb_designator] if args.key?(:pmb_designator)
  @pmb_number = args[:pmb_number] if args.key?(:pmb_number)
  @po_box_only_postal_code = args[:po_box_only_postal_code] if args.key?(:po_box_only_postal_code)
  @post_office_city = args[:post_office_city] if args.key?(:post_office_city)
  @post_office_state = args[:post_office_state] if args.key?(:post_office_state)
  @standardized_address = args[:standardized_address] if args.key?(:standardized_address)
  @suitelink_footnote = args[:suitelink_footnote] if args.key?(:suitelink_footnote)
end