request.txt 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. POST http://localhost/api/user/user/POST_userV2.php
  2. Content-Type: application/json
  3. {
  4. "firstName": "Jean",
  5. "lastName": "Dupont",
  6. "login": "jean.dupont@sipa-automobiles.fr",
  7. "mail": "jean.dupont@sipa-automobiles.fr",
  8. "dtContractStart": "2025-11-08T00:00:00",
  9. "legalEntityId": 1,
  10. "departmentId": 427,
  11. "cultureID": 1036,
  12. "rolePrincipalId": 55,
  13. "employeeNumber": "999999",
  14. "managerId": 585,
  15. "birthDate": "1990-05-15T00:00:00",
  16. "calendarId": 1,
  17. "habilitedRoles": [
  18. {"id": 59},
  19. {"id": 63}
  20. ],
  21. "jobTitle": "Développeur Full Stack",
  22. "gender": "Male",
  23. "address": "123 rue de la Paix, 75001 Paris",
  24. "personalEmail": "jean.dupont.perso@gmail.com",
  25. "personalMobile": "+33612345678",
  26. "professionalMobile": "+33687654321",
  27. "allowsElectronicPayslip": true,
  28. "bankName": "Banque Postale",
  29. "iban": "FR0312739000302346383836C42",
  30. "bic": "PSSTFRPPXXX",
  31. "nationalityId": "FR",
  32. "seniorityDate": "2025-11-08T00:00:00"
  33. }
  34. ---
  35. EXPLICATION DES CHAMPS UTILISÉS:
  36. - departmentId: 427 (Vente VN MMA) - récupéré depuis get_departments.php
  37. - managerId: 585 (Thomas DUPOUY) - récupéré depuis GET_all_users.php
  38. - legalEntityId: 1 (valeur par défaut, à ajuster selon votre instance)
  39. - rolePrincipalId: 55 (valeur par défaut, à ajuster selon votre instance)
  40. - cultureID: 1036 (français France - LCID standard)
  41. - calendarId: 1 (valeur par défaut)
  42. POUR TESTER AVEC CURL:
  43. curl -X POST http://localhost/api/user/user/POST_userV2.php \
  44. -H "Content-Type: application/json" \
  45. -H "Authorization: Bearer VOTRE_TOKEN_LUCCA" \
  46. -d '{
  47. "firstName": "Jean",
  48. "lastName": "Dupont",
  49. "login": "jean.dupont.test@sipa-automobiles.fr",
  50. "mail": "jean.dupont.test@sipa-automobiles.fr",
  51. "dtContractStart": "2025-11-08T00:00:00",
  52. "legalEntityId": 1,
  53. "departmentId": 427,
  54. "cultureID": 1036,
  55. "rolePrincipalId": 55,
  56. "employeeNumber": "999999",
  57. "managerId": 585,
  58. "birthDate": "1990-05-15T00:00:00",
  59. "calendarId": 1,
  60. "habilitedRoles": [{"id": 59}, {"id": 63}],
  61. "jobTitle": "Développeur Full Stack",
  62. "gender": "Male"
  63. }'
  64. DÉPARTEMENTS DISPONIBLES (exemples):
  65. - 427: Vente VN MMA
  66. - 566: Vente VN HYUNDAI AN
  67. - 617: Vente VN CNBL Saint-Avit
  68. - 381: Atelier ETLT
  69. - 94: Atelier AN
  70. MANAGERS DISPONIBLES (exemples):
  71. - 585: Thomas DUPOUY
  72. - 1889: Aric ANTEBI
  73. - 347: Alain BARBET
  74. - 492: Romain GAROCHAU
  75. - 1425: Mathilde NACRY