LogoLogo
v4.0
v4.0
  • 🏠Guida tecnica
  • 🕗Changelog
  • 🔢Setup iniziale
    • Adesione tramite l'Area Riservata
    • Iscrizione al Developer Portal
  • Funzionalità
    • 📦Pubblicare un servizio
      • Creare un servizio
      • Provare un servizio in test
      • Revisione del servizio
      • Visibilità del servizio
      • Importare servizi nell'Area Riservata
      • Dati obbligatori
        • Attributi
        • Service Metadata
      • Informazioni sensibili
      • Stato del servizio
      • Chiave manage
    • ✉️Inviare un messaggio
      • Messaggi di test
      • 📎Aggiungere allegati (Premium)
        • Specifiche degli endpoint di recupero degli allegati
  • 📐API
    • 📐OpenAPI
    • API Servizi
      • Manage Service: Get
      • Manage Service: Get keys
      • Manage Service: Get User Services
      • Manage Service: Create
      • Manage Service: Delete
      • Manage Service: Update
      • Manage Service: Request Review
      • Manage Service: Release
      • Manage Service: Get Released
      • Manage Service: Unpublish
      • Manage Service: Regenerate api key
      • Manage Service: Upload service logo
      • Upload organization logo
    • API Messaggi
      • Get a User Profile using POST
      • Submit a Message passing the user fiscal_code in the request body
      • Get Message
      • Get Subscriptions Feed
      • ⚠️Get a User Profile
      • ⚠️Submit a Message passing the user fiscal_code as path parameter
    • Errori comuni
    • Specifiche API
  • 🔑Abilitazioni
    • Test con Codici Fiscali reali
    • Test invio avvisi pagoPA
    • Invio messaggi massivo
    • Subscription feed
    • Gestione dei servizi
    • Funzionalità Premium
  • Risorse Utili
    • ❓Supporto agli Enti
    • 📘Glossario
Powered by GitBook
On this page
  1. API
  2. API Messaggi

Get Subscriptions Feed

PreviousGet MessageNextGet a User Profile

Questa modalità è riservata agli enti centrali o di livello nazionale.

Descrizione

L'API Get Subscriptions Feed permette di effettuare il download degli hash dei Codici Fiscali dei cittadini iscritti/disiscritti a un servizio per una specifica data (UTC-YYYY-MM-DD).

Lo scopo del subscription feed è mettere a disposizione degli enti centrali uno strumento per minimizzare le chiamate verso l'infrastruttura di IO attraverso un filtro costruito dall’ente stesso.

Le informazioni del subscription feed sono aggiornate al giorno precedente. Per la costruzione del subscription feed, dovrai interrogare il servizio per ogni giorno a partire dalla data del 24/03/2020 fino alla data attuale e salvare i dati nella tua infrastruttura.

In nessun caso sarà possibile richiedere i codici fiscali in chiaro.

Per una risposta corretta si ottiene:

  1. lo status code della risposta è 200

  2. nel body di risposta il campo subscriptions e unsubscriptions

Esempi

### REQUEST
curl --location --request GET 'https://api.io.pagopa.it/api/v1/subscriptions-feed/2020-02-23' \
--header 'Ocp-Apim-Subscription-Key: __YOUR_API_KEY__'
### RESPONSE
{
"dateUTC": "2020-02-23",
"subscriptions": [ "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" ],
"unsubscriptions": [ ]
}

Risorse utili

📐
https://developer.io.italia.it/openapi.html#operation/getSubscriptionsFeedForDate
Scopri come richiedere l'autorizzazione ->

Get Subscriptions Feed

get

Returns the hashed fiscal codes of users that subscribed to or unsubscribed from your service on the provided date (UTC).

By querying this feed everyday, you will be able to retrieve the "delta" of users that subscribed and unsubscribed from your service. You will have to keep a list of users somewhere in your infrastructure that you will keep updated at all times by adding the subscribed users and removing the unsubscribed users.

You will then be able to query this local list to know which users you can send messages, to without having to query getProfile for each message.

To avoid sharing the citizens fiscal codes, the API will provide the hex encoding of the SHA256 hash of the upper case fiscal code. In pseudo code CF_HASH = LOWERCASE(HEX(SHA256(UPPERCASE(CF)))).

Access to this feed is subject to case-by-case authorization, and it is primarily intended for large-scale services, such as those pertaining to organizations that have an extensive user base (including geographically), and/or need to send very high volumes of messages per day.

This feed serves the purpose of minimizing data processing activities while preserving optimization of API calls and data accuracy. Organizations allowed are required to query this feed everyday.

Authorizations
Path parameters
dateanyRequired

A date in the format YYYY-MM-DD.

Responses
200
Found.
application/json
401
Unauthorized
403
Forbidden.
404
Subscriptions feed not available yet.
application/json
429
Too many requests
get
GET /api/v1/subscriptions-feed/{date} HTTP/1.1
Host: api.io.pagopa.it
Ocp-Apim-Subscription-Key: YOUR_API_KEY
Accept: */*
{
  "dateUTC": "text",
  "subscriptions": [
    "text"
  ],
  "unsubscriptions": [
    "text"
  ]
}
  • Descrizione
  • GETGet Subscriptions Feed
  • Esempi
  • Risorse utili