github.com/stripe/stripe-go/v76@v76.25.0/terminal_configuration.go (about)

     1  //
     2  //
     3  // File generated from our OpenAPI spec
     4  //
     5  //
     6  
     7  package stripe
     8  
     9  // Deletes a Configuration object.
    10  type TerminalConfigurationParams struct {
    11  	Params `form:"*"`
    12  	// An object containing device type specific settings for BBPOS WisePOS E readers
    13  	BBPOSWisePOSE *TerminalConfigurationBBPOSWisePOSEParams `form:"bbpos_wisepos_e"`
    14  	// Specifies which fields in the response should be expanded.
    15  	Expand []*string `form:"expand"`
    16  	// Name of the configuration
    17  	Name *string `form:"name"`
    18  	// Configurations for collecting transactions offline.
    19  	Offline *TerminalConfigurationOfflineParams `form:"offline"`
    20  	// Tipping configurations for readers supporting on-reader tips
    21  	Tipping *TerminalConfigurationTippingParams `form:"tipping"`
    22  	// An object containing device type specific settings for Verifone P400 readers
    23  	VerifoneP400 *TerminalConfigurationVerifoneP400Params `form:"verifone_p400"`
    24  }
    25  
    26  // AddExpand appends a new field to expand.
    27  func (p *TerminalConfigurationParams) AddExpand(f string) {
    28  	p.Expand = append(p.Expand, &f)
    29  }
    30  
    31  // An object containing device type specific settings for BBPOS WisePOS E readers
    32  type TerminalConfigurationBBPOSWisePOSEParams struct {
    33  	// A File ID representing an image you would like displayed on the reader.
    34  	Splashscreen *string `form:"splashscreen"`
    35  }
    36  
    37  // Configurations for collecting transactions offline.
    38  type TerminalConfigurationOfflineParams struct {
    39  	// Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
    40  	Enabled *bool `form:"enabled"`
    41  }
    42  
    43  // Tipping configuration for AUD
    44  type TerminalConfigurationTippingAUDParams struct {
    45  	// Fixed amounts displayed when collecting a tip
    46  	FixedAmounts []*int64 `form:"fixed_amounts"`
    47  	// Percentages displayed when collecting a tip
    48  	Percentages []*int64 `form:"percentages"`
    49  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
    50  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
    51  }
    52  
    53  // Tipping configuration for CAD
    54  type TerminalConfigurationTippingCADParams struct {
    55  	// Fixed amounts displayed when collecting a tip
    56  	FixedAmounts []*int64 `form:"fixed_amounts"`
    57  	// Percentages displayed when collecting a tip
    58  	Percentages []*int64 `form:"percentages"`
    59  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
    60  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
    61  }
    62  
    63  // Tipping configuration for CHF
    64  type TerminalConfigurationTippingCHFParams struct {
    65  	// Fixed amounts displayed when collecting a tip
    66  	FixedAmounts []*int64 `form:"fixed_amounts"`
    67  	// Percentages displayed when collecting a tip
    68  	Percentages []*int64 `form:"percentages"`
    69  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
    70  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
    71  }
    72  
    73  // Tipping configuration for CZK
    74  type TerminalConfigurationTippingCZKParams struct {
    75  	// Fixed amounts displayed when collecting a tip
    76  	FixedAmounts []*int64 `form:"fixed_amounts"`
    77  	// Percentages displayed when collecting a tip
    78  	Percentages []*int64 `form:"percentages"`
    79  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
    80  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
    81  }
    82  
    83  // Tipping configuration for DKK
    84  type TerminalConfigurationTippingDKKParams struct {
    85  	// Fixed amounts displayed when collecting a tip
    86  	FixedAmounts []*int64 `form:"fixed_amounts"`
    87  	// Percentages displayed when collecting a tip
    88  	Percentages []*int64 `form:"percentages"`
    89  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
    90  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
    91  }
    92  
    93  // Tipping configuration for EUR
    94  type TerminalConfigurationTippingEURParams struct {
    95  	// Fixed amounts displayed when collecting a tip
    96  	FixedAmounts []*int64 `form:"fixed_amounts"`
    97  	// Percentages displayed when collecting a tip
    98  	Percentages []*int64 `form:"percentages"`
    99  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   100  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   101  }
   102  
   103  // Tipping configuration for GBP
   104  type TerminalConfigurationTippingGBPParams struct {
   105  	// Fixed amounts displayed when collecting a tip
   106  	FixedAmounts []*int64 `form:"fixed_amounts"`
   107  	// Percentages displayed when collecting a tip
   108  	Percentages []*int64 `form:"percentages"`
   109  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   110  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   111  }
   112  
   113  // Tipping configuration for HKD
   114  type TerminalConfigurationTippingHKDParams struct {
   115  	// Fixed amounts displayed when collecting a tip
   116  	FixedAmounts []*int64 `form:"fixed_amounts"`
   117  	// Percentages displayed when collecting a tip
   118  	Percentages []*int64 `form:"percentages"`
   119  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   120  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   121  }
   122  
   123  // Tipping configuration for MYR
   124  type TerminalConfigurationTippingMYRParams struct {
   125  	// Fixed amounts displayed when collecting a tip
   126  	FixedAmounts []*int64 `form:"fixed_amounts"`
   127  	// Percentages displayed when collecting a tip
   128  	Percentages []*int64 `form:"percentages"`
   129  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   130  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   131  }
   132  
   133  // Tipping configuration for NOK
   134  type TerminalConfigurationTippingNOKParams struct {
   135  	// Fixed amounts displayed when collecting a tip
   136  	FixedAmounts []*int64 `form:"fixed_amounts"`
   137  	// Percentages displayed when collecting a tip
   138  	Percentages []*int64 `form:"percentages"`
   139  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   140  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   141  }
   142  
   143  // Tipping configuration for NZD
   144  type TerminalConfigurationTippingNZDParams struct {
   145  	// Fixed amounts displayed when collecting a tip
   146  	FixedAmounts []*int64 `form:"fixed_amounts"`
   147  	// Percentages displayed when collecting a tip
   148  	Percentages []*int64 `form:"percentages"`
   149  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   150  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   151  }
   152  
   153  // Tipping configuration for SEK
   154  type TerminalConfigurationTippingSEKParams struct {
   155  	// Fixed amounts displayed when collecting a tip
   156  	FixedAmounts []*int64 `form:"fixed_amounts"`
   157  	// Percentages displayed when collecting a tip
   158  	Percentages []*int64 `form:"percentages"`
   159  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   160  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   161  }
   162  
   163  // Tipping configuration for SGD
   164  type TerminalConfigurationTippingSGDParams struct {
   165  	// Fixed amounts displayed when collecting a tip
   166  	FixedAmounts []*int64 `form:"fixed_amounts"`
   167  	// Percentages displayed when collecting a tip
   168  	Percentages []*int64 `form:"percentages"`
   169  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   170  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   171  }
   172  
   173  // Tipping configuration for USD
   174  type TerminalConfigurationTippingUSDParams struct {
   175  	// Fixed amounts displayed when collecting a tip
   176  	FixedAmounts []*int64 `form:"fixed_amounts"`
   177  	// Percentages displayed when collecting a tip
   178  	Percentages []*int64 `form:"percentages"`
   179  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   180  	SmartTipThreshold *int64 `form:"smart_tip_threshold"`
   181  }
   182  
   183  // Tipping configurations for readers supporting on-reader tips
   184  type TerminalConfigurationTippingParams struct {
   185  	// Tipping configuration for AUD
   186  	AUD *TerminalConfigurationTippingAUDParams `form:"aud"`
   187  	// Tipping configuration for CAD
   188  	CAD *TerminalConfigurationTippingCADParams `form:"cad"`
   189  	// Tipping configuration for CHF
   190  	CHF *TerminalConfigurationTippingCHFParams `form:"chf"`
   191  	// Tipping configuration for CZK
   192  	CZK *TerminalConfigurationTippingCZKParams `form:"czk"`
   193  	// Tipping configuration for DKK
   194  	DKK *TerminalConfigurationTippingDKKParams `form:"dkk"`
   195  	// Tipping configuration for EUR
   196  	EUR *TerminalConfigurationTippingEURParams `form:"eur"`
   197  	// Tipping configuration for GBP
   198  	GBP *TerminalConfigurationTippingGBPParams `form:"gbp"`
   199  	// Tipping configuration for HKD
   200  	HKD *TerminalConfigurationTippingHKDParams `form:"hkd"`
   201  	// Tipping configuration for MYR
   202  	MYR *TerminalConfigurationTippingMYRParams `form:"myr"`
   203  	// Tipping configuration for NOK
   204  	NOK *TerminalConfigurationTippingNOKParams `form:"nok"`
   205  	// Tipping configuration for NZD
   206  	NZD *TerminalConfigurationTippingNZDParams `form:"nzd"`
   207  	// Tipping configuration for SEK
   208  	SEK *TerminalConfigurationTippingSEKParams `form:"sek"`
   209  	// Tipping configuration for SGD
   210  	SGD *TerminalConfigurationTippingSGDParams `form:"sgd"`
   211  	// Tipping configuration for USD
   212  	USD *TerminalConfigurationTippingUSDParams `form:"usd"`
   213  }
   214  
   215  // An object containing device type specific settings for Verifone P400 readers
   216  type TerminalConfigurationVerifoneP400Params struct {
   217  	// A File ID representing an image you would like displayed on the reader.
   218  	Splashscreen *string `form:"splashscreen"`
   219  }
   220  
   221  // Returns a list of Configuration objects.
   222  type TerminalConfigurationListParams struct {
   223  	ListParams `form:"*"`
   224  	// Specifies which fields in the response should be expanded.
   225  	Expand []*string `form:"expand"`
   226  	// if present, only return the account default or non-default configurations.
   227  	IsAccountDefault *bool `form:"is_account_default"`
   228  }
   229  
   230  // AddExpand appends a new field to expand.
   231  func (p *TerminalConfigurationListParams) AddExpand(f string) {
   232  	p.Expand = append(p.Expand, &f)
   233  }
   234  
   235  type TerminalConfigurationBBPOSWisePOSE struct {
   236  	// A File ID representing an image you would like displayed on the reader.
   237  	Splashscreen *File `json:"splashscreen"`
   238  }
   239  type TerminalConfigurationOffline struct {
   240  	// Determines whether to allow transactions to be collected while reader is offline. Defaults to false.
   241  	Enabled bool `json:"enabled"`
   242  }
   243  type TerminalConfigurationTippingAUD struct {
   244  	// Fixed amounts displayed when collecting a tip
   245  	FixedAmounts []int64 `json:"fixed_amounts"`
   246  	// Percentages displayed when collecting a tip
   247  	Percentages []int64 `json:"percentages"`
   248  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   249  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   250  }
   251  type TerminalConfigurationTippingCAD struct {
   252  	// Fixed amounts displayed when collecting a tip
   253  	FixedAmounts []int64 `json:"fixed_amounts"`
   254  	// Percentages displayed when collecting a tip
   255  	Percentages []int64 `json:"percentages"`
   256  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   257  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   258  }
   259  type TerminalConfigurationTippingCHF struct {
   260  	// Fixed amounts displayed when collecting a tip
   261  	FixedAmounts []int64 `json:"fixed_amounts"`
   262  	// Percentages displayed when collecting a tip
   263  	Percentages []int64 `json:"percentages"`
   264  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   265  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   266  }
   267  type TerminalConfigurationTippingCZK struct {
   268  	// Fixed amounts displayed when collecting a tip
   269  	FixedAmounts []int64 `json:"fixed_amounts"`
   270  	// Percentages displayed when collecting a tip
   271  	Percentages []int64 `json:"percentages"`
   272  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   273  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   274  }
   275  type TerminalConfigurationTippingDKK struct {
   276  	// Fixed amounts displayed when collecting a tip
   277  	FixedAmounts []int64 `json:"fixed_amounts"`
   278  	// Percentages displayed when collecting a tip
   279  	Percentages []int64 `json:"percentages"`
   280  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   281  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   282  }
   283  type TerminalConfigurationTippingEUR struct {
   284  	// Fixed amounts displayed when collecting a tip
   285  	FixedAmounts []int64 `json:"fixed_amounts"`
   286  	// Percentages displayed when collecting a tip
   287  	Percentages []int64 `json:"percentages"`
   288  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   289  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   290  }
   291  type TerminalConfigurationTippingGBP struct {
   292  	// Fixed amounts displayed when collecting a tip
   293  	FixedAmounts []int64 `json:"fixed_amounts"`
   294  	// Percentages displayed when collecting a tip
   295  	Percentages []int64 `json:"percentages"`
   296  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   297  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   298  }
   299  type TerminalConfigurationTippingHKD struct {
   300  	// Fixed amounts displayed when collecting a tip
   301  	FixedAmounts []int64 `json:"fixed_amounts"`
   302  	// Percentages displayed when collecting a tip
   303  	Percentages []int64 `json:"percentages"`
   304  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   305  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   306  }
   307  type TerminalConfigurationTippingMYR struct {
   308  	// Fixed amounts displayed when collecting a tip
   309  	FixedAmounts []int64 `json:"fixed_amounts"`
   310  	// Percentages displayed when collecting a tip
   311  	Percentages []int64 `json:"percentages"`
   312  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   313  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   314  }
   315  type TerminalConfigurationTippingNOK struct {
   316  	// Fixed amounts displayed when collecting a tip
   317  	FixedAmounts []int64 `json:"fixed_amounts"`
   318  	// Percentages displayed when collecting a tip
   319  	Percentages []int64 `json:"percentages"`
   320  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   321  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   322  }
   323  type TerminalConfigurationTippingNZD struct {
   324  	// Fixed amounts displayed when collecting a tip
   325  	FixedAmounts []int64 `json:"fixed_amounts"`
   326  	// Percentages displayed when collecting a tip
   327  	Percentages []int64 `json:"percentages"`
   328  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   329  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   330  }
   331  type TerminalConfigurationTippingSEK struct {
   332  	// Fixed amounts displayed when collecting a tip
   333  	FixedAmounts []int64 `json:"fixed_amounts"`
   334  	// Percentages displayed when collecting a tip
   335  	Percentages []int64 `json:"percentages"`
   336  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   337  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   338  }
   339  type TerminalConfigurationTippingSGD struct {
   340  	// Fixed amounts displayed when collecting a tip
   341  	FixedAmounts []int64 `json:"fixed_amounts"`
   342  	// Percentages displayed when collecting a tip
   343  	Percentages []int64 `json:"percentages"`
   344  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   345  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   346  }
   347  type TerminalConfigurationTippingUSD struct {
   348  	// Fixed amounts displayed when collecting a tip
   349  	FixedAmounts []int64 `json:"fixed_amounts"`
   350  	// Percentages displayed when collecting a tip
   351  	Percentages []int64 `json:"percentages"`
   352  	// Below this amount, fixed amounts will be displayed; above it, percentages will be displayed
   353  	SmartTipThreshold int64 `json:"smart_tip_threshold"`
   354  }
   355  type TerminalConfigurationTipping struct {
   356  	AUD *TerminalConfigurationTippingAUD `json:"aud"`
   357  	CAD *TerminalConfigurationTippingCAD `json:"cad"`
   358  	CHF *TerminalConfigurationTippingCHF `json:"chf"`
   359  	CZK *TerminalConfigurationTippingCZK `json:"czk"`
   360  	DKK *TerminalConfigurationTippingDKK `json:"dkk"`
   361  	EUR *TerminalConfigurationTippingEUR `json:"eur"`
   362  	GBP *TerminalConfigurationTippingGBP `json:"gbp"`
   363  	HKD *TerminalConfigurationTippingHKD `json:"hkd"`
   364  	MYR *TerminalConfigurationTippingMYR `json:"myr"`
   365  	NOK *TerminalConfigurationTippingNOK `json:"nok"`
   366  	NZD *TerminalConfigurationTippingNZD `json:"nzd"`
   367  	SEK *TerminalConfigurationTippingSEK `json:"sek"`
   368  	SGD *TerminalConfigurationTippingSGD `json:"sgd"`
   369  	USD *TerminalConfigurationTippingUSD `json:"usd"`
   370  }
   371  type TerminalConfigurationVerifoneP400 struct {
   372  	// A File ID representing an image you would like displayed on the reader.
   373  	Splashscreen *File `json:"splashscreen"`
   374  }
   375  
   376  // A Configurations object represents how features should be configured for terminal readers.
   377  type TerminalConfiguration struct {
   378  	APIResource
   379  	BBPOSWisePOSE *TerminalConfigurationBBPOSWisePOSE `json:"bbpos_wisepos_e"`
   380  	Deleted       bool                                `json:"deleted"`
   381  	// Unique identifier for the object.
   382  	ID string `json:"id"`
   383  	// Whether this Configuration is the default for your account
   384  	IsAccountDefault bool `json:"is_account_default"`
   385  	// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
   386  	Livemode bool `json:"livemode"`
   387  	// String indicating the name of the Configuration object, set by the user
   388  	Name string `json:"name"`
   389  	// String representing the object's type. Objects of the same type share the same value.
   390  	Object       string                             `json:"object"`
   391  	Offline      *TerminalConfigurationOffline      `json:"offline"`
   392  	Tipping      *TerminalConfigurationTipping      `json:"tipping"`
   393  	VerifoneP400 *TerminalConfigurationVerifoneP400 `json:"verifone_p400"`
   394  }
   395  
   396  // TerminalConfigurationList is a list of Configurations as retrieved from a list endpoint.
   397  type TerminalConfigurationList struct {
   398  	APIResource
   399  	ListMeta
   400  	Data []*TerminalConfiguration `json:"data"`
   401  }