Let $f: [1,\infty)\rightarrow \mathbb{C}$ be defined by
$$
f(z) = z^{-1/2} e^{2\pi i N z}
$$
where $N\geq1$.
Let's call a function $g: [1,\infty)\rightarrow \mathbb{C}$ almost antiperiodic if there exist positive constants $\alpha$ and $c$ such that
$$
| g(x) + g(x+c)| < \frac{\alpha}{x^{(3/2)}}
$$
for all $x>1$.
I claim that $f$ is almost antiperiodic with $c=\frac1{2 N}$ because $$\begin{aligned}
\left|f(x) + f\left(x+c\right)\right| &= \left| \frac1{\sqrt{x}} - \frac1{\sqrt{x+c}} \right|\\&= \left| \frac{\sqrt{x+c} - \sqrt{x}}{\sqrt{x}\sqrt{x+c}}\right| \\&= \frac{c}{\sqrt{x}\sqrt{x+c}\cdot({\sqrt{x+c} + \sqrt{x}})} \\&\leq\frac{c}{x^{(3/2)}}.\end{aligned}$$
I also claim that if
- a continuous function $g:[1,\infty)\rightarrow C$ is almost antiperiodic,
- there exists a real number $\gamma$ such that $|g(x)|< \gamma/\sqrt{x}$ for all $x>1$, and
- $b>a\geq1$,
then there exists a constant $\beta>0$ such that
$$
\left|\int_{x=a}^b g(x) dx\right| < \frac{\beta}{\sqrt{a}}.
$$
Proof of second claim: Let $m$ be the largest integer less than $\frac{b-a}{2 c}$. Then
$$\left|\int_{x=a}^b g(x) dx\right| $$
$$=\left|\sum_{i=0}^{m-1}\left(\int_{x=a+2ic}^{a+2ic+c} g(x) dx +\int_{x=a+2ic+c}^{a+2ic+2c} g(x) dx \right) + \int_{x=a+2mc}^{b} g(x) dx \right|$$
$$=\left|\sum_{i=0}^{m-1}\left(\int_{x=a+2ic}^{a+2ic+c} (g(x)+ g(x+c)) dx \right) + \int_{x=a+2mc}^{b} g(x) dx \right|$$
$$\leq \left|\sum_{i=0}^{m-1}\left(\int_{x=a+2ic}^{a+2ic+c} (g(x)+ g(x+c)) dx \right)\right| + \left|\int_{x=a+2mc}^{b} g(x) dx \right|$$
$$\leq \sum_{i=0}^{m-1}\left|\int_{x=a+2ic}^{a+2ic+c} (g(x)+ g(x+c)) dx \right| + \frac{2 c \gamma}{\sqrt{a}} $$
$$\leq \sum_{i=0}^{m-1}\int_{x=a+2ic}^{a+2ic+c} \frac{\alpha}{x^{(3/2)}} dx + \frac{2 c \gamma}{\sqrt{a}} $$
$$\leq \int_{x=a}^{b} \frac{\alpha}{x^{(3/2)}} dx + \frac{2 c \gamma}{\sqrt{a}} $$
$$= \frac{2\alpha}{\sqrt{a}} - \frac{2\alpha}{\sqrt{b}} + \frac{2 c \gamma}{\sqrt{a}} $$
$$< \frac{2\alpha}{\sqrt{a}} + \frac{2 c \gamma}{\sqrt{a}} $$
$$= \frac{2(\alpha + c\gamma) }{\sqrt{a}}$$
proving the second claim.
It follows from the claims above that
$$
\int_{z=Y^2}^{(Y')^2} z^{-1/2} e^{2\pi i N z} dz \in O(1/Y)
$$
if $1<Y<Y'$.
Edited for grammar, algebra errors, added a bound on $g$ in the second claim in order to make it true, and added a proof of second claim as requested by Gary which was quite helpful because it was wrong as stated originally.