The first full amplitude analysis of B+→ψ(2S)K+π+π− decays is performed using proton-proton collision data corresponding to an integrated luminosity of 9fb−1 recorded with the LHCb detector. The rich K+π+π− spectrum is studied and the branching fractions of the resonant substructure associated with the prominent K1(1270)+ contribution are measured. The data cannot be described by conventional strange and charmonium resonances only. An amplitude model with 53 components is developed comprising 11 hidden-charm exotic hadrons. New production mechanisms for charged charmonium-like states are observed. Significant resonant activity with spin-parity JP=1+ in the ψ(2S)π+ system is confirmed and a multi-pole structure is demonstrated. The spectral decomposition of the ψ(2S)π+π− invariant-mass structure, dominated by X0→ψ(2S)ρ(770)0 decays, broadly resembles the J/ψϕ spectrum observed in B+→J/ψϕK+ decays. Exotic ψ(2S)K+π− resonances are observed for the first time.