Class UserAgent

java.lang.Object
com.mastercard.developer.oauth2.http.UserAgent

public final class UserAgent extends Object
Utility class to generate a User-Agent string used in HTTP requests.
  • Method Summary

    Modifier and Type
    Method
    Description
    static String
    get()
    Builds a stable user-agent string: Product/Version (Runtime; OS [OS Version]) Example: Mastercard-OAuth2-Client/1.0.0 (Java/17.0.2; Linux 5.15)

    Methods inherited from class java.lang.Object

    clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • get

      public static String get()
      Builds a stable user-agent string: Product/Version (Runtime; OS [OS Version]) Example: Mastercard-OAuth2-Client/1.0.0 (Java/17.0.2; Linux 5.15)