{"openapi":"3.0.0","servers":[{"description":"Production Server","url":"https://secure.4players.de"},{"description":"SwaggerHub API Auto Mocking","url":"https://virtserver.swaggerhub.com/4Players-GmbH/4players-payment/1.0.0"}],"info":{"description":"4Players Payment is the payment solution from 4Players and empowers developers to leverage the ease of use of a matured, full-service payment solution including subscriptions and is world-wide available.","version":"1.0.0","title":"4Players Payment API","contact":{"email":"info@4players.de"},"license":{"name":"Apache 2.0","url":"http://www.apache.org/licenses/LICENSE-2.0.html"}},"tags":[{"name":"account","description":"Account"},{"name":"bookings","description":"Booking"},{"name":"codes","description":"Codes"},{"name":"country","description":"Country"},{"name":"customer","description":"Customer"},{"name":"invoice","description":"Invoice"},{"name":"newsletter","description":"Newsletter"},{"name":"order","description":"Order"},{"name":"subscriptions","description":"Subscriptions"}],"paths":{"/public/api/v1/account/v1/login":{"post":{"operationId":"login","tags":["account"],"description":"Log into a fusion account using email and password. Returns some profile Info and a fusion Session ID via cookie.","security":[{}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginPayload"}}},"description":"Login payload","required":true},"responses":{"200":{"description":"Returns customer info if login successfull","headers":{"Set-Cookie":{"schema":{"type":"string","description":"Session-ID of the customer. Used accross 4Players services. A md5-hash.","example":"fusion_sid=999f999f9ff999ff9999ff999f99999"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountResponse"}}}},"300":{"$ref":"#/components/responses/SuccessFalseResponse"}}}},"/public/api/v1/account/v1/getfusionuser":{"get":{"operationId":"getFusionUser","tags":["account"],"security":[{"fusionSidInCookieAuth":[]},{"fusionSidInHeaderAuth":[]}],"description":"Returns some extenden customer data","responses":{"200":{"description":"Returns some extenden customer data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountResponse"}}}},"300":{"$ref":"#/components/responses/SuccessFalseResponse"}}}},"/public/api/v1/account/v1/getprofile":{"get":{"operationId":"getProfileId","tags":["account"],"security":[{"fusionSidInCookieAuth":[]},{"fusionSidInHeaderAuth":[]}],"description":"Returns fusion profile data","responses":{"200":{"description":"Returns fusion profile data","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetProfileResponse"}}}},"300":{"$ref":"#/components/responses/SuccessFalseResponse"}}}},"/public/api/v1/bookings":{"get":{"operationId":"getBookings","tags":["bookings"],"description":"Get a List of all payment internal transaction bookings of the customer","responses":{"200":{"description":"An array of available store products","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BookingResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/codes":{"get":{"operationId":"getCodes","tags":["codes"],"description":"Get a list of store products, that can be retrieved via code/serial key","responses":{"200":{"description":"An array of available store products","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CodesResponse"}}}}}}},"/public/api/v1/codes/{itemId}":{"get":{"operationId":"getCodeById","tags":["codes"],"description":"Get a store products, that can be retrieved via code/serial key","parameters":[{"in":"path","name":"itemId","description":"The ID of the code to request","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"The requested store code","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CodeResponse"}}}}}}},"/public/api/v1/codes/{itemId}/activate":{"get":{"operationId":"activateCode","tags":["codes"],"parameters":[{"in":"path","name":"itemId","description":"The ID of the item to request","required":true,"schema":{"type":"integer"}}],"description":"Tries to activate a store product using a available code","responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"300":{"description":"No prodct ID given","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"Already reserved","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Code wurde bereits bestellt (Store-ID: [STOREID])"},"code":{"example":1001}}}}}]}}}},"x-1002":{"description":"No quota for the code left","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Kein Code verfügbar"},"code":{"example":1002}}}}}]}}}},"x-1003":{"description":"Internal error adding code to customer","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Code konnte nicht zugewiesen werden"},"code":{"example":1003}}}}}]}}}},"x-1004":{"description":"Code already reserved this month","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Code wurde bereits in diesem Monat angefordert"},"code":{"example":1004}}}}}]}}}}}}},"/public/api/v1/codes/0/assigned":{"get":{"operationId":"getAssigned","tags":["codes"],"description":"Returns an array of codes assig to the current customer","responses":{"200":{"description":"An array of codes assig to the current customer","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CodeAssignResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/codes/{itemId}/canassignlimited":{"get":{"operationId":"getCanAssignLimited","tags":["codes"],"description":"Check if current product can be reserved","parameters":[{"in":"path","name":"itemId","description":"The ID of the store product to request","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1004":{"content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Code wurde bereits in diesem Monat angefordert"},"code":{"example":1004}}}}}]}}}}}}},"/public/api/v1/codes/{itemId}/importcodes":{"post":{"operationId":"importCodes","tags":["codes"],"security":[{"BearerAuth":[]}],"parameters":[{"in":"path","name":"itemId","description":"The ID of the store product to request","required":true,"schema":{"type":"integer"}}],"description":"Import new codes for an existing store product","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImportCodePayload"}}}},"responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"300":{"description":"Error while adding codes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"Store product can't be found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/codes/{itemId}/importcodefiles":{"post":{"operationId":"importCodeFiles","tags":["codes"],"parameters":[{"in":"path","name":"itemId","description":"The Itemid of the storeproduct to at codes for.","required":true,"schema":{"type":"integer"}}],"requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/ImportCodeFilesPayload"}}}},"responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"300":{"description":"Error while addimg codes.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"400":{"description":"Store product can't be found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/country/0/getexchangerates":{"get":{"operationId":"getEchangeRates","tags":["country"],"responses":{"200":{"description":"An array of currency exchange rates to €. Rates are refreshed every night between 3 AM and 4 AM MEZ","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeRatesResponse"}}}}}}},"/public/api/v1/country/0/getcountrybyip":{"get":{"operationId":"getCountryByIp","tags":["country"],"responses":{"200":{"description":"Returns the current country ISO-Code based on the IP address of client request.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IpListResponse"}}}}}}},"/public/api/v1/customer":{"get":{"operationId":"getCurrentCustomer","tags":["customer"],"responses":{"200":{"description":"A customer object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/customer/{hashedId}":{"get":{"operationId":"getCustomerById","tags":["customer"],"parameters":[{"in":"path","required":true,"name":"hashedId","schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"responses":{"200":{"description":"A customer object","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/invoices":{"get":{"operationId":"getInvoices","tags":["invoice"],"parameters":[{"in":"query","name":"filter:id","description":"Comma seperated list of hashed invoice ids to return.","required":false,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09,Z244dVFyaHEyUkUvWTlrVlQxcDZnQT10,Z244dVFyaHEyUkUvWTlrVlQxcDZnQT11"}}],"description":"Get a list of all invoices of the current customer","responses":{"200":{"description":"An array of all invoices","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoicesResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/invoices/{hashedId}":{"get":{"operationId":"getInvoiceById","tags":["invoice"],"parameters":[{"in":"path","name":"hashedId","description":"Hashed invoice id to return.","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"description":"Get a list of all invoices of the current customer","responses":{"200":{"description":"The requested invoice","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/newsletter":{"get":{"operationId":"getNewsletterLists","tags":["newsletter"],"security":[{}],"description":"Requests a List of available Newsletters customers can subscribe to","responses":{"200":{"description":"A List of available Newsletters customers can subscribe to","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterListResponse"}}}}}}},"/public/api/v1/newsletter/{customerId}":{"delete":{"operationId":"removeCustomerFromNewsletterList","tags":["newsletter"],"security":[{"BearerAuth":[]}],"parameters":[{"in":"path","name":"customerId","description":"Internal ID of the customer which is going to be removed. *Not* the public available Customer-ID","required":true,"schema":{"type":"integer","example":12345}},{"in":"query","name":"list","description":"ID of the Newsletter-List to remove the customer from","required":true,"schema":{"type":"integer","example":1}}],"description":"Removes a customers subscription from a newsletter list","responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-0":{"description":"Customer does not seem to have a subscription","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"No Subscriptions found"},"code":{"example":0}}}}}]}}}},"x-6":{"description":"Error requesting Customer-Data at our newsletter provider","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"Error Requesting User"},"code":{"example":6}}}}}]}}}}}}},"/public/api/v1/newsletter/{customerId}/customersubscriptions":{"get":{"operationId":"getNewsletterSubscriptionsByCustomerId","tags":["newsletter"],"security":[{"BearerAuth":[]}],"parameters":[{"in":"path","name":"customerId","description":"Internal ID of the customer which is going to be removed. *Not* the public available Customer-ID","required":true,"schema":{"type":"integer","example":12345}}],"description":"Gets a List of all Newsletter subscriptions of the requested customer","responses":{"200":{"description":"A List of available Newsletters customers can subscribe to","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewsletterSubscriptionResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/orders/{orderId}/triggerscillaction":{"get":{"operationId":"triggerScillAction","tags":["order"],"security":[{}],"description":"Register a scill service and trigger corresponding actions","parameters":[{"in":"path","name":"orderId","description":"Id of a placed order","required":true,"schema":{"type":"integer","example":123456}}],"responses":{"200":{"description":"If the action could be triggered","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"Order-ID could not be found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/orders/{orderInfoId}/validate":{"get":{"operationId":"validateOrderByInfoId","tags":["order"],"security":[{"BearerAuth":[]}],"description":"Register a scill service and trigger corresponding actions","parameters":[{"in":"path","name":"orderInfoId","description":"Id of a placed order that is not accepted yet","required":true,"schema":{"type":"integer","example":123456}}],"responses":{"200":{"description":"Validation infos","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidationInfo"}}}},"300":{"description":"Validation failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidationInfo"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"Order-Info could not be found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/subscriptions":{"get":{"operationId":"getSubscriptions","tags":["subscriptions"],"description":"Get a list of all customer subscriptions","parameters":[{"in":"query","name":"service","description":"The service name of the subscriptions to return","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"An array of subscriptions","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionsResponse"}}}}}}},"/public/api/v1/{subscriptionId}/subscriptions":{"get":{"operationId":"getSubscriptionById","tags":["subscriptions"],"parameters":[{"in":"path","name":"subscriptionId","description":"The Hashed-Id of the subscription to request","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"responses":{"200":{"description":"The requested subscription","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/subscriptions/{subscriptionId}/addflexibleoption":{"parameters":[{"in":"path","name":"subscriptionId","description":"The id of the subscription","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"post":{"tags":["subscriptions"],"summary":"Add a flexible option to an existing subscription","operationId":"addFlexibleOption","description":"Add this route to change a tarif parameter of that subscription. For example you can change the number of available slots. The option will be added to the subscription and the invoice value will change by the amount you provide.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddFlexibleOptionPayload"}}},"description":"Foreign user identifier.","required":true},"responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"400":{"description":"bad input parameter"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}}}}},"/public/api/v1/subscriptions/{subscriptionId}/quit":{"parameters":[{"in":"path","name":"subscriptionId","description":"The id of the subscription","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"get":{"tags":["subscriptions"],"summary":"Quit a subscription","operationId":"quitSubscription","description":"Use this to quit a subscription","responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}},"x-4001":{"description":"Subscription can not be quitted. That can because a quit is not allowed for the specific product, or it is already quitted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ERROR: Quit is not allowed on this subscription"},"code":{"example":4001}}}}}]}}}},"x-5001":{"description":"An internal error occured while trying to quit the subscription","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ERROR: Could not cancel subscription!"},"code":{"example":5001}}}}}]}}}}}}},"/public/api/v1/subscriptions/{subscriptionId}/unquit":{"parameters":[{"in":"path","name":"subscriptionId","description":"The id of the subscription","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"get":{"tags":["subscriptions"],"summary":"Unquit a subscription","operationId":"unquitSubscription","description":"Use this to unquit a subscription","responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"},"x-1001":{"description":"ID not found","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ID could not be found"},"code":{"example":1001}}}}}]}}}},"x-4001":{"description":"Subscription can not be unquitted. That can because a quit is not allowed for the specific product, or it is not quitted","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ERROR: Revoking of cancellation is not allowed on this subscription"},"code":{"example":4001}}}}}]}}}},"x-5001":{"description":"Could not unquit because of an internal error","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/Error"},{"properties":{"error":{"properties":{"message":{"example":"ERROR: Could not revoke cancellation of subscription!"},"code":{"example":5001}}}}}]}}}}}}},"/public/api/v1/subscriptions/0/raisets3":{"get":{"tags":["subscriptions"],"summary":"Raise the price of TS3 tariffs","deprecated":true,"operationId":"raisets3","description":"This route was used when 4P had to raise the prices of our TS3 tariffs because of i price change in our contract with TS3.","responses":{"200":{"$ref":"#/components/responses/SuccessResponse"},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}},"/public/api/v1/subscriptions/{subscriptionId}/checktariffchange":{"parameters":[{"in":"path","name":"subscriptionId","description":"The id of the subscription","required":true,"schema":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}],"get":{"tags":["subscriptions"],"summary":"Get Tariff Change Infos","operationId":"checkTariffChange","description":"Get Infos if Tariff change is allowed and infos about current state","responses":{"200":{"description":"Info about Tariff","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckTariffChangeResponse"}}}},"x-1000":{"$ref":"#/components/responses/FailedAuthorizationError"}}}}},"security":[{"fusionSidInCookieAuth":[]},{"fusionSidInHeaderAuth":[]},{"BearerAuth":[]},{"oAuthNoScopes":[]}],"components":{"securitySchemes":{"fusionSidInCookieAuth":{"type":"apiKey","in":"cookie","name":"fusion_sid"},"fusionSidInHeaderAuth":{"type":"apiKey","in":"header","name":"fusion_sid"},"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"Access Token or API-Key","description":"You can either use the API-Key or an Access Token generated earlier with the auth/generate-access-token route. Only use API-Key on server side, never expose it on client side. Use Access Tokens where possible. More info on this topic can be found here https://beta.developers.scillgame.com/api/authentication.html"},"oAuthNoScopes":{"type":"oauth2","flows":{"implicit":{"authorizationUrl":"https://api.example.com/oauth2/authorize","scopes":{}}}}},"responses":{"SuccessResponse":{"description":"Success","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessResponse"}}}},"SuccessFalseResponse":{"description":"Failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuccessFalseResponse"}}}},"FailedAuthorizationError":{"description":"Authorization failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FailedAuthorizationError"}}}}},"schemas":{"Account":{"type":"object","properties":{"fusion_sid":{"type":"string","example":"999f9999f9ff999ff9999ff999f99999","description":"Session-ID of the customer. Used accross 4Players services. A md5-hash."},"email":{"type":"string","example":"test@example.com","description":"Customer email"},"language":{"type":"string","example":"de","description":"Costumer language. Shortcode"},"firstname":{"type":"string","example":"John","description":"First name of customer","nullable":true},"lastname":{"type":"string","example":"Doe","description":"Last name of customer","nullable":true}}},"AccountResponse":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Account"},"error":{"$ref":"#/components/schemas/NoError"}}},"GetProfileResponse":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Profile"},"error":{"$ref":"#/components/schemas/NoError"}}},"Profile":{"type":"object","properties":{"pid":{"type":"integer","example":9876543,"description":"Internal profile ID"},"cid":{"type":"integer","example":625678912,"description":"Customer Number"},"profile_name":{"type":"string","example":"","description":"Fusion profile name"},"avatarImageUrl":{"type":"string","nullable":true,"example":null,"description":"Fusion avatar image url"},"photo":{"type":"string","example":"https://login.4players.de/","description":"URL to a photo. If none set it's https://login.4players.de/"},"signature":{"type":"string","example":"Lorem ipsum dolorem sit.","description":"Signature for forum comments"},"magazin_wertung":{"type":"boolean","example":true},"showsignatures":{"type":"boolean","example":true},"achievements":{"type":"boolean","example":true},"purEndDate":{"type":"string","example":"2022-12-12 23:59:59","description":"When the pur-Service (4Players Magazine) stops"},"hasPur":{"type":"boolean","example":true,"description":"If the customer subscribed to 4Players PUR (4Players Magazine)"},"fid":{"type":"integer","example":5678912,"description":"Fusion ID"}}},"AddFlexibleOptionPayload":{"type":"object","required":["userident","option"],"properties":{"userident":{"type":"string","example":"195.4.16.254:10128","description":"The user ident stored along the subscription. Subscriptions have a user ident that connects the subscription to the actual service."},"option":{"$ref":"#/components/schemas/FlexibleOptionDetails"}}},"FlexibleOptionDetails":{"type":"object","required":["name","bruttobetrag","artikelid","tarifoptionid","params"],"properties":{"name":{"type":"string","example":"No branding required","description":"The name of the option. This will be printed in the invoice"},"bruttobetrag":{"type":"integer","example":320,"description":"The price of the option that will be added to the invoice. It is Euro-Cent, i.e. for 1 EUR you need to set the value to 100"},"artikelid":{"type":"integer","example":1823,"description":"The article ID that will be used for reporting. Use the article ID you got from the Payment team."},"tarifoptionid":{"type":"integer","example":392732,"description":"The ID of the tarif option that will be used as a connection. The payment team will give you that id"},"params":{"type":"string","example":"isbranded=0","description":"This is a string encoded in typical query encoding style. These values will be applied to the tarif parameters and will change the actual business logic accordingle."}}},"Subscription":{"type":"object","properties":{"id":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"},"name":{"type":"string","example":"Nextcloud 12 Monate"},"service":{"type":"string","example":"CloudApps"},"isPaid":{"type":"boolean","example":true},"isActive":{"type":"boolean","example":true},"customer":{"type":"string","example":"https://secure.4players.de/public/api/v1/customers/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"},"start":{"type":"string","example":"2020-20-20"},"end":{"type":"boolean","example":null},"nextInvoice":{"type":"string","example":"2020-20-20"},"invoices":{"type":"object","properties":{"url":{"type":"string","example":"https://secure.4players.de/public/api/v1/invoices/"},"ids":{"type":"array","items":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}}},"amount":{"type":"number","example":2.49},"changeAllowed":{"type":"boolean","example":null},"nextChange":{"type":"integer","example":1609974000},"remainingAmount":{"type":"number","example":0.17},"remainingTime":{"type":"integer","example":31},"interval":{"type":"integer","example":30},"positions":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","example":"Nextcloud 12 Monate"},"amount":{"type":"number","example":2.49},"userident":{"type":"string","example":"pJZPCiIiUXrbrlCIt0jJ"},"params":{"type":"object","properties":{"tarifid":{"type":"string","example":"158"},"tarifgruppeid":{"type":"string","example":"41"},"tarifkategorieid":{"type":"string","example":"9"},"tarifservicekategorieid":{"type":"string","example":"9"},"servicetype":{"type":"string","example":"nextcloud"},"name":{"type":"string","example":"Nextcloud 12 Monate"},"preisgrund":{"type":"string","example":"249"},"laufzeitmonate":{"type":"string","example":"12"},"mbdiskquota":{"type":"string","example":"5"},"allowtarifchange":{"type":"string","example":"1"},"addwithstatus":{"type":"string","example":"14"},"preisanzeigebestellung":{"type":"string","example":"1"},"paymentidentvalue":{"type":"string","example":"1864"},"domain":{"type":"string","example":"4players.me"},"parenttarifid":{"type":"string","example":"0"},"subdomain":{"type":"string","example":"fubar"}}}}}},"url":{"type":"string","example":"https://secure.4players.de/public/api/v1/subscriptions/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}},"SubscriptionResponse":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Subscription"},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"SubscriptionsResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Subscription"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"Response":{"type":"object","properties":{"data":{"type":"object"},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"IpListResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"string","example":"DE"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"ExchangeRate":{"type":"object","properties":{"currencycode":{"type":"string","example":"AUD","description":"ISO-Code of currency"},"rate":{"type":"string","example":"1.6107","description":"Current exchange rate"}}},"ExchangeRatesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeRate"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"LoginPayload":{"type":"object","required":["email","password"],"properties":{"email":{"type":"string","description":"Customer Email used for login","example":"test@example.com"},"password":{"type":"string","description":"The customer password","example":"1234"}}},"ImportCodePayload":{"type":"object","properties":{"anleitung":{"description":"Info how to claim Product","type":"string","example":"Lorem Ipsum dolorem sit."},"codes":{"description":"Array of product codes","type":"array","items":{"type":"string","example":"XX-XX-XX-XX"}}}},"ImportCodeFilesPayload":{"type":"object","properties":{"anleitung":{"type":"string","example":"Lorem Ipsum dolorem sit.","description":"Info how to claim product"},"filename":{"description":"Multiple files are combined to one. One code per line. Comma not allowed","type":"array","items":{"type":"string","format":"binar"}}}},"SuccessResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"success":{"type":"boolean","example":true}}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"ValidationInfo":{"type":"object","properties":{"validated":{"type":"boolean","description":"If the order is valid","example":true},"sku":{"type":"string","description":"SKU of the product ordered","example":"de.4players.supporter.basic"},"orderId":{"type":"integer","description":"Id of a placed order that is not accepted yet","example":123456}}},"Success":{"type":"object","properties":{"result":{"type":"boolean","description":"If the action could be triggered","example":true}}},"SuccessFalseResponse":{"type":"object","properties":{"data":{"properties":{"success":{"example":false}}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"Error":{"type":"object","properties":{"data":{"nullable":true,"example":null},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"NoError":{"type":"object","properties":{"message":{"example":""},"code":{"example":0}}},"FailedAuthorizationError":{"allOf":[{"$ref":"#/components/schemas/Error"},{"type":"object","properties":{"error":{"properties":{"message":{"example":"Authorization failed"},"code":{"example":1000}}}}}]},"Code":{"type":"object","properties":{"id":{"type":"integer","example":1,"description":"ID of the voucher"},"imageUrl":{"type":"string","example":"https://storage.googleapis.com/fourplayers-mdp.appspot.com/goodies/v2/goodies_4netplayers_neu.jpg","description":"URL to an assigned promotional image"},"name":{"type":"string","example":"At vero eos et accusam et justo","description":"Name of the code"},"page":{"type":"integer","example":null,"description":"..."},"description":{"type":"string","example":"Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore","description":"Description for the code. Currently only available in one language (german is default)"},"reserved":{"type":"boolean","example":false,"description":"If the code is reserved to a customer. Set during order, before the order is completed"},"assigned":{"type":"boolean","example":false,"description":"If the code is already assigned to a customer"},"freeCodes":{"type":"integer","example":91,"description":"Remaining number of codes"},"finalDate":{"type":"string","example":"2020-12-31 23:59:59","description":"When the code stops to be usable"},"limited":{"type":"boolean","example":false,"description":"If the code is limited. Currently always false"},"active":{"type":"boolean","example":true,"description":"If the code is active"},"startDate":{"type":"string","example":"2020-03-02 00:00:00","description":"When the code starts to be valid"},"assignedCode":{"type":"string","example":"XX-XX-XX-XX-XX","description":"The used code for a store item"},"claimText":{"type":"string","example":"Lorem Ipsum dolorem sit","description":"A description how to claim the purchased product"}}},"CodeResponse":{"allOf":[{"$ref":"#/components/schemas/Response"},{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Code"}}}]},"CodesResponse":{"allOf":[{"$ref":"#/components/schemas/Response"},{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Code"}}}}]},"NewsletterListResponse":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer","description":"ID of the Newsletter-List","example":1},"name":{"type":"string","description":"(Display) Name of the Newsletter-List","example":"4Netplayers Newsletter"}}}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"NewsletterSubscription":{"type":"object","properties":{"id":{"type":"string","description":"ID of the Description in the database","example":"11"},"fusionId":{"type":"string","description":"4Players internal cross service customer ID","example":"5678912"},"MailjetMailinglistId":{"type":"string","description":"ID of the Newsletter-List","example":"1"},"subscribed":{"type":"string","description":"0|1 if the customer is subscriped","example":"1"},"subscriptionTime":{"type":"string","description":"When did the customer successfully subscribe","example":"2020-20-20 20:20:20"},"lastSync":{"type":"string","description":"When was the customer last synced with the newsletter provider","example":"2020-20-20 20:20:20"},"mailSent":{"type":"string","description":"When was the double-opt-in mail sent","example":"2020-20-19 20:20:20"},"created":{"type":"string","description":"When was the subscription created","example":"2020-20-18 20:20:20"}}},"NewsletterSubscriptionResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/NewsletterSubscription"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"CodeAssignResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Code"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"CheckTariffChangeResponse":{"type":"object","properties":{"data":{"type":"object","properties":{"nextInvoice":{"type":"integer","example":16,"description":"Days until next invoice"},"nextInvoiceTS":{"type":"integer","example":1612695600,"description":"Timestamp of next invoice"},"lastInvoice":{"type":"integer","example":13,"description":"Days since last invoice"},"lastInvoiceTS":{"type":"integer","example":1610066305,"description":"Timestamp of last invoice"},"lastChange":{"type":"integer","example":133,"description":"Days since last tariff change"},"lastChangeTS":{"type":"integer","example":1599688800,"description":"Timestamp of last tariff change"},"restValue":{"type":"integer","example":10000,"description":"Value of subscription deducted by used days"},"restValueMonth":{"type":"number","example":235.6,"description":"Value of subscription deducted by used days for one month"},"isQuit":{"type":"boolean","example":false,"description":"If the subscription is quit"},"isPaid":{"type":"boolean","example":true,"description":"If the subscription is paid"},"aboValue":{"type":"integer","example":20000,"description":"Value of subscription for the whole subscription time"},"minQuitData":{"type":"string","example":"2020-01-30","description":"Min runtime"},"minUnsubscribeData":{"type":"string","example":"2020-01-30","description":"Until this date subscription has to be quit before it is resubscripted"}}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"Customer":{"type":"object","properties":{"surname":{"type":"string","example":"Jon"},"lastname":{"type":"string","example":"Doe"},"address":{"type":"object","properties":{"street":{"type":"string","example":"Deelbögenkamp 4c"},"zip":{"type":"string","example":"22297"},"city":{"type":"string","example":"Hamburg"},"country":{"type":"string","example":"DE"},"url":{"type":"string","example":"/public/api/v1/addresses/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"},"customer":{"type":"string","example":"/public/api/v1/customers/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}},"email":{"type":"string","example":"test@example.com"},"fusionid":{"type":"integer","example":5678912,"description":"4Players internal cross service customer ID"},"cid":{"type":"integer","example":625678912,"description":"Payment customer ID"},"local":{"type":"string","example":"de_DE","description":"Locale of the customer"},"invoices":{"type":"object","description":"List of hashed invoices IDs","properties":{"url":{"type":"string","example":"/public/api/v1/invoices/"},"ids":{"type":"array","items":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}}},"subscriptions":{"type":"object","description":"List of hashed subscription IDs","properties":{"url":{"type":"string","example":"/public/api/v1/subscriptions/"},"ids":{"type":"array","items":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}}},"balance":{"type":"number","example":100.0,"description":"Current balance ot the customer"},"bookings":{"type":"array","description":"All payment internal transaction bookings of the customer","items":{"$ref":"#/components/schemas/Booking"}},"url":{"type":"string","example":"/public/api/v1/customers/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09"}}},"CustomerResponse":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Customer"},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"Booking":{"type":"object","properties":{"datum":{"type":"string","example":"2020-05-04","description":"When the transaction was issued"},"buchungsdatum":{"type":"string","example":"2020-05-04","description":"When the transaction was processed"},"betrag":{"type":"integer","example":-134,"description":"Amout of the transaction in Euro-Cent"},"gebuehr":{"type":"integer","example":0,"description":"Transaction fee"},"id":{"type":"string","example":"1234567890","description":"ID of the transaction"},"icon":{"type":"string","example":"pf pf-invoice-sign-alt-o","description":"CSS-Class used when displaying the transaction in a frontend"},"icon2":{"type":"string","example":"","description":"CSS-Class used when displaying the transaction in a frontend"},"mahngebuehr":{"type":"integer","example":0,"description":"Reminder fee"},"chargebackgebuehr":{"type":"integer","example":0,"description":"Chargeback fee"},"beschreibung":{"type":"string","example":"Rechnung Multigame Survival","description":"Description"},"beschreibungHTML":{"type":"string","example":"Rechnung Multigame Survival","description":"Description with HTML"},"saldo":{"type":"integer","example":100,"description":"Balance of the customer after this transaction"}}},"BookingResponse":{"type":"object","properties":{"data":{"description":"All payment internal transaction bookings of the customer","type":"array","items":{"$ref":"#/components/schemas/Booking"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"InvoicePosition":{"type":"object","properties":{"index":{"type":"integer","description":"Ordering index of the invoice item"},"name":{"type":"string","description":"Name of the invoice item"},"amount":{"type":"number","description":"Total item value with VAT"},"netamount":{"type":"number","description":"Total item value before VAT"},"tax":{"type":"number","description":"Item  VAT"},"pieceamount":{"type":"number","description":"Item value per piece with VAT"},"piecenetamount":{"type":"number","description":"Item value per piece before VAT"},"taxrate":{"type":"integer","description":"VAT of the customers home country"},"quantity":{"type":"integer","description":"How many items of the given article where ordered"},"start":{"type":"string","description":"Whe the subscription began"},"end":{"type":"string","description":"When the subscription is going to end."}},"example":[{"index":0,"name":"Sinusbot 12 Monate","amount":3.59,"netamount":3.09,"tax":0.5,"pieceamount":3.59,"piecenetamount":3.09,"taxrate":16,"quantity":1,"start":"2020-12-26","end":"2021-01-24"}]},"Invoice":{"type":"object","properties":{"id":{"type":"string","example":"Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09","description":"Hashed ID of the invoice"},"invoicenumber":{"type":"string","example":"4P2006066701","description":"Invoice number"},"date":{"type":"string","example":"2020-12-26 01:37:08","description":"Time when the invoice was issued"},"amount":{"type":"number","example":3.59,"description":"Total price of the order with VAT"},"netamount":{"type":"number","example":3.09,"description":"Total price of the order before VAT"},"tax":{"type":"number","example":0.5,"description":"Total VAT of the order"},"name":{"type":"string","example":"Sinusbot 12 Monate","description":"Name of the order"},"positions":{"type":"array","items":{"$ref":"#/components/schemas/InvoicePosition"}},"customer":{"type":"string","example":"/public/api/v1/customers/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09","description":"URL to the customer using the hashed ID"},"url":{"type":"string","example":"/public/api/v1/invoices/Z244dVFyaHEyUkUvWTlrVlQxcDZnQT09","description":"URL to this invoice item using the hashed ID"}}},"InvoicesResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Invoice"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}},"InvoiceResponse":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Invoice"}},"error":{"type":"object","properties":{"code":{"type":"integer","example":0},"message":{"type":"string","example":""}}}}}}}}