Publication de contacts (déprécié)

Ce web-service permet de publier des contacts à partir d’une liste de codes de contact.

Paramètres HTTP

Paramètre

Valeur

Route

contact

Méthode

GET

Paramètres URL

Nom

Description

Type

O/F

cdcontacts

liste de contacts

list(str)

F

dtmaj

Date de mise à jour

datetime

F

Droit de publication

L’authentification est facultative.
Le profil d’administrateur national est uniquement visible par les administrateurs nationaux.
Pour les autres utilisateurs, le profil d’administrateur vaut systématiquement 0.

Réponse du web-service

Le web-service renvoie un json hydrometrie contenant les contacts à publier.

Conformément au json hydrométrie, les contacts sont regroupés par intervenant.

Le json hydrométrie contient les deux propriétés Scenario et RefHyd.

RefHyd

L’objet RefHyd contiendra l’unique propriété Intervenants.

Intervenants est une liste d’objets Intervenant non vide.

Intervenant

L’objet Intervenant contiendra les propriétés suivantes:

  • CdIntervenant

  • schemeAgencyID

  • NomIntervenant

  • MnIntervenant

  • Contacts : liste non vide d’objets Contact.

Contact

Chaque objet Contact pourra contenir les propriétés suivantes:

  • CdContact

  • NomContact

  • PrenomContact

  • CiviliteContact

  • ProfilContact

  • AdContact

  • AdEtrangereContact

  • CpContact

  • VilleContact

  • FonctionContact

  • TelephoneContact

  • PortContact

  • FaxContact

  • MelContact

  • PaysContact

  • DateMajContact

  • AliasContact

ProfilContact peut contenir les valeurs suivantes:

  • 000 : Profil public

  • 001 : profil institutionnel

  • 011 : profil institutionnel et modélisateur

  • 101 : profil institutionnel administrateur national

  • 111 : profil institutionnel, modélisateur et administrateur national

La propriété ProfilsAdminLocal est absente des objets Contact

Exemple

Contacts au format json
{
  "Scenario": {},
  "RefHyd": {
    "Intervenants": [
      {
        "CdIntervenant": "1537",
        "schemeAgencyID": "SANDRE"
        "NomIntervenant": "Service ...",
        "MnIntervenant": "SCHAPI"
        "Contacts": [
          {
            "CdContact": "0",
            "NomContact": "FOO",
            "PrenomContact": "Bar",
            "CiviliteContact": 1,
            "ProfilContact": "000",
            "AdContact": "Paris",
            "AdEtrangereContact": "Madrid" ,
            "CpContact": "75000",
            "VilleContact": "Paris" ,
            "FonctionContact": "",
            "TelephoneContact": "06*",
            "PortContact": "06*",
            "FaxContact": "01*",
            "MelContact": "foo@bar.fr",
            "PaysContact": "FR",
            "DateMajContact": "2020-01-01T00:00:00"
            "AliasContact": ""
          }
        ]
      }
    ]
  }