We show that all strongly non-degenerate trigonometric solutions of the associative Yang-Baxter equation (AYBE) can be obtained from triple Massey products in the Fukaya categories of square-tiled surfaces. Along the way, we give a classification result for cyclic A ∞ -algebra structures on a certain Frobenius algebra associated with a pair of 1-spherical objects in terms of the equivalence classes of the corresponding solutions of the AYBE. As an application, combining our results with homological mirror symmetry for punctured tori (cf. [17]), we prove that any two simple vector bundles on a cycle of projective lines are related by a sequence of 1-spherical twists and their inverses. arXiv:1608.08992v2 [math.SG] 29 Aug 2018 1 Our convention is that in an A ∞ -category, we read the compositions from right-to-left (as in [24]). This affects certain signs in computations. In particular, the A ∞ -relations are given by: m,n (−1) |a 1 |+...+|an|−n m d−m+1 (a d , . . . , a n+m+1 , m m (a n+m , . . . , a n+1 ), a n , . . . a 1 ) = 0