@@ -7,82 +7,73 @@ curl -X POST $MESSAGES_API_URL \
77 -H ' Authorization: Bearer ' $JWT \
88 -H ' Content-Type: application/json' \
99 -d $' {
10- "from": {
11- "type": "messenger",
12- "id": "' $FB_SENDER_ID ' "
13- },
14- "to": {
15- "type": "messenger",
16- "id": "' $FB_RECIPIENT_ID ' "
17- },
18- "message": {
19- "content": {
20- "type": "custom",
21- "custom": {
22- "attachment": {
23- "type": "template",
24- "payload": {
25- "template_type": "airline_boardingpass",
26- "intro_message": "You are checked in.",
27- "locale": "en_US",
28- "boarding_pass": [
10+ "to": "' $FB_RECIPIENT_ID ' ",
11+ "from": "' $FB_SENDER_ID ' ",
12+ "channel": "messenger",
13+ "message_type": "custom",
14+ "custom": {
15+ "attachment": {
16+ "type": "template",
17+ "payload": {
18+ "template_type": "airline_boardingpass",
19+ "intro_message": "You are checked in.",
20+ "locale": "en_US",
21+ "boarding_pass": [
22+ {
23+ "passenger_name": "OTHER/A",
24+ "pnr_number": "CG4X7U",
25+ "seat": "1A",
26+ "logo_image_url": "' $LOGO_IMAGE_URL ' ",
27+ "header_image_url": "' $HEADER_IMAGE_URL ' ",
28+ "qr_code": "M1OTHER/A CG4X7U nawouehgawgnapwi3jfa0wfh",
29+ "above_bar_code_image_url": "' $ABOVE_BAR_CODE_IMAGE_URL ' ",
30+ "auxiliary_fields": [
2931 {
30- "passenger_name": "OTHER/A",
31- "pnr_number": "CG4X7U",
32- "seat": "1A",
33- "logo_image_url": "' $LOGO_IMAGE_URL ' ",
34- "header_image_url": "' $HEADER_IMAGE_URL ' ",
35- "qr_code": "M1OTHER/A CG4X7U nawouehgawgnapwi3jfa0wfh",
36- "above_bar_code_image_url": "' $ABOVE_BAR_CODE_IMAGE_URL ' ",
37- "auxiliary_fields": [
38- {
39- "label": "Terminal",
40- "value": "T1"
41- },
42- {
43- "label": "Departure",
44- "value": "30OCT 19:05"
45- }
46- ],
47- "secondary_fields": [
48- {
49- "label": "Boarding",
50- "value": "18:30"
51- },
52- {
53- "label": "Gate",
54- "value": "D57"
55- },
56- {
57- "label": "Seat",
58- "value": "74J"
59- },
60- {
61- "label": "Sec.Nr.",
62- "value": "003"
63- }
64- ],
65- "flight_info": {
66- "flight_number": "KL0642",
67- "departure_airport": {
68- "airport_code": "SFO",
69- "city": "San Francisco",
70- "terminal": "T1",
71- "gate": "D57"
72- },
73- "arrival_airport": {
74- "airport_code": "LHR",
75- "city": "London"
76- },
77- "flight_schedule": {
78- "departure_time": "2018-03-02T19:05",
79- "arrival_time": "2018-03-05T17:30"
80- }
81- }
32+ "label": "Terminal",
33+ "value": "T1"
34+ },
35+ {
36+ "label": "Departure",
37+ "value": "30OCT 19:05"
38+ }
39+ ],
40+ "secondary_fields": [
41+ {
42+ "label": "Boarding",
43+ "value": "18:30"
44+ },
45+ {
46+ "label": "Gate",
47+ "value": "D57"
48+ },
49+ {
50+ "label": "Seat",
51+ "value": "74J"
52+ },
53+ {
54+ "label": "Sec.Nr.",
55+ "value": "003"
56+ }
57+ ],
58+ "flight_info": {
59+ "flight_number": "KL0642",
60+ "departure_airport": {
61+ "airport_code": "SFO",
62+ "city": "San Francisco",
63+ "terminal": "T1",
64+ "gate": "D57"
65+ },
66+ "arrival_airport": {
67+ "airport_code": "LHR",
68+ "city": "London"
69+ },
70+ "flight_schedule": {
71+ "departure_time": "2018-03-02T19:05",
72+ "arrival_time": "2018-03-05T17:30"
8273 }
83- ]
74+ }
8475 }
85- }
76+ ]
8677 }
8778 }
8879 }
0 commit comments