I'm quite new to (La)TeX stuff like macros and custom environments, so I'm not sure, whether I'm using the right approach. I want to create my own list environment, which should produce something similar to the list here (but I don't want to add more packages like enumitem for it):
\begin{pathlist}
\item[\texttt{nodes/\{id\}}]
Gives a single node by its id.
\item[\texttt{nodes/\{id\}/children}]
Gives all children of a node, also if they are stored in a field, which is not called {\sf childIds}.
%snip
\end{pathlist}
The result looks like:

So it should become a manipulated description list. But how can I control the margins and position of the \descriptionlabel and the itembody (I don't know the command)?
As you can see in the spot, the label is placed badly, it breaks out (to the left) of the margins of the normal textbody, but the itembody lies far right to it.
My current code:
%my own description list
%newenvironment takes as definition:
%{description}[numberOfArguments]{before, processed before text in environment is processed}{after, see @ before}
\definecolor{darkblue}{HTML}{0304A4}
\newenvironment{pathlist}{%
\renewcommand{\descriptionlabel}[1]{%
%\leftmargin{5px}
\parbox[b][2em][c]{\textwidth}{{\color{darkblue}\textsf{##1}}}}%
\begin{description}}
{\end{description}}
Using \leftmargin there would not work at all. Or, where can I place something like this?
\setlength\leftmargini{0em}
There are some nice examples in this paper, but the code there does not work, too, very often. There are some nice examples here, too, but they aslo don't fit to my wanted layout.
Thanks a lot in advance!
A working example (updated):
\documentclass[a4paper, 14pt, titlepage]{article}
\usepackage{textcomp}
\usepackage{pifont}
\usepackage{xcolor}
\usepackage[american]{babel}
%my own description list
%newenvironment takes {description}[numberOfArguments]{before, processed before text in environment is processed}{after, see @ before} as definition
\definecolor{darkblue}{HTML}{0304A4}
\newenvironment{pathlist}{
\renewcommand{\descriptionlabel}[1]{
\parbox[b][2em][c]{\textwidth}{{\color{darkblue\textsf{\hspace{15px}##1}}}}
\begin{description}
\setlength{\rightmargin}{30px} % does not work at all
}{
\end{description}
}
%response type expanding
\def\resptype#1{{\it \textbf{#1} (response type)}}
\begin{document}
\section{API}
Divided by HTTP methods.
\subsection{GET}
... some text \\
The text usually starts at the left edge, it will reach to the right edge and everyone is happy. But why do the item bodies in the list below behave differently and why I can't set left- or rightmargin for them?
\begin{pathlist}
\item[\texttt{nodes/\{id\}}]
Gives a single node by its id.
\item[\texttt{nodes/\{id\}/children}]
Gives all children of a node, also if they are stored in a field, which is not called {\sf childIds}.
\end{pathlist}
\end{document}

\descriptionlabeland the itembody (I don't know the command)?" – BairDev Jun 05 '15 at 11:21\parbox[b][2em][c]{\textwidth}{{\color{darkblue}\textsf{\hspace{6px}##1}}}}. But actually I don't understand, why theparboxhangs left from the left edgte of the main textbody. And I don't know, how I can control the item's body or main text. – BairDev Jun 05 '15 at 11:34controlling the item body. – Bernard Jun 05 '15 at 11:44\itemparin the body of the\descriptionenvironment, which I use in my own environment? – BairDev Jun 05 '15 at 12:05enumitem. It's pointless trying to reinvent the wheel… – Bernard Jun 05 '15 at 12:19enumitemis demanding enough already, but if you really mean it, you can look at the descriptions of "itemize" (especially), "enumerate", "description", and "list" in section 9 of what pops up when you typetexdoc latex2e. – jon Jun 05 '15 at 13:12