Convergent sequence in metric space

Let $A:=\mathbb{N}\cup\{\infty\}$.
What is a metric on $A$ s.t.

a sequence $(x_n)$ is convergent in a metric space $X\iff$ there exists a continuous map $\phi:A\rightarrow X$ with $\phi(n)=x_n$ for all $n=0,1,2,...$?

What I know:
Let $d$ be the metric on $A$ that we are searching $d_X$ the one on $X$.
Being convergent to a point $x$ means that for all $\epsilon$ there is a $N$ s.t. $d_X(x,x_n)<\epsilon$ for all $n\geq N$.
Being continuous means that for all $a\in X$ and all $\epsilon$ there is a $\delta$ s.t. $d_X(x,a)<\delta$ implies $d(\phi(x),\phi(a))<\epsilon$.

How can I use these to find our metric?

First note that if we found a metric in $A$ such that every creasing sequence where convergent, we'd win, because, given that:
$\implies$) let call $x$ the limit and define $\forall n\in\mathbb{N},\phi(n)=x_n$ and $\phi(\infty)=x$, so this sequence is continuous as is sequentially continuous ($f:A\rightarrow X$ is sequentially continuous if $\forall (n_k)_k\subset A,(n_k)_k$ convergent $\implies (f(n_k))_k$ convergent and $\mathrm{lim}f(n_k)=f(\mathrm{lim}n_k)$)
$\impliedby$)As $\phi$ is continuous take $x_{\infty}=\phi(\infty)$ and as $n\rightarrow\infty$, then $\phi(n)=x_n\rightarrow x_{\infty}=\phi(\infty)$
Then we simply define: $\forall n,m\in\mathbb{N},d(n,m)=\frac{|n-m|}{|n-m|+1},d(n,\infty)=d(\infty,n)=1,d(\infty,\infty)=0$