Come funziona
- storekit invia
payments.payout.createdalla tua app quando viene creato un payout. - La tua app aggiunge una riga per payout con il totale per valuta, le ultime quattro cifre del conto bancario e la data stimata di arrivo.
- Tu spunti le righe rispetto al tuo estratto conto; qualsiasi payout oltre la data di arrivo e ancora non spuntato viene evidenziato.
Cosa ti serve
- I webhook abilitati sul tuo piano storekit (Settings → Developers).
- Un account Replit — il registro ha bisogno di un database e di un URL che resti attivo.
- Opzionale: un URL di incoming webhook Slack per un promemoria settimanale “ancora non riconciliato”.
Step 1: costruisci l’app
Incolla nel builder l’intero blocco in un unico messaggio.Either button opens the builder with the whole prompt below already filled in. Nothing starts until you press send, so read it through and edit the parts marked as yours first.
Prompt completo (clicca per espandere)
Prompt completo (clicca per espandere)
Step 2: collega storekit
1
Open the webhooks portal
In the dashboard sidebar, go to Settings → Webhooks. If your plan includes webhooks and they are not yet enabled, click Enable Webhooks. If the page shows Upgrade to enable webhooks, contact support to discuss adding webhooks to your plan.
2
Add your app as an endpoint
In the embedded portal, add a new endpoint, paste the webhook URL your app builder gave you, and tick only the event types the recipe needs.
3
Copy the signing secret into your app
Open the endpoint you just created and copy its signing secret. In your app builder, save it as the environment variable
STOREKIT_WEBHOOK_SECRET (builders call this “secrets” or “environment variables”). Redeploy if the builder asks you to.4
Send a test event
Use the portal’s test option on the endpoint to send a sample event. The delivery log shows the response code from your app. A
2xx means your app accepted it; anything else, read the response body in the log — it is usually a missing secret.payments.payout.created per questo endpoint. Usa l’opzione di test del portale con quel tipo di evento per creare la tua prima riga.
Step 3: riconcilia
Quando arriva il prossimo payout reale, confronta la riga con Analytics → Accounting → Payouts nella dashboard e con il tuo estratto conto, poi spuntala. I payout seguono la tua pianificazione dei payout, quindi la prima riga reale potrebbe richiedere qualche giorno.Idee
- Invia automaticamente al commercialista: chiedi al builder di inviare via email il CSV del mese il 1° tramite un provider come Resend o Postmark.
- Match per importo: incolla un CSV dell’estratto conto e lascia che l’app suggerisca corrispondenze per importo e data.
- Più negozi: esegui un endpoint per account storekit e aggiungi un’etichetta “store” da una variabile d’ambiente così che il registro possa essere unito.
Cosa non fa
- Non spiega cosa c’è dentro un payout. L’evento contiene i totali, non gli ordini, le commissioni o i rimborsi che ci stanno dietro; per quello usa il report commissioni e il report transazioni.
- Parte dal giorno in cui la colleghi. I payout precedenti sono nella dashboard, non nel flusso di eventi.
- Non è una prova di pagamento. L’evento dice che un payout è stato creato; se e quando arriva è una questione tra il provider di pagamento e la tua banca.
- È il tuo servizio. Il supporto di storekit può confermare che l’evento ha raggiunto il tuo URL e il codice di risposta; il registro e l’esportazione sono tuoi.
Correlati
Payload payments.payout.created
Il payload completo, inclusi i campi che questa recipe deliberatamente non memorizza.
Come funzionano i payout
Tempistiche, commissioni e dove i payout appaiono nella dashboard.
Scrivere un prompt che funziona
La struttura dietro questo prompt e cosa dire quando il builder sbaglia.
Report commissioni
Cosa è stato dedotto prima del payout.