Blame | Last modification | View Log | RSS feed
package com.smartdukaan.cron.scheduled;/*** Supplies a g-recaptcha-response token for the Motorola warranty page.** The page is Oracle Service Cloud (RightNow). Its lookup endpoint answers* "==CHALLENGE REQUIRED==" and hands back a Google reCAPTCHA v2 config* (sitekey 6LcHf0wUAAAAAFxRHKequHkHUGyUWA5dy24ZaB5s) instead of the warranty* payload, on the FIRST lookup of a clean session -- it is not rate-triggered.** This is deliberately an unimplemented seam. reCAPTCHA v2 is not a puzzle with* a computable answer the way vivo's 4-char image or the oppo/realme DingXiang* slider are, so there is no solver to write here in the way CaptchaService* solves vivo. Point this at whatever token source is actually sanctioned --* the Lenovo partner warranty API (supportapi.lenovo.com, ClientID-based) is* the route that removes the need for a browser at all.** Until a bean implementing this exists, CheckMotorolaWarrantyTask detects the* challenge, logs it once, and abandons the batch rather than hammering the* endpoint with lookups that cannot succeed.*/public interface MotorolaChallengeSolver {/*** @param siteKey reCAPTCHA sitekey scraped from the challenge payload* @param pageUrl the warranty page the challenge was raised on* @return a token to post back as g-recaptcha-response, or null if none* can be supplied (the caller then skips the batch)*/String solve(String siteKey, String pageUrl);}