Only display max/min values on axes in Pgfplots

I have the following function in pgfplots:

\begin{tikzpicture}% coordinates
\begin{axis}[xlabel=$x$,ylabel=$y$, axis lines = center, every axis plot/.append style={ultra thick}, ymin=-1,ymax=7]
\addlegendentry{$y=x^2$}
\end{axis}
\end{tikzpicture}


This prints out the following:

I'd like to remove the tick labels (but keep the ticks) on everything except the min/max on the axes. So I'd like it to look like this:

To that end, it'd be nice to be able to label any tick I wanted to while keeping the ticks visible on the non-labelled ones. This seems simple but I can't seem to figure it out. Thanks in advance!

If you already know the values, then you can do it easily. One way is to disable all the ticklabels and then label only required ticks.

\documentclass[border=3mm]{standalone}
\usepackage{pgfplots}
\pgfplotsset{compat=1.16}

\begin{document}
\begin{tikzpicture}
\begin{axis}[axis equal,
xlabel=$x$,ylabel=$y$, axis lines = center, every axis plot/.append style={ultra thick},
xticklabels={},yticklabels={}, % remove ticklabels
xtick distance=1, ytick distance=2, % set the tick distance
extra x ticks={-3,3},extra y ticks={6}, % add required labels
ymin=-1,ymax=7,
]
\addlegendentry{$y=x^2$}