There's no such example.
Since this is convenient, I denote by $L$ the Lie algebra over the algebraic closure. Let $A$ be a codimension 1 abelian ideal and let us show that some (possibly other) abelian ideal $A'$ is defined over the ground field, i.e. is a hyperplane that can be defined by a linear equation with coefficients in $K$.
Since $L/A$ is abelian, we have $[L,L]$ contained in $A$. In particular, $A$ is contained in the centralizer of $[L,L]$. In case $A$ is equal to the centralizer of $[L,L]$, this is defined over the ground field and thus we are done. So I now assume that the centralizer of $[L,L]$ is all of $L$ (so $L$ is nilpotent of step 2).
The case when $L$ is abelian is trivial. If the derived subalgebra of $L$ is 1-dimensional, then the Lie algebra law can be viewed as an alternate form. Since $A$ is a codimension 1 isotropic subspace for this form, it is easy to check that the kernel of this alternate form has codimension 2 (and is defined over the ground field) and contains $[L,L]$ because $L$ is nilpotent of step 2. Every hyperplane $A'$ containing this kernel is an abelian ideal; we can pick it to be defined over the ground field.
If the derived subalgebra of $L$ is at least 2-dimensional, there exist two linear forms $f_1,f_2$ on $L$ such that the alternate bilinear forms $(x,y)\mapsto b_i(x,y)=f_i([x,y])$, $i=1,2$ are not proportional. They can be chosen to be defined over the ground field. Let $K_i$ be the kernel of $b_i$. Then $K_i$ is contained in $A$ (otherwise $b_i$ would be zero). Besides, $K_1$ and $K_2$ have codimension 2 (because $A$ is an isotropic subspace for $b_i$) and are not equal, because otherwise $b_1$ and $b_2$ would be alternate forms on the plane $L/K_1$ and would thus be proportional as the set of antisymmetric matrices of size 2 is 1-dimensional. So the codimension of $K_1+K_2$ is at most 1. Since it's contained in $A$, we deduce that $A=K_1+K_2$. So $A$ is defined over the ground field and the proof is complete.