examples_test.go 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824
  1. // THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT.
  2. package sns_test
  3. import (
  4. "bytes"
  5. "fmt"
  6. "time"
  7. "github.com/aws/aws-sdk-go/aws"
  8. "github.com/aws/aws-sdk-go/aws/session"
  9. "github.com/aws/aws-sdk-go/service/sns"
  10. )
  11. var _ time.Duration
  12. var _ bytes.Buffer
  13. func ExampleSNS_AddPermission() {
  14. sess, err := session.NewSession()
  15. if err != nil {
  16. fmt.Println("failed to create session,", err)
  17. return
  18. }
  19. svc := sns.New(sess)
  20. params := &sns.AddPermissionInput{
  21. AWSAccountId: []*string{ // Required
  22. aws.String("delegate"), // Required
  23. // More values...
  24. },
  25. ActionName: []*string{ // Required
  26. aws.String("action"), // Required
  27. // More values...
  28. },
  29. Label: aws.String("label"), // Required
  30. TopicArn: aws.String("topicARN"), // Required
  31. }
  32. resp, err := svc.AddPermission(params)
  33. if err != nil {
  34. // Print the error, cast err to awserr.Error to get the Code and
  35. // Message from an error.
  36. fmt.Println(err.Error())
  37. return
  38. }
  39. // Pretty-print the response data.
  40. fmt.Println(resp)
  41. }
  42. func ExampleSNS_CheckIfPhoneNumberIsOptedOut() {
  43. sess, err := session.NewSession()
  44. if err != nil {
  45. fmt.Println("failed to create session,", err)
  46. return
  47. }
  48. svc := sns.New(sess)
  49. params := &sns.CheckIfPhoneNumberIsOptedOutInput{
  50. PhoneNumber: aws.String("PhoneNumber"), // Required
  51. }
  52. resp, err := svc.CheckIfPhoneNumberIsOptedOut(params)
  53. if err != nil {
  54. // Print the error, cast err to awserr.Error to get the Code and
  55. // Message from an error.
  56. fmt.Println(err.Error())
  57. return
  58. }
  59. // Pretty-print the response data.
  60. fmt.Println(resp)
  61. }
  62. func ExampleSNS_ConfirmSubscription() {
  63. sess, err := session.NewSession()
  64. if err != nil {
  65. fmt.Println("failed to create session,", err)
  66. return
  67. }
  68. svc := sns.New(sess)
  69. params := &sns.ConfirmSubscriptionInput{
  70. Token: aws.String("token"), // Required
  71. TopicArn: aws.String("topicARN"), // Required
  72. AuthenticateOnUnsubscribe: aws.String("authenticateOnUnsubscribe"),
  73. }
  74. resp, err := svc.ConfirmSubscription(params)
  75. if err != nil {
  76. // Print the error, cast err to awserr.Error to get the Code and
  77. // Message from an error.
  78. fmt.Println(err.Error())
  79. return
  80. }
  81. // Pretty-print the response data.
  82. fmt.Println(resp)
  83. }
  84. func ExampleSNS_CreatePlatformApplication() {
  85. sess, err := session.NewSession()
  86. if err != nil {
  87. fmt.Println("failed to create session,", err)
  88. return
  89. }
  90. svc := sns.New(sess)
  91. params := &sns.CreatePlatformApplicationInput{
  92. Attributes: map[string]*string{ // Required
  93. "Key": aws.String("String"), // Required
  94. // More values...
  95. },
  96. Name: aws.String("String"), // Required
  97. Platform: aws.String("String"), // Required
  98. }
  99. resp, err := svc.CreatePlatformApplication(params)
  100. if err != nil {
  101. // Print the error, cast err to awserr.Error to get the Code and
  102. // Message from an error.
  103. fmt.Println(err.Error())
  104. return
  105. }
  106. // Pretty-print the response data.
  107. fmt.Println(resp)
  108. }
  109. func ExampleSNS_CreatePlatformEndpoint() {
  110. sess, err := session.NewSession()
  111. if err != nil {
  112. fmt.Println("failed to create session,", err)
  113. return
  114. }
  115. svc := sns.New(sess)
  116. params := &sns.CreatePlatformEndpointInput{
  117. PlatformApplicationArn: aws.String("String"), // Required
  118. Token: aws.String("String"), // Required
  119. Attributes: map[string]*string{
  120. "Key": aws.String("String"), // Required
  121. // More values...
  122. },
  123. CustomUserData: aws.String("String"),
  124. }
  125. resp, err := svc.CreatePlatformEndpoint(params)
  126. if err != nil {
  127. // Print the error, cast err to awserr.Error to get the Code and
  128. // Message from an error.
  129. fmt.Println(err.Error())
  130. return
  131. }
  132. // Pretty-print the response data.
  133. fmt.Println(resp)
  134. }
  135. func ExampleSNS_CreateTopic() {
  136. sess, err := session.NewSession()
  137. if err != nil {
  138. fmt.Println("failed to create session,", err)
  139. return
  140. }
  141. svc := sns.New(sess)
  142. params := &sns.CreateTopicInput{
  143. Name: aws.String("topicName"), // Required
  144. }
  145. resp, err := svc.CreateTopic(params)
  146. if err != nil {
  147. // Print the error, cast err to awserr.Error to get the Code and
  148. // Message from an error.
  149. fmt.Println(err.Error())
  150. return
  151. }
  152. // Pretty-print the response data.
  153. fmt.Println(resp)
  154. }
  155. func ExampleSNS_DeleteEndpoint() {
  156. sess, err := session.NewSession()
  157. if err != nil {
  158. fmt.Println("failed to create session,", err)
  159. return
  160. }
  161. svc := sns.New(sess)
  162. params := &sns.DeleteEndpointInput{
  163. EndpointArn: aws.String("String"), // Required
  164. }
  165. resp, err := svc.DeleteEndpoint(params)
  166. if err != nil {
  167. // Print the error, cast err to awserr.Error to get the Code and
  168. // Message from an error.
  169. fmt.Println(err.Error())
  170. return
  171. }
  172. // Pretty-print the response data.
  173. fmt.Println(resp)
  174. }
  175. func ExampleSNS_DeletePlatformApplication() {
  176. sess, err := session.NewSession()
  177. if err != nil {
  178. fmt.Println("failed to create session,", err)
  179. return
  180. }
  181. svc := sns.New(sess)
  182. params := &sns.DeletePlatformApplicationInput{
  183. PlatformApplicationArn: aws.String("String"), // Required
  184. }
  185. resp, err := svc.DeletePlatformApplication(params)
  186. if err != nil {
  187. // Print the error, cast err to awserr.Error to get the Code and
  188. // Message from an error.
  189. fmt.Println(err.Error())
  190. return
  191. }
  192. // Pretty-print the response data.
  193. fmt.Println(resp)
  194. }
  195. func ExampleSNS_DeleteTopic() {
  196. sess, err := session.NewSession()
  197. if err != nil {
  198. fmt.Println("failed to create session,", err)
  199. return
  200. }
  201. svc := sns.New(sess)
  202. params := &sns.DeleteTopicInput{
  203. TopicArn: aws.String("topicARN"), // Required
  204. }
  205. resp, err := svc.DeleteTopic(params)
  206. if err != nil {
  207. // Print the error, cast err to awserr.Error to get the Code and
  208. // Message from an error.
  209. fmt.Println(err.Error())
  210. return
  211. }
  212. // Pretty-print the response data.
  213. fmt.Println(resp)
  214. }
  215. func ExampleSNS_GetEndpointAttributes() {
  216. sess, err := session.NewSession()
  217. if err != nil {
  218. fmt.Println("failed to create session,", err)
  219. return
  220. }
  221. svc := sns.New(sess)
  222. params := &sns.GetEndpointAttributesInput{
  223. EndpointArn: aws.String("String"), // Required
  224. }
  225. resp, err := svc.GetEndpointAttributes(params)
  226. if err != nil {
  227. // Print the error, cast err to awserr.Error to get the Code and
  228. // Message from an error.
  229. fmt.Println(err.Error())
  230. return
  231. }
  232. // Pretty-print the response data.
  233. fmt.Println(resp)
  234. }
  235. func ExampleSNS_GetPlatformApplicationAttributes() {
  236. sess, err := session.NewSession()
  237. if err != nil {
  238. fmt.Println("failed to create session,", err)
  239. return
  240. }
  241. svc := sns.New(sess)
  242. params := &sns.GetPlatformApplicationAttributesInput{
  243. PlatformApplicationArn: aws.String("String"), // Required
  244. }
  245. resp, err := svc.GetPlatformApplicationAttributes(params)
  246. if err != nil {
  247. // Print the error, cast err to awserr.Error to get the Code and
  248. // Message from an error.
  249. fmt.Println(err.Error())
  250. return
  251. }
  252. // Pretty-print the response data.
  253. fmt.Println(resp)
  254. }
  255. func ExampleSNS_GetSMSAttributes() {
  256. sess, err := session.NewSession()
  257. if err != nil {
  258. fmt.Println("failed to create session,", err)
  259. return
  260. }
  261. svc := sns.New(sess)
  262. params := &sns.GetSMSAttributesInput{
  263. Attributes: []*string{
  264. aws.String("String"), // Required
  265. // More values...
  266. },
  267. }
  268. resp, err := svc.GetSMSAttributes(params)
  269. if err != nil {
  270. // Print the error, cast err to awserr.Error to get the Code and
  271. // Message from an error.
  272. fmt.Println(err.Error())
  273. return
  274. }
  275. // Pretty-print the response data.
  276. fmt.Println(resp)
  277. }
  278. func ExampleSNS_GetSubscriptionAttributes() {
  279. sess, err := session.NewSession()
  280. if err != nil {
  281. fmt.Println("failed to create session,", err)
  282. return
  283. }
  284. svc := sns.New(sess)
  285. params := &sns.GetSubscriptionAttributesInput{
  286. SubscriptionArn: aws.String("subscriptionARN"), // Required
  287. }
  288. resp, err := svc.GetSubscriptionAttributes(params)
  289. if err != nil {
  290. // Print the error, cast err to awserr.Error to get the Code and
  291. // Message from an error.
  292. fmt.Println(err.Error())
  293. return
  294. }
  295. // Pretty-print the response data.
  296. fmt.Println(resp)
  297. }
  298. func ExampleSNS_GetTopicAttributes() {
  299. sess, err := session.NewSession()
  300. if err != nil {
  301. fmt.Println("failed to create session,", err)
  302. return
  303. }
  304. svc := sns.New(sess)
  305. params := &sns.GetTopicAttributesInput{
  306. TopicArn: aws.String("topicARN"), // Required
  307. }
  308. resp, err := svc.GetTopicAttributes(params)
  309. if err != nil {
  310. // Print the error, cast err to awserr.Error to get the Code and
  311. // Message from an error.
  312. fmt.Println(err.Error())
  313. return
  314. }
  315. // Pretty-print the response data.
  316. fmt.Println(resp)
  317. }
  318. func ExampleSNS_ListEndpointsByPlatformApplication() {
  319. sess, err := session.NewSession()
  320. if err != nil {
  321. fmt.Println("failed to create session,", err)
  322. return
  323. }
  324. svc := sns.New(sess)
  325. params := &sns.ListEndpointsByPlatformApplicationInput{
  326. PlatformApplicationArn: aws.String("String"), // Required
  327. NextToken: aws.String("String"),
  328. }
  329. resp, err := svc.ListEndpointsByPlatformApplication(params)
  330. if err != nil {
  331. // Print the error, cast err to awserr.Error to get the Code and
  332. // Message from an error.
  333. fmt.Println(err.Error())
  334. return
  335. }
  336. // Pretty-print the response data.
  337. fmt.Println(resp)
  338. }
  339. func ExampleSNS_ListPhoneNumbersOptedOut() {
  340. sess, err := session.NewSession()
  341. if err != nil {
  342. fmt.Println("failed to create session,", err)
  343. return
  344. }
  345. svc := sns.New(sess)
  346. params := &sns.ListPhoneNumbersOptedOutInput{
  347. NextToken: aws.String("string"),
  348. }
  349. resp, err := svc.ListPhoneNumbersOptedOut(params)
  350. if err != nil {
  351. // Print the error, cast err to awserr.Error to get the Code and
  352. // Message from an error.
  353. fmt.Println(err.Error())
  354. return
  355. }
  356. // Pretty-print the response data.
  357. fmt.Println(resp)
  358. }
  359. func ExampleSNS_ListPlatformApplications() {
  360. sess, err := session.NewSession()
  361. if err != nil {
  362. fmt.Println("failed to create session,", err)
  363. return
  364. }
  365. svc := sns.New(sess)
  366. params := &sns.ListPlatformApplicationsInput{
  367. NextToken: aws.String("String"),
  368. }
  369. resp, err := svc.ListPlatformApplications(params)
  370. if err != nil {
  371. // Print the error, cast err to awserr.Error to get the Code and
  372. // Message from an error.
  373. fmt.Println(err.Error())
  374. return
  375. }
  376. // Pretty-print the response data.
  377. fmt.Println(resp)
  378. }
  379. func ExampleSNS_ListSubscriptions() {
  380. sess, err := session.NewSession()
  381. if err != nil {
  382. fmt.Println("failed to create session,", err)
  383. return
  384. }
  385. svc := sns.New(sess)
  386. params := &sns.ListSubscriptionsInput{
  387. NextToken: aws.String("nextToken"),
  388. }
  389. resp, err := svc.ListSubscriptions(params)
  390. if err != nil {
  391. // Print the error, cast err to awserr.Error to get the Code and
  392. // Message from an error.
  393. fmt.Println(err.Error())
  394. return
  395. }
  396. // Pretty-print the response data.
  397. fmt.Println(resp)
  398. }
  399. func ExampleSNS_ListSubscriptionsByTopic() {
  400. sess, err := session.NewSession()
  401. if err != nil {
  402. fmt.Println("failed to create session,", err)
  403. return
  404. }
  405. svc := sns.New(sess)
  406. params := &sns.ListSubscriptionsByTopicInput{
  407. TopicArn: aws.String("topicARN"), // Required
  408. NextToken: aws.String("nextToken"),
  409. }
  410. resp, err := svc.ListSubscriptionsByTopic(params)
  411. if err != nil {
  412. // Print the error, cast err to awserr.Error to get the Code and
  413. // Message from an error.
  414. fmt.Println(err.Error())
  415. return
  416. }
  417. // Pretty-print the response data.
  418. fmt.Println(resp)
  419. }
  420. func ExampleSNS_ListTopics() {
  421. sess, err := session.NewSession()
  422. if err != nil {
  423. fmt.Println("failed to create session,", err)
  424. return
  425. }
  426. svc := sns.New(sess)
  427. params := &sns.ListTopicsInput{
  428. NextToken: aws.String("nextToken"),
  429. }
  430. resp, err := svc.ListTopics(params)
  431. if err != nil {
  432. // Print the error, cast err to awserr.Error to get the Code and
  433. // Message from an error.
  434. fmt.Println(err.Error())
  435. return
  436. }
  437. // Pretty-print the response data.
  438. fmt.Println(resp)
  439. }
  440. func ExampleSNS_OptInPhoneNumber() {
  441. sess, err := session.NewSession()
  442. if err != nil {
  443. fmt.Println("failed to create session,", err)
  444. return
  445. }
  446. svc := sns.New(sess)
  447. params := &sns.OptInPhoneNumberInput{
  448. PhoneNumber: aws.String("PhoneNumber"), // Required
  449. }
  450. resp, err := svc.OptInPhoneNumber(params)
  451. if err != nil {
  452. // Print the error, cast err to awserr.Error to get the Code and
  453. // Message from an error.
  454. fmt.Println(err.Error())
  455. return
  456. }
  457. // Pretty-print the response data.
  458. fmt.Println(resp)
  459. }
  460. func ExampleSNS_Publish() {
  461. sess, err := session.NewSession()
  462. if err != nil {
  463. fmt.Println("failed to create session,", err)
  464. return
  465. }
  466. svc := sns.New(sess)
  467. params := &sns.PublishInput{
  468. Message: aws.String("message"), // Required
  469. MessageAttributes: map[string]*sns.MessageAttributeValue{
  470. "Key": { // Required
  471. DataType: aws.String("String"), // Required
  472. BinaryValue: []byte("PAYLOAD"),
  473. StringValue: aws.String("String"),
  474. },
  475. // More values...
  476. },
  477. MessageStructure: aws.String("messageStructure"),
  478. PhoneNumber: aws.String("String"),
  479. Subject: aws.String("subject"),
  480. TargetArn: aws.String("String"),
  481. TopicArn: aws.String("topicARN"),
  482. }
  483. resp, err := svc.Publish(params)
  484. if err != nil {
  485. // Print the error, cast err to awserr.Error to get the Code and
  486. // Message from an error.
  487. fmt.Println(err.Error())
  488. return
  489. }
  490. // Pretty-print the response data.
  491. fmt.Println(resp)
  492. }
  493. func ExampleSNS_RemovePermission() {
  494. sess, err := session.NewSession()
  495. if err != nil {
  496. fmt.Println("failed to create session,", err)
  497. return
  498. }
  499. svc := sns.New(sess)
  500. params := &sns.RemovePermissionInput{
  501. Label: aws.String("label"), // Required
  502. TopicArn: aws.String("topicARN"), // Required
  503. }
  504. resp, err := svc.RemovePermission(params)
  505. if err != nil {
  506. // Print the error, cast err to awserr.Error to get the Code and
  507. // Message from an error.
  508. fmt.Println(err.Error())
  509. return
  510. }
  511. // Pretty-print the response data.
  512. fmt.Println(resp)
  513. }
  514. func ExampleSNS_SetEndpointAttributes() {
  515. sess, err := session.NewSession()
  516. if err != nil {
  517. fmt.Println("failed to create session,", err)
  518. return
  519. }
  520. svc := sns.New(sess)
  521. params := &sns.SetEndpointAttributesInput{
  522. Attributes: map[string]*string{ // Required
  523. "Key": aws.String("String"), // Required
  524. // More values...
  525. },
  526. EndpointArn: aws.String("String"), // Required
  527. }
  528. resp, err := svc.SetEndpointAttributes(params)
  529. if err != nil {
  530. // Print the error, cast err to awserr.Error to get the Code and
  531. // Message from an error.
  532. fmt.Println(err.Error())
  533. return
  534. }
  535. // Pretty-print the response data.
  536. fmt.Println(resp)
  537. }
  538. func ExampleSNS_SetPlatformApplicationAttributes() {
  539. sess, err := session.NewSession()
  540. if err != nil {
  541. fmt.Println("failed to create session,", err)
  542. return
  543. }
  544. svc := sns.New(sess)
  545. params := &sns.SetPlatformApplicationAttributesInput{
  546. Attributes: map[string]*string{ // Required
  547. "Key": aws.String("String"), // Required
  548. // More values...
  549. },
  550. PlatformApplicationArn: aws.String("String"), // Required
  551. }
  552. resp, err := svc.SetPlatformApplicationAttributes(params)
  553. if err != nil {
  554. // Print the error, cast err to awserr.Error to get the Code and
  555. // Message from an error.
  556. fmt.Println(err.Error())
  557. return
  558. }
  559. // Pretty-print the response data.
  560. fmt.Println(resp)
  561. }
  562. func ExampleSNS_SetSMSAttributes() {
  563. sess, err := session.NewSession()
  564. if err != nil {
  565. fmt.Println("failed to create session,", err)
  566. return
  567. }
  568. svc := sns.New(sess)
  569. params := &sns.SetSMSAttributesInput{
  570. Attributes: map[string]*string{ // Required
  571. "Key": aws.String("String"), // Required
  572. // More values...
  573. },
  574. }
  575. resp, err := svc.SetSMSAttributes(params)
  576. if err != nil {
  577. // Print the error, cast err to awserr.Error to get the Code and
  578. // Message from an error.
  579. fmt.Println(err.Error())
  580. return
  581. }
  582. // Pretty-print the response data.
  583. fmt.Println(resp)
  584. }
  585. func ExampleSNS_SetSubscriptionAttributes() {
  586. sess, err := session.NewSession()
  587. if err != nil {
  588. fmt.Println("failed to create session,", err)
  589. return
  590. }
  591. svc := sns.New(sess)
  592. params := &sns.SetSubscriptionAttributesInput{
  593. AttributeName: aws.String("attributeName"), // Required
  594. SubscriptionArn: aws.String("subscriptionARN"), // Required
  595. AttributeValue: aws.String("attributeValue"),
  596. }
  597. resp, err := svc.SetSubscriptionAttributes(params)
  598. if err != nil {
  599. // Print the error, cast err to awserr.Error to get the Code and
  600. // Message from an error.
  601. fmt.Println(err.Error())
  602. return
  603. }
  604. // Pretty-print the response data.
  605. fmt.Println(resp)
  606. }
  607. func ExampleSNS_SetTopicAttributes() {
  608. sess, err := session.NewSession()
  609. if err != nil {
  610. fmt.Println("failed to create session,", err)
  611. return
  612. }
  613. svc := sns.New(sess)
  614. params := &sns.SetTopicAttributesInput{
  615. AttributeName: aws.String("attributeName"), // Required
  616. TopicArn: aws.String("topicARN"), // Required
  617. AttributeValue: aws.String("attributeValue"),
  618. }
  619. resp, err := svc.SetTopicAttributes(params)
  620. if err != nil {
  621. // Print the error, cast err to awserr.Error to get the Code and
  622. // Message from an error.
  623. fmt.Println(err.Error())
  624. return
  625. }
  626. // Pretty-print the response data.
  627. fmt.Println(resp)
  628. }
  629. func ExampleSNS_Subscribe() {
  630. sess, err := session.NewSession()
  631. if err != nil {
  632. fmt.Println("failed to create session,", err)
  633. return
  634. }
  635. svc := sns.New(sess)
  636. params := &sns.SubscribeInput{
  637. Protocol: aws.String("protocol"), // Required
  638. TopicArn: aws.String("topicARN"), // Required
  639. Endpoint: aws.String("endpoint"),
  640. }
  641. resp, err := svc.Subscribe(params)
  642. if err != nil {
  643. // Print the error, cast err to awserr.Error to get the Code and
  644. // Message from an error.
  645. fmt.Println(err.Error())
  646. return
  647. }
  648. // Pretty-print the response data.
  649. fmt.Println(resp)
  650. }
  651. func ExampleSNS_Unsubscribe() {
  652. sess, err := session.NewSession()
  653. if err != nil {
  654. fmt.Println("failed to create session,", err)
  655. return
  656. }
  657. svc := sns.New(sess)
  658. params := &sns.UnsubscribeInput{
  659. SubscriptionArn: aws.String("subscriptionARN"), // Required
  660. }
  661. resp, err := svc.Unsubscribe(params)
  662. if err != nil {
  663. // Print the error, cast err to awserr.Error to get the Code and
  664. // Message from an error.
  665. fmt.Println(err.Error())
  666. return
  667. }
  668. // Pretty-print the response data.
  669. fmt.Println(resp)
  670. }