Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

AddRegistration

Add a time registration to Microbizz.

Input

registrationentryregistrationentryThe time registration to add.

Output

idnumberThe ID of the newly saved registration, or 0 if MB failed to save the registration
registrationentryregistrationentryThe newly saved registration

ApproveRegistration

Approve an existing time registration in Microbizz.

Input

registrationidnumberThe Microbizz ID of the registration.
useridnumberThe Microbizz ID of the user who approved the registration.

Output

none-

-

UpdateRegistration

Update an existing registration. Only works for registrations that already belong to the current user. Only updates minutes, start time, workarea, note and stars.

The internalid (the ID of an internal post) can only be updated if the registration already refers to an internal post.

Input

registrationentryregistrationentryThe time registration to update.
versionintversion 2 or above has admin features. like setting approvedby, locked and gpslock
ignorepatchesbool0 or 1 if 1 then patches will not overwrite the registrations if the contract has active patches.

Output

idnumberThe ID of the registration

DeleteRegistrationByID

Delete a registration by ID.

Input

registrationentryidnumberThe ID of the registration to delete

Output

none--

ClearRegistrationByDate

Clear all registrations from Microbizz, on a given date (and for a given user).

Input

datedateThe date on which to clear the work.
useridnumberOptional user id. If provided, then only clear registrations for the user with this id.

Output

none--

GetRegistrationByDate

Get all registrations in Microbizz, registered on a given date (and for a given user).

Input

datedateThe date on which to get registrations.
useridnumberThe ID of a user to get registrations from. This is optional, and if not provided the API login user is assumed.

Output

registrationentriescollection[ registrationentry ]

A collection of the relevant registrations, or an empty collection if no products were found.

statenumber

Shows the state on the registration.

1: OPEN, 2: CLOSED, 3: CLOSED AND ACCEPTED

isopenbooleanIndicates if this date is open for registrations.
regtypeidintThe ID of the workplan registration for the date
atworkbooleanIf the user is supposed to be at work on the date
colorstringThe color of the workplan registration for the date
titlestringThe name of the workplan registration for the date
holidaybooleanIf the date is a holiday

GetRegistrations

Get all registrations for a given object.

Input

objecttypestringThe type of object to read registrations for, either 'todo', 'customers' or 'tools'.
objectidnumberThe ID of an object.

Output

registrationentriescollection[ registrationentry ]A collection of the relevant registrations, or an empty collection if no products were found.

GetRegistrationsByLastChange

Get a collection of registrations changed since a given date and time. Please note that this refers to when the registration was changed, and not on what time it was made.

Input

changedatedateReturn all registration changed on or after the provided date.
changetimetimeIf this is provided only return registrations changed after the provided date and time.
resumekeystringIf a partial result is returned, provide the resumekey received along with the partial result, to get the rest of the entries
onlyapprovedbooleanIf true then only return approved registrations

Output

registrationscollection[registrationentry]A collection of the relevant registrations, or an empty collection if no registration was found.
resumekeystringSometimes the entire result cannot be returned because it's to large. In that case a resumekey is returned along with the results. Execute the command again with this resumekey to get the remaining results.

OpenRegistrationsByDate

Reopens a registration day / daily time sheet.

Input

datedateThe date to reopen.
useridnumberID of the user to affect; default is the active user

Output

statenumber

Shows the state of the registration day.

1: OPEN, 2: CLOSED, 3: CLOSED AND ACCEPTED

CloseRegistrationsByDate

Closes all registrations by date.

Input

datedateThe date on which to close registrations.
notestringThe note for the day
useridintId for the user to close registrations off. Default is your own.

Output

statenumber

Shows the state of the registration day.

1: OPEN, 2: CLOSED, 3: CLOSED AND ACCEPTED

GetRegistrationsPendingInvoicing

Get all registrations which is pending invoicing.

Input

getallbooleanIf this is set, then all pending registrations are returned, with no assumptions whether they are invoicable or not.

Output

registrationentriescollection [registrationentry]A collection of the relevant registrations, or an empty collection if no products were found.

MarkRegistrationsAsInvoiced

Mark the given registrations as invoiced.

Input

registrationidscollection [number]A collection of all registration entry ids to mark as invoiced.

Output

None--

GetInternalRegistrations

Get all possible internal registrations in Microbizz.

Input

None--

Output

internalscollection[ registration_internal ]A collection of all the possible internal registrations

GetAllRegistrationsByDateRange

Get all registrations for a period.

Input

startdatedateThe first valid registrationdate
enddatedateThe last valid registrationdate
resumekeystringIf a partial result is returned, provide the resumekey received along with the partial result, to get the rest of the entries

Output

registrationscollection[registrationentry]A collection of the relevant registrations, or an empty collection if no registration was found.
resumekeystringSometimes the entire result cannot be returned because it's to large. In that case a resumekey is returned along with the results. Execute the command again with this resumekey to get the remaining results.


GetCustomRegistrationDefinitions

Get the definitions of all custom registrations.

Input

None--

Output

customregistrationscollection[customregistration]A collection of custom registrations, or an empty collection if no custom registrations were found.


GetWeekOverview

Get additional summarizing lines for describing the time usage in a given period. This is primary used by the app.

Input

startdatedateStart of period
enddatedateEnd of period

Output

linescollection[lines]The lines element is described below

Lines

left_textstringThe text leading the line. The subject of the line.
right_textstringThe text at the end of the line. The value of the line.
stylestring

normal - show as normal

bold - show as bold



Table of Contents
maxLevel3